diff options
author | huri <huri@zoznam.sk> | 2012-11-20 17:29:15 +0100 |
---|---|---|
committer | huri <huri@zoznam.sk> | 2012-11-20 17:29:15 +0100 |
commit | 43d5af1ebd3743968c04edc58f9df9e0acf5b503 (patch) | |
tree | d1848cdfcea3a361b7f2678e1442fe4571a2f2bd /src | |
parent | 1ecc55272e210258e9ccbe64d5bff8d6dfbd78fa (diff) |
Core/Spells: Fixed Arcane Brilliance, Dalaran Brilliance, Power Word: Fortitude, Shadow Protection, Mark of the Wild, Blessing of Kings, Blessing of Might
Diffstat (limited to 'src')
-rw-r--r-- | src/server/scripts/Spells/spell_generic.cpp | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/src/server/scripts/Spells/spell_generic.cpp b/src/server/scripts/Spells/spell_generic.cpp index 65fde6059c9..1f23d0a4d7a 100644 --- a/src/server/scripts/Spells/spell_generic.cpp +++ b/src/server/scripts/Spells/spell_generic.cpp @@ -3306,6 +3306,35 @@ class spell_gen_gift_of_naaru : public SpellScriptLoader } }; +class spell_gen_increase_stats_buff : public SpellScriptLoader +{ + public: + spell_gen_increase_stats_buff(char const* scriptName) : SpellScriptLoader(scriptName) { } + + class spell_gen_increase_stats_buff_SpellScript : public SpellScript + { + PrepareSpellScript(spell_gen_increase_stats_buff_SpellScript); + + void HandleDummy(SpellEffIndex /*effIndex*/) + { + if (GetHitUnit()->IsInRaidWith(GetCaster())) + GetCaster()->CastSpell(GetCaster(), GetEffectValue() + 1, true); // raid buff + else + GetCaster()->CastSpell(GetHitUnit(), GetEffectValue(), true); // single-target buff + } + + void Register() + { + OnEffectHitTarget += SpellEffectFn(spell_gen_increase_stats_buff_SpellScript::HandleDummy, EFFECT_0, SPELL_EFFECT_DUMMY); + } + }; + + SpellScript* GetSpellScript() const + { + return new spell_gen_increase_stats_buff_SpellScript(); + } +}; + void AddSC_generic_spell_scripts() { new spell_gen_absorb0_hitlimit1(); @@ -3382,4 +3411,11 @@ void AddSC_generic_spell_scripts() new spell_gen_upper_deck_create_foam_sword(); new spell_gen_bonked(); new spell_gen_gift_of_naaru(); + new spell_gen_increase_stats_buff("spell_pal_blessing_of_kings"); + new spell_gen_increase_stats_buff("spell_pal_blessing_of_might"); + new spell_gen_increase_stats_buff("spell_dru_mark_of_the_wild"); + new spell_gen_increase_stats_buff("spell_pri_power_word_fortitude"); + new spell_gen_increase_stats_buff("spell_pri_shadow_protection"); + new spell_gen_increase_stats_buff("spell_mage_arcane_brilliance"); + new spell_gen_increase_stats_buff("spell_mage_dalaran_brilliance"); } |