diff options
author | Vincent-Michael <Vincent_Michael@gmx.de> | 2013-07-29 06:25:30 +0200 |
---|---|---|
committer | Vincent-Michael <Vincent_Michael@gmx.de> | 2013-07-29 06:25:30 +0200 |
commit | a08b52aa197a31b9821f3f9ef425da6365065907 (patch) | |
tree | db6252ca36f1d85abcbdf13ff2d95b3e1ed9ee44 /src | |
parent | eef0d67bb7f06ec063455fcfb4ae336b6aa8391d (diff) |
Core/Spells: Fix hunter talent "Improved Serpent Sting"
Closes #10001
Diffstat (limited to 'src')
-rw-r--r-- | src/server/scripts/Spells/spell_hunter.cpp | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/src/server/scripts/Spells/spell_hunter.cpp b/src/server/scripts/Spells/spell_hunter.cpp index 3f6b3b5e47e..e2686eab3ac 100644 --- a/src/server/scripts/Spells/spell_hunter.cpp +++ b/src/server/scripts/Spells/spell_hunter.cpp @@ -201,6 +201,42 @@ class spell_hun_improved_mend_pet : public SpellScriptLoader } }; +// -19464 Improved Serpent Sting +class spell_hun_improved_serpent_sting : public SpellScriptLoader +{ + public: + spell_hun_improved_serpent_sting() : SpellScriptLoader("spell_hun_improved_serpent_sting") { } + + class spell_hun_improved_serpent_sting_AuraScript : public AuraScript + { + PrepareAuraScript(spell_hun_improved_serpent_sting_AuraScript); + + void HandleEffectCalcSpellMod(AuraEffect const* aurEff, SpellModifier*& spellMod) + { + if (!spellMod) + { + spellMod = new SpellModifier(GetAura()); + spellMod->op = SpellModOp(aurEff->GetMiscValue()); + spellMod->type = SPELLMOD_PCT; + spellMod->spellId = GetId(); + spellMod->mask = GetSpellInfo()->Effects[aurEff->GetEffIndex()].SpellClassMask; + } + + spellMod->value = aurEff->GetAmount(); + } + + void Register() OVERRIDE + { + DoEffectCalcSpellMod += AuraEffectCalcSpellModFn(spell_hun_improved_serpent_sting_AuraScript::HandleEffectCalcSpellMod, EFFECT_0, SPELL_AURA_DUMMY); + } + }; + + AuraScript* GetAuraScript() const OVERRIDE + { + return new spell_hun_improved_serpent_sting_AuraScript(); + } +}; + // 53412 - Invigoration class spell_hun_invigoration : public SpellScriptLoader { @@ -944,6 +980,7 @@ void AddSC_hunter_spell_scripts() new spell_hun_disengage(); new spell_hun_fire(); new spell_hun_improved_mend_pet(); + new spell_hun_improved_serpent_sting(); new spell_hun_invigoration(); new spell_hun_last_stand_pet(); new spell_hun_masters_call(); |