diff --git a/src/AnticheatMgr.cpp b/src/AnticheatMgr.cpp index 48af7c5..b8496d0 100644 --- a/src/AnticheatMgr.cpp +++ b/src/AnticheatMgr.cpp @@ -244,6 +244,13 @@ void AnticheatMgr::ZAxisHackDetection(Player* player, MovementInfo movementInfo) if (player->GetLiquidData().Status == LIQUID_MAP_ABOVE_WATER && movementInfo.HasMovementFlag(MOVEMENTFLAG_ONTRANSPORT)) return; + uint32 distance2D = (uint32)movementInfo.pos.GetExactDist2d(&m_Players[key].GetLastMovementInfo().pos); + + // We don't need to check for a ignore z if the player hasn't moved + // This is necessary since MovementHandler fires if you rotate the camera in place + if (!distance2D) + return; + // This is Black Magic. Check only for x and y difference but no z difference that is greater then or equal to z +2.5 of the ground if (m_Players[key].GetLastMovementInfo().pos.GetPositionZ() == movementInfo.pos.GetPositionZ() && player->GetPositionZ() >= player->GetFloorZ() + 2.5f)