diff options
author | cedeel@gmail.com <cedeel@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-06-14 22:43:23 +0200 |
---|---|---|
committer | cedeel@gmail.com <cedeel@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-06-14 22:43:23 +0200 |
commit | 6f70fb2845e095cbfb2e14730a257048a44b8047 (patch) | |
tree | 5053e68156f42466609de0f263fc5f6f3e986660 /source/cClientHandle.cpp | |
parent | Fixes placing blocks on snow. (diff) | |
download | cuberite-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 '')
-rw-r--r-- | source/cClientHandle.cpp | 19 |
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; } |