diff options
author | jackpoz <giacomopoz@gmail.com> | 2020-04-08 21:05:01 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2022-01-01 12:56:24 +0100 |
commit | 68d947d42f6b99b11bc59bb892b4e6602708dd07 (patch) | |
tree | 3f9fab655a5dcef9c2dea21386851978d7b57126 /src/server/game/Handlers/CharacterHandler.cpp | |
parent | dbb0f399facbbaf5ada4cd90333475f6ecebc6ab (diff) |
Core/Log: Log all character kicks to "network.kick" category
(cherry picked from commit 31018c36527755166d8a297ac9e6c98a66f014ae)
Diffstat (limited to 'src/server/game/Handlers/CharacterHandler.cpp')
-rw-r--r-- | src/server/game/Handlers/CharacterHandler.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/server/game/Handlers/CharacterHandler.cpp b/src/server/game/Handlers/CharacterHandler.cpp index 02caad1bb7f..d9c2aa5781d 100644 --- a/src/server/game/Handlers/CharacterHandler.cpp +++ b/src/server/game/Handlers/CharacterHandler.cpp @@ -972,7 +972,7 @@ void WorldSession::HandlePlayerLoginOpcode(WorldPackets::Character::PlayerLogin& if (PlayerLoading() || GetPlayer() != nullptr) { TC_LOG_ERROR("network", "Player tries to login again, AccountId = %d", GetAccountId()); - KickPlayer(); + KickPlayer("WorldSession::HandlePlayerLoginOpcode Another client logging in"); return; } @@ -983,7 +983,7 @@ void WorldSession::HandlePlayerLoginOpcode(WorldPackets::Character::PlayerLogin& if (!IsLegitCharacterForAccount(playerLogin.Guid)) { TC_LOG_ERROR("network", "Account (%u) can't login with that character (%s).", GetAccountId(), playerLogin.Guid.ToString().c_str()); - KickPlayer(); + KickPlayer("WorldSession::HandlePlayerLoginOpcode Trying to login with a character of another account"); return; } @@ -994,7 +994,7 @@ void WorldSession::HandleContinuePlayerLogin() { if (!PlayerLoading() || GetPlayer()) { - KickPlayer(); + KickPlayer("WorldSession::HandleContinuePlayerLogin incorrect player state when logging in"); return; } @@ -1015,7 +1015,7 @@ void WorldSession::AbortLogin(WorldPackets::Character::LoginFailureReason reason { if (!PlayerLoading() || GetPlayer()) { - KickPlayer(); + KickPlayer("WorldSession::AbortLogin incorrect player state when logging in"); return; } @@ -1040,7 +1040,7 @@ void WorldSession::HandlePlayerLogin(LoginQueryHolder* holder) if (!pCurrChar->LoadFromDB(playerGuid, holder)) { SetPlayer(nullptr); - KickPlayer(); // disconnect client, player no set to session and it will not deleted or saved at kick + KickPlayer("WorldSession::HandlePlayerLogin Player::LoadFromDB failed"); // disconnect client, player no set to session and it will not deleted or saved at kick delete pCurrChar; // delete it manually delete holder; // delete all unprocessed queries m_playerLoading.Clear(); @@ -1538,7 +1538,7 @@ void WorldSession::HandleCharRenameOpcode(WorldPackets::Character::CharacterRena { TC_LOG_ERROR("network", "Account %u, IP: %s tried to rename character %s, but it does not belong to their account!", GetAccountId(), GetRemoteAddress().c_str(), request.RenameInfo->Guid.ToString().c_str()); - KickPlayer(); + KickPlayer("WorldSession::HandleCharRenameOpcode rename character from a different account"); return; } @@ -1736,7 +1736,7 @@ void WorldSession::HandleCharCustomizeOpcode(WorldPackets::Character::CharCustom { TC_LOG_ERROR("entities.player.cheat", "Account %u, IP: %s tried to customise %s, but it does not belong to their account!", GetAccountId(), GetRemoteAddress().c_str(), packet.CustomizeInfo->CharGUID.ToString().c_str()); - KickPlayer(); + KickPlayer("WorldSession::HandleCharCustomize Trying to customise character of another account"); return; } @@ -2011,7 +2011,7 @@ void WorldSession::HandleCharRaceOrFactionChangeOpcode(WorldPackets::Character:: { TC_LOG_ERROR("entities.player.cheat", "Account %u, IP: %s tried to factionchange character %s, but it does not belong to their account!", GetAccountId(), GetRemoteAddress().c_str(), packet.RaceOrFactionChangeInfo->Guid.ToString().c_str()); - KickPlayer(); + KickPlayer("WorldSession::HandleCharFactionOrRaceChange Trying to change faction of character of another account"); return; } |