From 9156f6654450df37faeeb1e4508d9b8b36c05d31 Mon Sep 17 00:00:00 2001 From: sevi Date: Mon, 25 May 2026 11:44:07 +0200 Subject: [PATCH] Core/Spells: cancel player casts on movement (#469) --- src/server/game/Spells/Spell.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp index 7f79a4a813..4e5e3058d6 100644 --- a/src/server/game/Spells/Spell.cpp +++ b/src/server/game/Spells/Spell.cpp @@ -4157,7 +4157,8 @@ void Spell::update(uint32 difftime) // if charmed by creature, trust the AI not to cheat and allow the cast to proceed // @todo this is a hack, "creature" movesplines don't differentiate turning/moving right now // however, checking what type of movement the spline is for every single spline would be really expensive - if (!m_caster->ToUnit()->IsControlledByPlayer()) + Unit* unitCaster = m_caster->ToUnit(); + if (!unitCaster->GetCharmerGUID().IsCreature() && (!unitCaster->IsControlledByPlayer() || unitCaster->GetTypeId() == TYPEID_PLAYER)) cancel(); }