From 36a83fa307e4249d2acf7f3bd8a813d7a7b355ba Mon Sep 17 00:00:00 2001 From: hondacrx Date: Sun, 12 Feb 2023 02:07:29 -0500 Subject: [PATCH] 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) --- Source/Scripts/Events/LoveIsInTheAir.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Source/Scripts/Events/LoveIsInTheAir.cs b/Source/Scripts/Events/LoveIsInTheAir.cs index cb521f11b..82a61980e 100644 --- a/Source/Scripts/Events/LoveIsInTheAir.cs +++ b/Source/Scripts/Events/LoveIsInTheAir.cs @@ -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()