diff options
author | Unholychick <lucas__jensen@hotmail.com> | 2014-12-24 16:40:51 +0100 |
---|---|---|
committer | Nayd <dnpd.dd@gmail.com> | 2014-12-25 21:33:02 +0000 |
commit | d13036442e82f4fe8140db09707eaa37e2392160 (patch) | |
tree | af8493e0186540d5675f6df130184a3355a97a71 /src/server/game/Spells/SpellScript.h | |
parent | 3cb6ac02b2d9114ef493369b68afac1b355d81a4 (diff) |
Core/Scripts: Add new SpellScript hook OnEffectSuccessfulDispel
Adds SpellScript hook to execute scripts after succesful dispels, example could be warlock pets Devour Magic, which should only trigger when succesfully dispelling an aura.
(cherry picked from commit ebf95e7ed7f518c54d9c4044e050d50e0dcb0c57)
Conflicts:
src/server/game/Spells/SpellEffects.cpp
Diffstat (limited to 'src/server/game/Spells/SpellScript.h')
-rw-r--r-- | src/server/game/Spells/SpellScript.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/server/game/Spells/SpellScript.h b/src/server/game/Spells/SpellScript.h index 653ae9ab5e9..c606cb91de3 100644 --- a/src/server/game/Spells/SpellScript.h +++ b/src/server/game/Spells/SpellScript.h @@ -130,6 +130,7 @@ enum SpellScriptHookType SPELL_SCRIPT_HOOK_EFFECT_LAUNCH_TARGET, SPELL_SCRIPT_HOOK_EFFECT_HIT, SPELL_SCRIPT_HOOK_EFFECT_HIT_TARGET, + SPELL_SCRIPT_HOOK_EFFECT_SUCCESSFUL_DISPEL, SPELL_SCRIPT_HOOK_BEFORE_HIT, SPELL_SCRIPT_HOOK_HIT, SPELL_SCRIPT_HOOK_AFTER_HIT, @@ -292,6 +293,7 @@ class SpellScript : public _SpellScript HookList<EffectHandler> OnEffectLaunchTarget; HookList<EffectHandler> OnEffectHit; HookList<EffectHandler> OnEffectHitTarget; + HookList<EffectHandler> OnEffectSuccessfulDispel; #define SpellEffectFn(F, I, N) EffectHandlerFunction(&F, I, N) // example: BeforeHit += SpellHitFn(class::function); @@ -334,6 +336,9 @@ class SpellScript : public _SpellScript // 11. OnHit - executed just before spell deals damage and procs auras - when spell hits target - called for each target from spell target map // 12. AfterHit - executed just after spell finishes all it's jobs for target - called for each target from spell target map + // this hook is only executed after a successful dispel of any aura + // OnEffectSuccessfulDispel - executed just after effect successfully dispelled aura(s) + // // methods allowing interaction with Spell object // |