summaryrefslogtreecommitdiffstats
path: root/src/Items/ItemShears.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2014-03-18 21:49:08 +0100
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2014-03-18 21:49:08 +0100
commitb8fe024f9de9988b8aa2fc86a1d52b8dbf5712df (patch)
tree93afcc6d60f697fe59a12b4e67a780a0c7a3907e /src/Items/ItemShears.h
parentAdded levels of shrapnel (diff)
parentFixed chunkmap tree block replacing. (diff)
downloadcuberite-b8fe024f9de9988b8aa2fc86a1d52b8dbf5712df.tar
cuberite-b8fe024f9de9988b8aa2fc86a1d52b8dbf5712df.tar.gz
cuberite-b8fe024f9de9988b8aa2fc86a1d52b8dbf5712df.tar.bz2
cuberite-b8fe024f9de9988b8aa2fc86a1d52b8dbf5712df.tar.lz
cuberite-b8fe024f9de9988b8aa2fc86a1d52b8dbf5712df.tar.xz
cuberite-b8fe024f9de9988b8aa2fc86a1d52b8dbf5712df.tar.zst
cuberite-b8fe024f9de9988b8aa2fc86a1d52b8dbf5712df.zip
Diffstat (limited to 'src/Items/ItemShears.h')
-rw-r--r--src/Items/ItemShears.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Items/ItemShears.h b/src/Items/ItemShears.h
index b8f75f5ba..39d2776fa 100644
--- a/src/Items/ItemShears.h
+++ b/src/Items/ItemShears.h
@@ -28,10 +28,10 @@ public:
virtual bool OnDiggingBlock(cWorld * a_World, cPlayer * a_Player, const cItem & a_Item, int a_BlockX, int a_BlockY, int a_BlockZ, eBlockFace a_Dir) override
{
BLOCKTYPE Block = a_World->GetBlock(a_BlockX, a_BlockY, a_BlockZ);
- if (Block == E_BLOCK_LEAVES)
+ if ((Block == E_BLOCK_LEAVES) || (Block == E_BLOCK_NEW_LEAVES))
{
cItems Drops;
- Drops.push_back(cItem(E_BLOCK_LEAVES, 1, a_World->GetBlockMeta(a_BlockX, a_BlockY, a_BlockZ) & 0x03));
+ Drops.push_back(cItem(Block, 1, a_World->GetBlockMeta(a_BlockX, a_BlockY, a_BlockZ) & 0x03));
a_World->SpawnItemPickups(Drops, a_BlockX, a_BlockY, a_BlockZ);
a_World->SetBlock(a_BlockX, a_BlockY, a_BlockZ, E_BLOCK_AIR, 0);
@@ -49,6 +49,7 @@ public:
case E_BLOCK_COBWEB:
case E_BLOCK_VINES:
case E_BLOCK_LEAVES:
+ case E_BLOCK_NEW_LEAVES:
{
return true;
}