diff options
author | Mattes D <github@xoft.cz> | 2015-03-08 15:59:30 +0100 |
---|---|---|
committer | Mattes D <github@xoft.cz> | 2015-03-08 15:59:30 +0100 |
commit | 5b74987a59c23c579ebb2bcc37d83bfa7fc6acc9 (patch) | |
tree | 280190d80b4a8a00f983c4dfcbe2f5e5be880bef /src/Generating/CompoGenBiomal.cpp | |
parent | Merge pull request #1784 from mc-server/SteppyHeiGen (diff) | |
parent | Added parenthesis around the comparisons (diff) | |
download | cuberite-5b74987a59c23c579ebb2bcc37d83bfa7fc6acc9.tar cuberite-5b74987a59c23c579ebb2bcc37d83bfa7fc6acc9.tar.gz cuberite-5b74987a59c23c579ebb2bcc37d83bfa7fc6acc9.tar.bz2 cuberite-5b74987a59c23c579ebb2bcc37d83bfa7fc6acc9.tar.lz cuberite-5b74987a59c23c579ebb2bcc37d83bfa7fc6acc9.tar.xz cuberite-5b74987a59c23c579ebb2bcc37d83bfa7fc6acc9.tar.zst cuberite-5b74987a59c23c579ebb2bcc37d83bfa7fc6acc9.zip |
Diffstat (limited to '')
-rw-r--r-- | src/Generating/CompoGenBiomal.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/Generating/CompoGenBiomal.cpp b/src/Generating/CompoGenBiomal.cpp index 030c2baa5..3140bd754 100644 --- a/src/Generating/CompoGenBiomal.cpp +++ b/src/Generating/CompoGenBiomal.cpp @@ -542,6 +542,20 @@ protected: HasHadWater = true; } // for y a_ChunkDesc.SetBlockType(a_RelX, 0, a_RelZ, E_BLOCK_BEDROCK); + + EMCSBiome MesaVersion = a_ChunkDesc.GetBiome(a_RelX, a_RelZ); + if ((MesaVersion == biMesaPlateauF) || (MesaVersion == biMesaPlateauFM)) + { + if (Top < 95 + static_cast<int>(m_MesaFloor.CubicNoise2D(NoiseY * 2, NoiseX * 2) * 6)) + { + return; + } + + BLOCKTYPE Block = (m_MesaFloor.CubicNoise2D(NoiseX * 4, NoiseY * 4) < 0) ? E_BLOCK_DIRT : E_BLOCK_GRASS; + NIBBLETYPE Meta = (Block == E_BLOCK_GRASS) ? 0 : 1; + + a_ChunkDesc.SetBlockTypeMeta(a_RelX, Top, a_RelZ, Block, Meta); + } } |