diff options
author | offl <11556157+offl@users.noreply.github.com> | 2022-03-01 21:52:41 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2022-03-26 15:38:16 +0100 |
commit | c3b213172315240bc62f99b5e61c23bfbaf3826e (patch) | |
tree | c67e80d88aa1d14c4ee6f6f8c851493f480045b8 /src | |
parent | f767fa4cdb78cf28e9a244bbff948f38259b4d02 (diff) |
Scripts/Quest: Update 'A Flawless Plan' (#27841)
(cherry picked from commit c70c2d782af6bfd2dfd5a532de1da506353a1573)
Diffstat (limited to 'src')
-rw-r--r-- | src/server/scripts/Northrend/zone_storm_peaks.cpp | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/server/scripts/Northrend/zone_storm_peaks.cpp b/src/server/scripts/Northrend/zone_storm_peaks.cpp index 4e13ee5a0ef..e20cd91fc74 100644 --- a/src/server/scripts/Northrend/zone_storm_peaks.cpp +++ b/src/server/scripts/Northrend/zone_storm_peaks.cpp @@ -1386,29 +1386,28 @@ public: } }; -enum CollapsingCave -{ - SPELL_COLLAPSING_CAVE = 55486 -}; +/*###### +## Quest 12823: A Flawless Plan +######*/ // 55693 - Remove Collapsing Cave Aura class spell_q12823_remove_collapsing_cave_aura : public SpellScript { PrepareSpellScript(spell_q12823_remove_collapsing_cave_aura); - bool Validate(SpellInfo const* /*spellInfo*/) override + bool Validate(SpellInfo const* spellInfo) override { - return ValidateSpellInfo({ SPELL_COLLAPSING_CAVE }); + return ValidateSpellInfo({ uint32(spellInfo->GetEffect(EFFECT_0).CalcValue()) }); } - void HandleScriptEffect(SpellEffIndex /* effIndex */) + void HandleScript(SpellEffIndex /*effIndex*/) { - GetHitUnit()->RemoveAurasDueToSpell(SPELL_COLLAPSING_CAVE); + GetHitUnit()->RemoveAurasDueToSpell(uint32(GetEffectValue())); } void Register() override { - OnEffectHitTarget += SpellEffectFn(spell_q12823_remove_collapsing_cave_aura::HandleScriptEffect, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); + OnEffectHitTarget += SpellEffectFn(spell_q12823_remove_collapsing_cave_aura::HandleScript, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); } }; |