diff options
author | paramat <paramat@users.noreply.github.com> | 2017-06-23 21:49:26 +0100 |
---|---|---|
committer | paramat <mat.gregory@virginmedia.com> | 2017-06-24 01:48:29 +0100 |
commit | 34e8e0e5ce2887391f55d5d7285088ec2c0f5761 (patch) | |
tree | cbdb790628c8ac6d0311a20cf3e120b03c00a9fe /src/mapgen_v7.h | |
parent | 9a77397fbfb95a0b45ed33831291259626968500 (diff) | |
download | minetest-34e8e0e5ce2887391f55d5d7285088ec2c0f5761.tar.gz minetest-34e8e0e5ce2887391f55d5d7285088ec2c0f5761.tar.bz2 minetest-34e8e0e5ce2887391f55d5d7285088ec2c0f5761.zip |
Mgv7: Avoid divide-by-zero errors
Some settings of paramters can cause mgv7 variables to be -inf, nan or -nan.
This can cause massive vertical columns of water to appear above sea level.
Diffstat (limited to 'src/mapgen_v7.h')
-rw-r--r-- | src/mapgen_v7.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mapgen_v7.h b/src/mapgen_v7.h index 7b4364ef1..b88d90dee 100644 --- a/src/mapgen_v7.h +++ b/src/mapgen_v7.h @@ -106,6 +106,8 @@ private: Noise *noise_float_base_height; Noise *noise_mountain; Noise *noise_ridge; + + float float_mount_height_lim; }; #endif |