diff --git a/src/AnticheatMgr.cpp b/src/AnticheatMgr.cpp index 6c2d08a..dd95528 100644 --- a/src/AnticheatMgr.cpp +++ b/src/AnticheatMgr.cpp @@ -100,21 +100,21 @@ void AnticheatMgr::FlyHackDetection(Player* player, MovementInfo movementInfo) /*Thanks to @LilleCarl for info to check extra flag*/ bool stricterChecks = true; if (sConfigMgr->GetBoolDefault("Anticheat.StricterFlyHackCheck", false)) - { + { stricterChecks = !(movementInfo.HasMovementFlag(MOVEMENTFLAG_ASCENDING) && !player->IsInWater()); - } + } if (!movementInfo.HasMovementFlag(MOVEMENTFLAG_CAN_FLY) && !movementInfo.HasMovementFlag(MOVEMENTFLAG_FLYING) && stricterChecks) - { + { return; - } + } if (sConfigMgr->GetBoolDefault("Anticheat.KickPlayerFlyHack", false)) { if (sConfigMgr->GetBoolDefault("Anticheat.WriteLog", false)) - { + { sLog->outString("AnticheatMgr:: Fly-Hack detected and counteracted by kicking player %s (%u)", player->GetName().c_str(), player->GetGUIDLow()); - } + } player->GetSession()->KickPlayer(true); if(sConfigMgr->GetBoolDefault("Anticheat.AnnounceKick", true)) @@ -129,7 +129,7 @@ void AnticheatMgr::FlyHackDetection(Player* player, MovementInfo movementInfo) sWorld->SendServerMessage(SERVER_MSG_STRING, stream.str().c_str()); } } else if (sConfigMgr->GetBoolDefault("Anticheat.WriteLog", false)) - { + { sLog->outString( "AnticheatMgr:: Fly-Hack detected player %s (%u)", player->GetName().c_str(), player->GetGUIDLow()); }