diff options
author | offl <11556157+offl@users.noreply.github.com> | 2022-03-01 21:52:41 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-01 21:52:41 +0200 |
commit | c70c2d782af6bfd2dfd5a532de1da506353a1573 (patch) | |
tree | 2e462b1be09fd13a4148cdafda87cf3f097436af /src | |
parent | b7de3299413d05514581150f44a032384b91506e (diff) |
Scripts/Quest: Update 'A Flawless Plan' (#27841)
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 a1ea0efddcf..30d004eb819 100644 --- a/src/server/scripts/Northrend/zone_storm_peaks.cpp +++ b/src/server/scripts/Northrend/zone_storm_peaks.cpp @@ -1294,29 +1294,28 @@ class spell_player_mount_wyrm : public SpellScriptLoader } }; -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); } }; |