From b5a646d94a2189d12517f2cea128d6394d16873e Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Tue, 3 Apr 2012 14:07:18 +0000 Subject: Logging OnBlockDig and OnBlockPlace only in Debug mode ( http://mc-server.org/support/index.php?do=details&task_id=133&project=2 ) git-svn-id: http://mc-server.googlecode.com/svn/trunk@447 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/cClientHandle.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/source/cClientHandle.cpp b/source/cClientHandle.cpp index 567a705c6..7ec5e9834 100644 --- a/source/cClientHandle.cpp +++ b/source/cClientHandle.cpp @@ -759,7 +759,10 @@ void cClientHandle::HandleBlockDig(cPacket_BlockDig * a_Packet) return; } - LOG("OnBlockDig: %i %i %i Dir: %i Stat: %i", a_Packet->m_PosX, a_Packet->m_PosY, a_Packet->m_PosZ, a_Packet->m_Direction, a_Packet->m_Status); + LOGD("OnBlockDig: {%i, %i, %i} Dir: %i Stat: %i", + a_Packet->m_PosX, a_Packet->m_PosY, a_Packet->m_PosZ, + a_Packet->m_Direction, a_Packet->m_Status + ); if (a_Packet->m_Status == 0x04) // Drop block { m_Player->TossItem(false); @@ -969,7 +972,10 @@ void cClientHandle::HandleBlockPlace(cPacket_BlockPlace * a_Packet) cItem Item; Item.m_ItemID = Equipped.m_ItemID; Item.m_ItemCount = 1; - LOG("Placing item of type: %i", (int)a_Packet->m_ItemType); + LOGD("Placing item of type %i at {%d, %d, %d}", + (int)a_Packet->m_ItemType, + a_Packet->m_PosX, a_Packet->m_PosY, a_Packet->m_PosZ + ); // Hacked in edible items go!~ // TODO: Handle hunger -- cgit v1.2.3