diff options
Diffstat (limited to 'src/mapgen/cavegen.cpp')
-rw-r--r-- | src/mapgen/cavegen.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mapgen/cavegen.cpp b/src/mapgen/cavegen.cpp index d4cb5733b..6f571ba1f 100644 --- a/src/mapgen/cavegen.cpp +++ b/src/mapgen/cavegen.cpp @@ -20,6 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., */ #include "util/numeric.h" +#include <cmath> #include "map.h" #include "mapgen.h" #include "mapgen_v5.h" @@ -248,7 +249,7 @@ bool CavernsNoise::generateCaverns(MMVManip *vm, v3s16 nmin, v3s16 nmax) VoxelArea::add_y(em, vi, -1), cavern_amp_index++) { content_t c = vm->m_data[vi].getContent(); - float n_absamp_cavern = fabs(noise_cavern->result[index3d]) * + float n_absamp_cavern = std::fabs(noise_cavern->result[index3d]) * cavern_amp[cavern_amp_index]; // Disable CavesRandomWalk at a safe distance from caverns // to avoid excessively spreading liquids in caverns. |