summaryrefslogtreecommitdiffstats
path: root/src/ClientHandle.cpp
diff options
context:
space:
mode:
authorSamuel Barney <samjbarney@gmail.com>2013-12-02 17:32:28 +0100
committerSamuel Barney <samjbarney@gmail.com>2013-12-02 17:32:28 +0100
commit050702eaa14180b1821e141203f613d9fc31805f (patch)
tree8355d713fdc4be9bc0d910b98f9e20bf3131f1ab /src/ClientHandle.cpp
parentRemoved stray printf. (diff)
downloadcuberite-050702eaa14180b1821e141203f613d9fc31805f.tar
cuberite-050702eaa14180b1821e141203f613d9fc31805f.tar.gz
cuberite-050702eaa14180b1821e141203f613d9fc31805f.tar.bz2
cuberite-050702eaa14180b1821e141203f613d9fc31805f.tar.lz
cuberite-050702eaa14180b1821e141203f613d9fc31805f.tar.xz
cuberite-050702eaa14180b1821e141203f613d9fc31805f.tar.zst
cuberite-050702eaa14180b1821e141203f613d9fc31805f.zip
Diffstat (limited to 'src/ClientHandle.cpp')
-rw-r--r--src/ClientHandle.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/ClientHandle.cpp b/src/ClientHandle.cpp
index f9a48003e..95d8f23e5 100644
--- a/src/ClientHandle.cpp
+++ b/src/ClientHandle.cpp
@@ -887,6 +887,15 @@ void cClientHandle::HandlePlaceBlock(int a_BlockX, int a_BlockY, int a_BlockZ, c
)
{
// Coordinates at CLICKED block, don't move them anywhere
+ if((ClickedBlockMeta & 0x08) && (a_BlockFace == BLOCK_FACE_TOP))
+ {
+ ++a_BlockY;
+ }
+ else if (!(ClickedBlockMeta & 0x08) && (a_BlockFace == BLOCK_FACE_BOTTOM))
+ {
+ --a_BlockY;
+ }
+ World->GetBlockTypeMeta(a_BlockX, a_BlockY, a_BlockZ, ClickedBlock, ClickedBlockMeta);
}
else
{