summaryrefslogtreecommitdiff
path: root/src/heightmap.cpp
diff options
context:
space:
mode:
authorPerttu Ahola <celeron55@gmail.com>2010-12-26 13:51:56 +0200
committerPerttu Ahola <celeron55@gmail.com>2010-12-26 13:51:56 +0200
commitc32da52104cc6bbe8ed0bf1ba1a7874f015cb738 (patch)
tree844e08affaf47d1d03fb0f37eec006ae39b6e8c5 /src/heightmap.cpp
parent4ba5cd580d86710b54f4b523db4e8710fb56fdb6 (diff)
downloadminetest-c32da52104cc6bbe8ed0bf1ba1a7874f015cb738.tar.gz
minetest-c32da52104cc6bbe8ed0bf1ba1a7874f015cb738.tar.bz2
minetest-c32da52104cc6bbe8ed0bf1ba1a7874f015cb738.zip
working good
Diffstat (limited to 'src/heightmap.cpp')
-rw-r--r--src/heightmap.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/heightmap.cpp b/src/heightmap.cpp
index 5acb8916b..6e785fcc5 100644
--- a/src/heightmap.cpp
+++ b/src/heightmap.cpp
@@ -143,7 +143,7 @@ void FixedHeightmap::makeDiamond(
f32 n = avgDiagNeighbours(center, a/2);
// Add (-1.0...1.0) * randmax
- n += ((float)rand() / (float)(RAND_MAX/2) - 1.0)*randmax;
+ n += ((float)myrand() / (float)(MYRAND_MAX/2) - 1.0)*randmax;
bool worked = setGroundHeightParent(center, n);
if(a >= 2 && worked)
@@ -176,7 +176,7 @@ void FixedHeightmap::makeSquare(
f32 n = avgNeighbours(center, a/2);
// Add (-1.0...1.0) * randmax
- n += ((float)rand() / (float)(RAND_MAX/2) - 1.0)*randmax;
+ n += ((float)myrand() / (float)(MYRAND_MAX/2) - 1.0)*randmax;
bool worked = setGroundHeightParent(center, n);
if(a >= 4 && worked)