mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-16 02:20:27 +00:00
fix(Scripts/ShadowLabyrinth): Murmur's Touch (#16600)
This commit is contained in:
@@ -208,25 +208,27 @@ class spell_murmur_thundering_storm : public SpellScript
|
||||
}
|
||||
};
|
||||
|
||||
// 33711/38794 - Murmur's Touch
|
||||
class spell_murmur_touch : public AuraScript
|
||||
// 33686 - Shockwave (Murmur's Touch final explosion)
|
||||
class spell_shockwave_knockback : public SpellScript
|
||||
{
|
||||
PrepareAuraScript(spell_murmur_touch);
|
||||
PrepareSpellScript(spell_shockwave_knockback);
|
||||
|
||||
void HandleAfterRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
|
||||
bool Validate(SpellInfo const* /*spellInfo*/) override
|
||||
{
|
||||
if (GetTargetApplication()->GetRemoveMode() == AURA_REMOVE_BY_EXPIRE)
|
||||
return ValidateSpellInfo({ SPELL_SHOCKWAVE_SERVERSIDE });
|
||||
}
|
||||
|
||||
void HandleOnHit()
|
||||
{
|
||||
if (Unit* target = GetHitUnit())
|
||||
{
|
||||
if (GetTarget())
|
||||
{
|
||||
GetTarget()->CastSpell(GetTarget(), SPELL_SHOCKWAVE_SERVERSIDE, true);
|
||||
}
|
||||
target->CastSpell(target, SPELL_SHOCKWAVE_SERVERSIDE, true);
|
||||
}
|
||||
}
|
||||
|
||||
void Register() override
|
||||
{
|
||||
AfterEffectRemove += AuraEffectRemoveFn(spell_murmur_touch::HandleAfterRemove, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL, AURA_EFFECT_HANDLE_REAL);
|
||||
OnHit += SpellHitFn(spell_shockwave_knockback::HandleOnHit);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -252,6 +254,6 @@ void AddSC_boss_murmur()
|
||||
{
|
||||
RegisterShadowLabyrinthCreatureAI(boss_murmur);
|
||||
RegisterSpellScript(spell_murmur_thundering_storm);
|
||||
RegisterSpellScript(spell_murmur_touch);
|
||||
RegisterSpellScript(spell_shockwave_knockback);
|
||||
RegisterSpellScript(spell_murmur_sonic_boom_effect);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user