summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2013-08-24 12:10:30 +0200
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2013-08-24 12:10:30 +0200
commit8bb2cab9930f807b8434ca6d75da0377605c84da (patch)
tree7d376094ec82a5a6d3d65f54b0887faeb440b373
parentFixed incorrect double slab drops (diff)
downloadcuberite-8bb2cab9930f807b8434ca6d75da0377605c84da.tar
cuberite-8bb2cab9930f807b8434ca6d75da0377605c84da.tar.gz
cuberite-8bb2cab9930f807b8434ca6d75da0377605c84da.tar.bz2
cuberite-8bb2cab9930f807b8434ca6d75da0377605c84da.tar.lz
cuberite-8bb2cab9930f807b8434ca6d75da0377605c84da.tar.xz
cuberite-8bb2cab9930f807b8434ca6d75da0377605c84da.tar.zst
cuberite-8bb2cab9930f807b8434ca6d75da0377605c84da.zip
Diffstat (limited to '')
-rw-r--r--source/ClientHandle.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/ClientHandle.cpp b/source/ClientHandle.cpp
index 937aebd1a..8ff93ec1b 100644
--- a/source/ClientHandle.cpp
+++ b/source/ClientHandle.cpp
@@ -856,7 +856,7 @@ void cClientHandle::HandlePlaceBlock(int a_BlockX, int a_BlockY, int a_BlockZ, c
//Special slab handler coding
if (
- ((a_BlockFace == BLOCK_FACE_TOP) || (a_BlockFace == BLOCK_FACE_BOTTOM)) &&
+ (((a_BlockFace == BLOCK_FACE_TOP) && (ClickedBlockMeta == (EquippedBlockDamage & 0x07))) || ((a_BlockFace == BLOCK_FACE_BOTTOM) && (ClickedBlockMeta == (EquippedBlockDamage | 0x08)))) &&
((ClickedBlock == E_BLOCK_STONE_SLAB) || (ClickedBlock == E_BLOCK_WOODEN_SLAB)) && //Is clicked a slab?
((EquippedBlock == E_BLOCK_STONE_SLAB) || (EquippedBlock == E_BLOCK_WOODEN_SLAB)) && //Is equipped a slab?
((ClickedBlockMeta & 0x07) == (EquippedBlockDamage & 0x07)) //Is clicked same type of slab as item in hand?