From 1c1aedda3021e3c843b998836c6123e7bc20c93e Mon Sep 17 00:00:00 2001 From: Jonas Betzendahl Date: Fri, 16 May 2014 11:39:29 +0200 Subject: [PATCH] Grass is back, bettered mountains --- src/Map/Creation.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Map/Creation.hs b/src/Map/Creation.hs index 91faee9..205c99b 100644 --- a/src/Map/Creation.hs +++ b/src/Map/Creation.hs @@ -54,7 +54,7 @@ heightToTerrain :: MapType -> YCoord -> TileType heightToTerrain GrassIslandMap y | y < 0.1 = Ocean | y < 0.2 = Beach - | y < 1 = Grass + | y < 1.5 = Grass | y < 3 = Hill | otherwise = Mountain heightToTerrain _ _ = undefined @@ -77,7 +77,7 @@ gaussMountain seed mp = aplByPlace (liftUp c) (\(_,_) -> True) mp gs = map mkStdGen (map (*seed) [1..]) c = let ((a,b), (x,y)) = bounds mp in (head (randomRs (a,x) (gs !! 0)), (head (randomRs (b,y) (gs !! 1)))) amp = head $ randomRs ((2.0, 5.0) :: (Float, Float)) (gs !! 2) - sig = head $ randomRs ((1.0, 15.0) :: (Float, Float)) (gs !! 3) + sig = head $ randomRs ((2.0, 8.0) :: (Float, Float)) (gs !! 3) htt = heightToTerrain -- TODO: Fix Lambda to True with sensible function, maybe rework giveNeighbourhood in Map.Map