summaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
authorcedeel@gmail.com <cedeel@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-06-14 22:43:23 +0200
committercedeel@gmail.com <cedeel@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-06-14 22:43:23 +0200
commit6f70fb2845e095cbfb2e14730a257048a44b8047 (patch)
tree5053e68156f42466609de0f263fc5f6f3e986660 /source
parentFixes placing blocks on snow. (diff)
downloadcuberite-6f70fb2845e095cbfb2e14730a257048a44b8047.tar
cuberite-6f70fb2845e095cbfb2e14730a257048a44b8047.tar.gz
cuberite-6f70fb2845e095cbfb2e14730a257048a44b8047.tar.bz2
cuberite-6f70fb2845e095cbfb2e14730a257048a44b8047.tar.lz
cuberite-6f70fb2845e095cbfb2e14730a257048a44b8047.tar.xz
cuberite-6f70fb2845e095cbfb2e14730a257048a44b8047.tar.zst
cuberite-6f70fb2845e095cbfb2e14730a257048a44b8047.zip
Diffstat (limited to 'source')
-rw-r--r--source/cClientHandle.cpp19
1 files changed, 17 insertions, 2 deletions
diff --git a/source/cClientHandle.cpp b/source/cClientHandle.cpp
index 92388301c..79fd6b34b 100644
--- a/source/cClientHandle.cpp
+++ b/source/cClientHandle.cpp
@@ -1051,9 +1051,24 @@ void cClientHandle::HandleBlockPlace(cPacket_BlockPlace * a_Packet)
if (ClickedBlock == E_BLOCK_SNOW)
{
- if (a_Packet->m_Direction == 1)
+ switch (a_Packet->m_Direction)
{
- a_Packet->m_PosY--;
+ case 1:
+ a_Packet->m_PosY--;
+ break;
+ case 2:
+ a_Packet->m_PosZ++;
+ break;
+ case 3:
+ a_Packet->m_PosZ--;
+ break;
+ case 4:
+ a_Packet->m_PosX++;
+ break;
+ case 5:
+ a_Packet->m_PosX--;
+ break;
+ default: break;
}
bIgnoreCollision = true;
}