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

Port From (https://github.com/TrinityCore/TrinityCore/commit/f79cd0f526af552d0df06b80dca951d6f1f8ae55)
This commit is contained in:
hondacrx
2023-02-12 02:07:29 -05:00
parent 05f71afa4e
commit 36a83fa307
+2 -1
View File
@@ -180,7 +180,8 @@ namespace Scripts.Events.LoveIsInTheAir
void AfterRemove(AuraEffect aurEff, AuraEffectHandleModes mode)
{
GetTarget().CastSpell(GetTarget(), SpellIds.HeavilyPerfumed);
if (GetTargetApplication().GetRemoveMode() == AuraRemoveMode.Expire)
GetTarget().CastSpell(GetTarget(), SpellIds.HeavilyPerfumed);
}
public override void Register()