summaryrefslogtreecommitdiffstats
path: root/src/World.cpp
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2014-12-14 17:39:50 +0100
committerMattes D <github@xoft.cz>2014-12-14 17:39:50 +0100
commit81446b0f809c1a15b45f0f3118f0a68eb0565f91 (patch)
tree0c0038b9a2421f829d1fa08af90ccb293cd0b0ec /src/World.cpp
parentMerge pull request #1670 from Masy98/crafting (diff)
parentMerge branch 'master' into Cocoa (diff)
downloadcuberite-81446b0f809c1a15b45f0f3118f0a68eb0565f91.tar
cuberite-81446b0f809c1a15b45f0f3118f0a68eb0565f91.tar.gz
cuberite-81446b0f809c1a15b45f0f3118f0a68eb0565f91.tar.bz2
cuberite-81446b0f809c1a15b45f0f3118f0a68eb0565f91.tar.lz
cuberite-81446b0f809c1a15b45f0f3118f0a68eb0565f91.tar.xz
cuberite-81446b0f809c1a15b45f0f3118f0a68eb0565f91.tar.zst
cuberite-81446b0f809c1a15b45f0f3118f0a68eb0565f91.zip
Diffstat (limited to 'src/World.cpp')
-rw-r--r--src/World.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/World.cpp b/src/World.cpp
index 1bee6e344..d3bde3559 100644
--- a/src/World.cpp
+++ b/src/World.cpp
@@ -1520,7 +1520,21 @@ bool cWorld::GrowRipePlant(int a_BlockX, int a_BlockY, int a_BlockZ, bool a_IsBy
}
return true;
}
-
+
+ case E_BLOCK_COCOA_POD:
+ {
+ NIBBLETYPE TypeMeta = BlockMeta & 0x03;
+ int GrowState = BlockMeta >> 2;
+
+ if (GrowState < 2)
+ {
+ GrowState++;
+ FastSetBlock(a_BlockX, a_BlockY, a_BlockZ, BlockType, (NIBBLETYPE) (GrowState << 2 | TypeMeta));
+ BroadcastSoundParticleEffect(2005, a_BlockX, a_BlockY, a_BlockZ, 0);
+ }
+ return true;
+ }
+
case E_BLOCK_CROPS:
{
if (a_IsByBonemeal && !m_IsCropsBonemealable)