Scripts/Events: Fixed infinite loop with auras 71507 and 71508 casting each other when unit is removed from map

(cherry picked from commit 70e985c7f7)
This commit is contained in:
Shauren
2023-02-09 10:26:42 +01:00
parent 0e76b4ab9d
commit f79cd0f526

View File

@@ -212,7 +212,8 @@ class spell_love_is_in_the_air_recently_analyzed : public AuraScript
void AfterRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
{
GetTarget()->CastSpell(GetTarget(), SPELL_HEAVILY_PERFUMED);
if (GetTargetApplication()->GetRemoveMode() == AURA_REMOVE_BY_EXPIRE)
GetTarget()->CastSpell(GetTarget(), SPELL_HEAVILY_PERFUMED);
}
void Register() override