From 09e48b85170572dfccd301101816d9a6345b08bb Mon Sep 17 00:00:00 2001 From: Hondacrx Date: Sun, 25 Aug 2024 00:00:58 -0400 Subject: [PATCH] Core/Spells: Implemented SPELL_ATTR13_DO_NOT_ALLOW_DISABLE_MOVEMENT_INTERRUPT Port From (https://github.com/TrinityCore/TrinityCore/commit/48bc24697f58f95a5ff07e0884ef03d27a303f73) --- Source/Framework/Constants/Spells/SpellConst.cs | 2 +- Source/Game/Entities/Unit/Unit.Spells.cs | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Source/Framework/Constants/Spells/SpellConst.cs b/Source/Framework/Constants/Spells/SpellConst.cs index 623753075..428c45370 100644 --- a/Source/Framework/Constants/Spells/SpellConst.cs +++ b/Source/Framework/Constants/Spells/SpellConst.cs @@ -2133,7 +2133,7 @@ namespace Framework.Constants Unk24 = 0x01000000, // 24 Unk25 = 0x02000000, // 25 Unk26 = 0x04000000, // 26 - Unk27 = 0x08000000, // 27 + DoNotAllowDisableMovementInterrupt = 0x08000000, // 27 Unk28 = 0x10000000, // 28 Unk29 = 0x20000000, // 29 Unk30 = 0x40000000, // 30 diff --git a/Source/Game/Entities/Unit/Unit.Spells.cs b/Source/Game/Entities/Unit/Unit.Spells.cs index d2626b5af..1a080846a 100644 --- a/Source/Game/Entities/Unit/Unit.Spells.cs +++ b/Source/Game/Entities/Unit/Unit.Spells.cs @@ -1515,6 +1515,9 @@ namespace Game.Entities public bool CanCastSpellWhileMoving(SpellInfo spellInfo) { + if (spellInfo.HasAttribute(SpellAttr13.DoNotAllowDisableMovementInterrupt)) + return false; + if (HasAuraTypeWithAffectMask(AuraType.CastWhileWalking, spellInfo)) return true;