summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordbhicks <david.bacher.hicks@gmail.com>2017-05-06 03:41:01 +0200
committerworktycho <work.tycho@gmail.com>2017-05-06 03:41:01 +0200
commitdffbf0b5109ae7ae2fd3a1793299a96725ec18dc (patch)
treef2a2b8e37fd7fbd4db5b52ed15d70d5f1f185d86
parentPrevent infinite loop when logging fails (#3693) (diff)
downloadcuberite-dffbf0b5109ae7ae2fd3a1793299a96725ec18dc.tar
cuberite-dffbf0b5109ae7ae2fd3a1793299a96725ec18dc.tar.gz
cuberite-dffbf0b5109ae7ae2fd3a1793299a96725ec18dc.tar.bz2
cuberite-dffbf0b5109ae7ae2fd3a1793299a96725ec18dc.tar.lz
cuberite-dffbf0b5109ae7ae2fd3a1793299a96725ec18dc.tar.xz
cuberite-dffbf0b5109ae7ae2fd3a1793299a96725ec18dc.tar.zst
cuberite-dffbf0b5109ae7ae2fd3a1793299a96725ec18dc.zip
-rw-r--r--src/Blocks/BlockCrops.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Blocks/BlockCrops.h b/src/Blocks/BlockCrops.h
index 5ca264774..3563f85fd 100644
--- a/src/Blocks/BlockCrops.h
+++ b/src/Blocks/BlockCrops.h
@@ -29,7 +29,7 @@ public:
cFastRandom rand;
// If not fully grown, drop the "seed" of whatever is growing:
- if (a_Meta < RipeMeta)
+ if (a_Meta < (RipeMeta - 1))
{
switch (m_BlockType)
{
@@ -97,7 +97,7 @@ public:
// If there is still room to grow and the plant can grow, then grow.
// Otherwise if the plant needs to die, then dig it up
- if ((Meta < RipeMeta) && (Action == paGrowth))
+ if ((Meta < (RipeMeta - 1)) && (Action == paGrowth))
{
a_Chunk.FastSetBlock(a_RelX, a_RelY, a_RelZ, m_BlockType, ++Meta);
}