diff --git a/msu/hooks/entity/tactical/player.nut b/msu/hooks/entity/tactical/player.nut index 4525f8b7..8490f374 100644 --- a/msu/hooks/entity/tactical/player.nut +++ b/msu/hooks/entity/tactical/player.nut @@ -27,6 +27,21 @@ this.m.LevelUpsSpent++; } + q.onHired = @(__original) function() + { + __original(); + this.getSkills().onHired(); + + foreach (bro in ::World.getPlayerRoster().getAll()) + { + if (bro.getID() != this.getID()) + { + bro.getSkills().onOtherPlayerHired(this); + } + } + + } + q.onSerialize = @(__original) function( _out ) { this.getFlags().set("LevelUpsSpent", this.m.LevelUpsSpent); diff --git a/msu/hooks/skills/skill.nut b/msu/hooks/skills/skill.nut index 08293817..a1822e20 100644 --- a/msu/hooks/skills/skill.nut +++ b/msu/hooks/skills/skill.nut @@ -437,6 +437,17 @@ return _tooltip; } + +// New Events + // This event is triggered once for every skill of a player character directly after the onHired event of that player class is triggered + q.onHired <- function() + { + } + + // This event is triggered once for every skill of every other character in the player roster after the onHired event of a player class is triggered + q.onOtherPlayerHired <- function( _otherCharacter ) + { + } }); ::MSU.QueueBucket.VeryLate.push(function() { diff --git a/msu/hooks/skills/skill_container.nut b/msu/hooks/skills/skill_container.nut index 138dba66..b72e6624 100644 --- a/msu/hooks/skills/skill_container.nut +++ b/msu/hooks/skills/skill_container.nut @@ -538,4 +538,19 @@ return ret; } + +// New Events + // This event is triggered once for a player directly after the onHired event of that characters player class is triggered + q.onHired <- function() + { + this.callSkillsFunction("onHired", []); + } + + // This event is triggered once for every other character in the player roster after the onHired event of a player class is triggered + q.onOtherPlayerHired <- function( _otherCharacter ) + { + this.callSkillsFunction("onOtherPlayerHired", [ + _otherCharacter + ]); + } });