diff options
author | paramat <mat.gregory@virginmedia.com> | 2015-07-03 22:47:31 +0100 |
---|---|---|
committer | paramat <mat.gregory@virginmedia.com> | 2015-07-04 20:21:19 +0100 |
commit | d786a272c0a400f9aa2c89d696aa6f9840f83d03 (patch) | |
tree | 5a0fb92fc0484ef2003a3bd2b1ff2bd87ba132ab /src | |
parent | 64dc0532098ceeaa8a9de01984bd6a309578ec1e (diff) | |
download | minetest-d786a272c0a400f9aa2c89d696aa6f9840f83d03.tar.gz minetest-d786a272c0a400f9aa2c89d696aa6f9840f83d03.tar.bz2 minetest-d786a272c0a400f9aa2c89d696aa6f9840f83d03.zip |
Mgv7: Lower base of mountain generation to -112 and define constant
Diffstat (limited to 'src')
-rw-r--r-- | src/mapgen_v7.cpp | 4 | ||||
-rw-r--r-- | src/mapgen_v7.h | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/mapgen_v7.cpp b/src/mapgen_v7.cpp index 7fe5a3848..a111256a4 100644 --- a/src/mapgen_v7.cpp +++ b/src/mapgen_v7.cpp @@ -363,7 +363,7 @@ void MapgenV7::calculateNoise() noise_ridge_uwater->perlinMap2D(x, z); } - if ((spflags & MGV7_MOUNTAINS) && node_max.Y >= 0) { + if ((spflags & MGV7_MOUNTAINS) && node_max.Y >= MOUNTAIN_BASE) { noise_mountain->perlinMap3D(x, y, z); noise_mount_height->perlinMap2D(x, z); } @@ -536,7 +536,7 @@ int MapgenV7::generateBaseTerrain() int MapgenV7::generateMountainTerrain(int ymax) { - if (node_max.Y < 0) + if (node_max.Y < MOUNTAIN_BASE) return ymax; MapNode n_stone(c_stone); diff --git a/src/mapgen_v7.h b/src/mapgen_v7.h index 0a8a8c876..6fa1a0f1c 100644 --- a/src/mapgen_v7.h +++ b/src/mapgen_v7.h @@ -22,6 +22,8 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "mapgen.h" +#define MOUNTAIN_BASE -112 + /////////////////// Mapgen V7 flags #define MGV7_MOUNTAINS 0x01 #define MGV7_RIDGES 0x02 |