diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-06-09 14:03:49 +0200 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-06-09 14:03:49 +0200 |
commit | ec61713221292914cd8e9e12bb77fac9e76e42eb (patch) | |
tree | 99acb7704519206e83e91235c78fa0f1ec22cd83 /source/cChunkMap.cpp | |
parent | Bonemeal is consumed in survival mode when used on growable blocks (diff) | |
download | cuberite-ec61713221292914cd8e9e12bb77fac9e76e42eb.tar cuberite-ec61713221292914cd8e9e12bb77fac9e76e42eb.tar.gz cuberite-ec61713221292914cd8e9e12bb77fac9e76e42eb.tar.bz2 cuberite-ec61713221292914cd8e9e12bb77fac9e76e42eb.tar.lz cuberite-ec61713221292914cd8e9e12bb77fac9e76e42eb.tar.xz cuberite-ec61713221292914cd8e9e12bb77fac9e76e42eb.tar.zst cuberite-ec61713221292914cd8e9e12bb77fac9e76e42eb.zip |
Diffstat (limited to 'source/cChunkMap.cpp')
-rw-r--r-- | source/cChunkMap.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/source/cChunkMap.cpp b/source/cChunkMap.cpp index 6938c1cb7..a881c71ef 100644 --- a/source/cChunkMap.cpp +++ b/source/cChunkMap.cpp @@ -1118,6 +1118,23 @@ void cChunkMap::GrowSugarcane(int a_BlockX, int a_BlockY, int a_BlockZ, int a_Nu +void cChunkMap::GrowCactus(int a_BlockX, int a_BlockY, int a_BlockZ, int a_NumBlocksToGrow)
+{
+ int ChunkX, ChunkZ;
+ cChunkDef::AbsoluteToRelative(a_BlockX, a_BlockY, a_BlockZ, ChunkX, ChunkZ);
+
+ cCSLock Lock(m_CSLayers);
+ cChunkPtr Chunk = GetChunkNoLoad(ChunkX, ZERO_CHUNK_Y, ChunkZ);
+ if (Chunk != NULL)
+ {
+ Chunk->GrowCactus(a_BlockX, a_BlockY, a_BlockZ, a_NumBlocksToGrow);
+ }
+}
+
+
+
+
+
void cChunkMap::SetNextBlockTick(int a_BlockX, int a_BlockY, int a_BlockZ)
{
int ChunkX, ChunkZ;
|