summaryrefslogtreecommitdiffstats
path: root/src/Blocks/BlockLeaves.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2014-07-20 13:02:23 +0200
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2014-07-20 13:02:23 +0200
commitd0e7b2f18b15afbc78adfdcf7d1b7b3511a0a6ab (patch)
tree4f283dd99354a72bb8ba30da637b38adb5521b76 /src/Blocks/BlockLeaves.h
parentProper comment for DropBlock() (diff)
parentNBTChunkSerializer.cpp: Added break after serializing the splash potion (diff)
downloadcuberite-d0e7b2f18b15afbc78adfdcf7d1b7b3511a0a6ab.tar
cuberite-d0e7b2f18b15afbc78adfdcf7d1b7b3511a0a6ab.tar.gz
cuberite-d0e7b2f18b15afbc78adfdcf7d1b7b3511a0a6ab.tar.bz2
cuberite-d0e7b2f18b15afbc78adfdcf7d1b7b3511a0a6ab.tar.lz
cuberite-d0e7b2f18b15afbc78adfdcf7d1b7b3511a0a6ab.tar.xz
cuberite-d0e7b2f18b15afbc78adfdcf7d1b7b3511a0a6ab.tar.zst
cuberite-d0e7b2f18b15afbc78adfdcf7d1b7b3511a0a6ab.zip
Diffstat (limited to 'src/Blocks/BlockLeaves.h')
-rw-r--r--src/Blocks/BlockLeaves.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/Blocks/BlockLeaves.h b/src/Blocks/BlockLeaves.h
index 67c4535b8..1635eba08 100644
--- a/src/Blocks/BlockLeaves.h
+++ b/src/Blocks/BlockLeaves.h
@@ -11,7 +11,7 @@
// Leaves can be this many blocks that away (inclusive) from the log not to decay
#define LEAVES_CHECK_DISTANCE 6
-#define PROCESS_NEIGHBOR(x,y,z) \
+#define PROCESS_NEIGHBOR(x, y, z) \
switch (a_Area.GetBlockType(x, y, z)) \
{ \
case E_BLOCK_LEAVES: a_Area.SetBlockType(x, y, z, (BLOCKTYPE)(E_BLOCK_SPONGE + i + 1)); break; \
@@ -82,7 +82,7 @@ public:
virtual void OnNeighborChanged(cChunkInterface & a_ChunkInterface, int a_BlockX, int a_BlockY, int a_BlockZ) override
{
NIBBLETYPE Meta = a_ChunkInterface.GetBlockMeta(a_BlockX, a_BlockY, a_BlockZ);
- a_ChunkInterface.SetBlockMeta(a_BlockX, a_BlockY, a_BlockZ, Meta & 0x7); // Unset 0x8 bit so it gets checked for decay
+ a_ChunkInterface.SetBlockMeta(a_BlockX, a_BlockY, a_BlockZ, Meta & 0x7); // Unset 0x8 bit so it gets checked for decay
}
@@ -106,10 +106,10 @@ public:
int BlockZ = a_RelZ + a_Chunk.GetPosZ() * cChunkDef::Width;
cBlockArea Area;
if (!Area.Read(
- a_Chunk.GetWorld(),
- BlockX - LEAVES_CHECK_DISTANCE, BlockX + LEAVES_CHECK_DISTANCE,
- a_RelY - LEAVES_CHECK_DISTANCE, a_RelY + LEAVES_CHECK_DISTANCE,
- BlockZ - LEAVES_CHECK_DISTANCE, BlockZ + LEAVES_CHECK_DISTANCE,
+ a_Chunk.GetWorld(),
+ BlockX - LEAVES_CHECK_DISTANCE, BlockX + LEAVES_CHECK_DISTANCE,
+ a_RelY - LEAVES_CHECK_DISTANCE, a_RelY + LEAVES_CHECK_DISTANCE,
+ BlockZ - LEAVES_CHECK_DISTANCE, BlockZ + LEAVES_CHECK_DISTANCE,
cBlockArea::baTypes)
)
{