diff options
author | madmaxoft <github@xoft.cz> | 2013-11-30 13:48:22 +0100 |
---|---|---|
committer | madmaxoft <github@xoft.cz> | 2013-11-30 13:48:22 +0100 |
commit | 463de118a02baa1500d7fbcdbafb8510cd3ee0ff (patch) | |
tree | 90f090a8b8b365c579b984dbbf131f72e44922f6 /src/Blocks/BlockDirt.h | |
parent | APIDump: Updated the project file to include all partial docs files. (diff) | |
download | cuberite-463de118a02baa1500d7fbcdbafb8510cd3ee0ff.tar cuberite-463de118a02baa1500d7fbcdbafb8510cd3ee0ff.tar.gz cuberite-463de118a02baa1500d7fbcdbafb8510cd3ee0ff.tar.bz2 cuberite-463de118a02baa1500d7fbcdbafb8510cd3ee0ff.tar.lz cuberite-463de118a02baa1500d7fbcdbafb8510cd3ee0ff.tar.xz cuberite-463de118a02baa1500d7fbcdbafb8510cd3ee0ff.tar.zst cuberite-463de118a02baa1500d7fbcdbafb8510cd3ee0ff.zip |
Diffstat (limited to '')
-rw-r--r-- | src/Blocks/BlockDirt.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Blocks/BlockDirt.h b/src/Blocks/BlockDirt.h index c694d79f6..a98199977 100644 --- a/src/Blocks/BlockDirt.h +++ b/src/Blocks/BlockDirt.h @@ -44,7 +44,7 @@ public: } } - // Grass spreads to adjacent blocks: + // Grass spreads to adjacent dirt blocks: MTRand rand; for (int i = 0; i < 2; i++) // Pick two blocks to grow to { @@ -60,8 +60,9 @@ public: continue; } bool IsValid = a_World->GetBlockTypeMeta(a_BlockX + OfsX, a_BlockY + OfsY, a_BlockZ + OfsZ, DestBlock, DestMeta); - if (!IsValid || (DestBlock != E_BLOCK_DIRT)) + if (!IsValid || (DestBlock != E_BLOCK_DIRT) || (DestMeta != E_META_DIRT_NORMAL)) { + // Not a regular dirt block, or in an unloaded chunk continue; } |