From 92c7ba73bf6f59e4a21a8867cd0c34628158c5ff Mon Sep 17 00:00:00 2001 From: killerwife Date: Mon, 3 Nov 2025 07:01:09 +0100 Subject: [PATCH] fix(Core/Unit): Fix root/stun client freeze (#23521) --- src/server/game/Entities/Unit/Unit.cpp | 7 +++++++ .../Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp | 4 +--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 96fa45e52..ed907d951 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -16709,6 +16709,13 @@ void Unit::StopMovingOnCurrentPos() void Unit::SendMovementFlagUpdate(bool self /* = false */) { + if (IsRooted()) + { + // each case where this occurs has to be examined and reported and dealt with. + LOG_ERROR("Unit", "Attempted sending heartbeat with root flag for guid {}", GetGUID().ToString()); + return; + } + WorldPacket data; BuildHeartBeatMsg(&data); SendMessageToSet(&data, self); diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp index 29ff343a8..7e7e800b9 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp @@ -205,9 +205,7 @@ struct boss_volkhan : public BossAI me->SetOrientation(2.19f); // and client - WorldPacket data; - me->BuildHeartBeatMsg(&data); - me->SendMessageToSet(&data, false); + me->SendMovementFlagUpdate(false); me->SetControlled(true, UNIT_STATE_ROOT); } else