aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorparamat <mat.gregory@virginmedia.com>2014-12-30 22:43:15 +0000
committerkwolekr <kwolekr@minetest.net>2015-01-01 12:51:49 -0500
commit938a3f2976ade828f11a84a2a40864271e14ebba (patch)
tree05df63f0e7aceed2670f34c6f9c26fddd9ed8a24
parenta3d7203be5777010f13bf5465667028b920f4a29 (diff)
downloadminetest-938a3f2976ade828f11a84a2a40864271e14ebba.tar.gz
minetest-938a3f2976ade828f11a84a2a40864271e14ebba.tar.bz2
minetest-938a3f2976ade828f11a84a2a40864271e14ebba.zip
Mgv7: Remove range limits on mountain height to enable modification through .conf
-rw-r--r--src/mapgen_v7.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mapgen_v7.cpp b/src/mapgen_v7.cpp
index d72874d04..d9e928006 100644
--- a/src/mapgen_v7.cpp
+++ b/src/mapgen_v7.cpp
@@ -350,7 +350,7 @@ float MapgenV7::baseTerrainLevelFromMap(int index)
bool MapgenV7::getMountainTerrainAtPoint(int x, int y, int z)
{
float mnt_h_n = NoisePerlin2D(&noise_mount_height->np, x, z, seed);
- float height_modifier = -((float)y / rangelim(mnt_h_n, 80.0, 150.0));
+ float height_modifier = -((float)y / mnt_h_n);
float mnt_n = NoisePerlin3D(&noise_mountain->np, x, y, z, seed);
return mnt_n + height_modifier >= 0.6;
@@ -360,7 +360,7 @@ bool MapgenV7::getMountainTerrainAtPoint(int x, int y, int z)
bool MapgenV7::getMountainTerrainFromMap(int idx_xyz, int idx_xz, int y)
{
float mounthn = noise_mount_height->result[idx_xz];
- float height_modifier = -((float)y / rangelim(mounthn, 80.0, 150.0));
+ float height_modifier = -((float)y / mounthn);
return (noise_mountain->result[idx_xyz] + height_modifier >= 0.6);
}