From 86808ec9a5e33a6c3c686ae3a581834e9ac34fb0 Mon Sep 17 00:00:00 2001 From: hondacrx Date: Sat, 31 Aug 2019 15:29:15 -0400 Subject: [PATCH] Remove auras interrupted by falling when we fall to the ground or water Port From (https://github.com/TrinityCore/TrinityCore/commit/825719c25ca82ee94af85d1a7f2e99ce7ef5c9df) --- Source/Game/Entities/Player/Player.cs | 1 - Source/Game/Handlers/MovementHandler.cs | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Source/Game/Entities/Player/Player.cs b/Source/Game/Entities/Player/Player.cs index e2d0a746e..37bfeaac9 100644 --- a/Source/Game/Entities/Player/Player.cs +++ b/Source/Game/Entities/Player/Player.cs @@ -2078,7 +2078,6 @@ namespace Game.Entities movementInfo.Pos.posZ, height, GetPositionZ(), movementInfo.jump.fallTime, height, damage, safe_fall); } } - RemoveAurasWithInterruptFlags(SpellAuraInterruptFlags.Landing); // No fly zone - Parachute } public void UpdateFallInformationIfNeed(MovementInfo minfo, ClientOpcodes opcode) { diff --git a/Source/Game/Handlers/MovementHandler.cs b/Source/Game/Handlers/MovementHandler.cs index 68f230fcf..02efc40a1 100644 --- a/Source/Game/Handlers/MovementHandler.cs +++ b/Source/Game/Handlers/MovementHandler.cs @@ -136,6 +136,10 @@ namespace Game if (opcode == ClientOpcodes.MoveFallLand && plrMover && !plrMover.IsInFlight()) plrMover.HandleFall(movementInfo); + // interrupt parachutes upon falling or landing in water + if (opcode == ClientOpcodes.MoveFallLand || opcode == ClientOpcodes.MoveStartSwim) + mover.RemoveAurasWithInterruptFlags(SpellAuraInterruptFlags.Landing); // Parachutes + if (plrMover && movementInfo.HasMovementFlag(MovementFlag.Swimming) != plrMover.IsInWater()) { // now client not include swimming flag in case jumping under water