Added settings for margin, and documented in settingtypes.txt

This commit is contained in:
Gael-de-Sailly
2022-01-03 15:45:27 +01:00
parent fabe107336
commit 6d8ee5af1f
5 changed files with 22 additions and 6 deletions

View File

@ -6,7 +6,7 @@ local transform_quadri = dofile(modpath .. 'geometry.lua')
local sea_level = mapgen_rivers.settings.sea_level
local riverbed_slope = mapgen_rivers.settings.riverbed_slope * mapgen_rivers.settings.blocksize
local MAP_BOTTOM = -31000
local out_elev = mapgen_rivers.settings.margin_elev
-- Localize for performance
local floor, min, max = math.floor, math.min, math.max
@ -128,8 +128,8 @@ local function heightmaps(minp, maxp)
terrain_height_map[i] = terrain_height
lake_height_map[i] = lake_height
else
terrain_height_map[i] = MAP_BOTTOM
lake_height_map[i] = MAP_BOTTOM
terrain_height_map[i] = out_elev
lake_height_map[i] = out_elev
end
i = i + 1
end