[9793] Add 'Logout Player' output to the Char.log

This commit is contained in:
DasBlub 2010-04-25 18:28:43 +02:00 committed by arrai
parent 5902f6cf77
commit 26cbb01556
3 changed files with 8 additions and 6 deletions

View file

@ -474,14 +474,14 @@ void WorldSession::HandleCharCreateOpcode( WorldPacket & recv_data )
loginDatabase.PExecute("DELETE FROM realmcharacters WHERE acctid= '%d' AND realmid = '%d'", GetAccountId(), realmID);
loginDatabase.PExecute("INSERT INTO realmcharacters (numchars, acctid, realmid) VALUES (%u, %u, %u)", charcount, GetAccountId(), realmID);
delete pNewChar; // created only to call SaveToDB()
data << (uint8)CHAR_CREATE_SUCCESS;
SendPacket( &data );
std::string IP_str = GetRemoteAddress();
sLog.outBasic("Account: %d (IP: %s) Create Character:[%s]", GetAccountId(), IP_str.c_str(), name.c_str());
sLog.outChar("Account: %d (IP: %s) Create Character:[%s]", GetAccountId(), IP_str.c_str(), name.c_str());
sLog.outBasic("Account: %d (IP: %s) Create Character:[%s] (guid: %u)", GetAccountId(), IP_str.c_str(), name.c_str(), pNewChar->GetGUIDLow());
sLog.outChar("Account: %d (IP: %s) Create Character:[%s] (guid: %u)", GetAccountId(), IP_str.c_str(), name.c_str(), pNewChar->GetGUIDLow());
delete pNewChar; // created only to call SaveToDB()
}
void WorldSession::HandleCharDeleteOpcode( WorldPacket & recv_data )
@ -787,7 +787,7 @@ void WorldSession::HandlePlayerLogin(LoginQueryHolder *holder)
SendNotification(LANG_GM_ON);
std::string IP_str = GetRemoteAddress();
sLog.outChar("Account: %d (IP: %s) Login Character:[%s] (guid:%u)",
sLog.outChar("Account: %d (IP: %s) Login Character:[%s] (guid: %u)",
GetAccountId(), IP_str.c_str(), pCurrChar->GetName(), pCurrChar->GetGUIDLow());
if(!pCurrChar->IsStandState() && !pCurrChar->hasUnitState(UNIT_STAT_STUNNED))

View file

@ -302,6 +302,8 @@ void WorldSession::LogoutPlayer(bool Save)
if (_player)
{
sLog.outChar("Account: %d (IP: %s) Logout Character:[%s] (guid: %u)", GetAccountId(), GetRemoteAddress().c_str(), _player->GetName() ,_player->GetGUIDLow());
if (uint64 lguid = GetPlayer()->GetLootGUID())
DoLootRelease(lguid);

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "9792"
#define REVISION_NR "9793"
#endif // __REVISION_NR_H__