diff --git a/src/AnticheatMgr.cpp b/src/AnticheatMgr.cpp index b8496d0..44f826e 100644 --- a/src/AnticheatMgr.cpp +++ b/src/AnticheatMgr.cpp @@ -186,7 +186,9 @@ void AnticheatMgr::IgnoreControlHackDetection(Player* player, MovementInfo movem if (sConfigMgr->GetOption("Anticheat.IgnoreControlHack", true)) { - if (player->HasUnitState(UNIT_STATE_ROOT) && !player->GetVehicle()) + uint32 latency = 0; + latency = player->GetSession()->GetLatency() >= 400; + if (player->HasUnitState(UNIT_STATE_ROOT) && !player->GetVehicle() && !latency) { bool unrestricted = movementInfo.pos.GetPositionX() != x || movementInfo.pos.GetPositionY() != y; if (unrestricted) diff --git a/src/cs_anticheat.cpp b/src/cs_anticheat.cpp index 603415b..3ffc51f 100644 --- a/src/cs_anticheat.cpp +++ b/src/cs_anticheat.cpp @@ -44,18 +44,18 @@ public: { static std::vector anticheatCommandTable = { - { "global", SEC_GAMEMASTER, true, &HandleAntiCheatGlobalCommand, "" }, - { "player", SEC_GAMEMASTER, true, &HandleAntiCheatPlayerCommand, "" }, - { "delete", SEC_ADMINISTRATOR, true, &HandleAntiCheatDeleteCommand, "" }, + { "global", SEC_GAMEMASTER, false, &HandleAntiCheatGlobalCommand, "" }, + { "player", SEC_GAMEMASTER, false, &HandleAntiCheatPlayerCommand, "" }, + { "delete", SEC_ADMINISTRATOR, false, &HandleAntiCheatDeleteCommand, "" }, { "jail", SEC_GAMEMASTER, false, &HandleAnticheatJailCommand, "" }, { "parole", SEC_ADMINISTRATOR, false, &HandleAnticheatParoleCommand, "" }, - { "purge", SEC_ADMINISTRATOR, true, &HandleAntiCheatPurgeCommand, "" }, - { "warn", SEC_GAMEMASTER, true, &HandleAnticheatWarnCommand, "" } + { "purge", SEC_ADMINISTRATOR, false, &HandleAntiCheatPurgeCommand, "" }, + { "warn", SEC_GAMEMASTER, false, &HandleAnticheatWarnCommand, "" } }; static std::vector commandTable = { - { "anticheat", SEC_GAMEMASTER, true, NULL, "", anticheatCommandTable}, + { "anticheat", SEC_GAMEMASTER, false, NULL, "", anticheatCommandTable}, }; return commandTable;