Core/Network: Enable trace loggers for packet send and receive (just account + opcodeName, opcodeId)
This commit is contained in:
1 parent
26006551e2
commit
0c4e8c8dc2
2 files changed
+14
-9
No files matched your search
@@ -163,6 +163,9 @@ int WorldSocket::SendPacket(WorldPacket const& pct)
|
||||
if (sPacketLog->CanLogPacket())
|
||||
sPacketLog->LogPacket(pct, SERVER_TO_CLIENT);
|
||||
|
||||
if (m_Session)
|
||||
sLog->outTrace(LOG_FILTER_OPCODES, "S->C %s %s", m_Session->GetPlayerInfo().c_str(), GetOpcodeNameForLogging(pct.GetOpcode()).c_str());
|
||||
|
||||
// Create a copy of the original packet; this is to avoid issues if a hook modifies it.
|
||||
sScriptMgr->OnPacketSend(this, WorldPacket(pct));
|
||||
|
||||
@@ -674,6 +677,9 @@ int WorldSocket::ProcessIncoming(WorldPacket* new_pct)
|
||||
if (sPacketLog->CanLogPacket())
|
||||
sPacketLog->LogPacket(*new_pct, CLIENT_TO_SERVER);
|
||||
|
||||
if (m_Session)
|
||||
sLog->outTrace(LOG_FILTER_OPCODES, "C->S %s %s", m_Session->GetPlayerInfo().c_str(), GetOpcodeNameForLogging(new_pct.GetOpcode()).c_str());
|
||||
|
||||
try
|
||||
{
|
||||
switch (opcode)
|
||||
|
||||
Reference in new issue
Block a user