From bb0d175b151451f3ca4b20eb5029d26081e9ed56 Mon Sep 17 00:00:00 2001 From: MDIC Date: Mon, 9 May 2022 09:35:48 -0400 Subject: [PATCH] update (module): Reformulated for false reductions --- src/AnticheatMgr.cpp | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/src/AnticheatMgr.cpp b/src/AnticheatMgr.cpp index 1e6fa4c..4eed785 100644 --- a/src/AnticheatMgr.cpp +++ b/src/AnticheatMgr.cpp @@ -158,15 +158,6 @@ void AnticheatMgr::TeleportPlaneHackDetection(Player* player, MovementInfo movem if (!sConfigMgr->GetOption("Anticheat.DetectTelePlaneHack", true)) return; - if (player->GetAreaId()) - { - switch (player->GetAreaId()) - { - case 2100: //Maraudon https://github.com/azerothcore/azerothcore-wotlk/issues/2437 - return; - } - } - ObjectGuid key = player->GetGUID(); if (m_Players[key].GetLastOpcode() == MSG_MOVE_JUMP) @@ -178,10 +169,9 @@ void AnticheatMgr::TeleportPlaneHackDetection(Player* player, MovementInfo movem if (movementInfo.HasMovementFlag(MOVEMENTFLAG_FALLING | MOVEMENTFLAG_SWIMMING)) return; - float x, y, z; - player->GetPosition(x, y, z); - float ground_Z = player->GetMap()->GetHeight(x, y, z); - float z_diff = fabs(ground_Z - z); + float pos_z = player->GetPositionZ(); + float ground_Z = player->GetFloorZ(); + float z_diff = fabs(ground_Z - pos_z); // we are not really walking there if (z_diff > 1.0f)