Page 1 of 1

Less Extreme Maps

PostPosted: Thu Nov 05, 2015 23:20
by larkguit
Is there a way to get less extreme maps in Minetest? All the overhanging mountains and flying rocks are beautiful and all, but I'd rather have a lot less of that and more flat land and gentle valleys and hill to build on. How do configure mapgen to do this? Thanks!

Re: Maps

PostPosted: Fri Nov 06, 2015 00:05
by qwertymine3
There are two ways of doing this;
1. Add some lines to your minetest.conf which change the default noise values when you create a world
2. Create a world and then change the noise settings in the minetest/worlds/world_name/map_meta.txt

The noise values/names are different for each mapgen - so the second method is better for playing around with.

IDK what you specifically want your world to look like, but there are two main noise parameters I think you will want to edit:
1. scale = (multiplication done to noise after it is generated) this is the vertical stretch for 2d noise (for 3d noise it is the terrain density, but only 2d noise is used to controll height - at least in mapgen v7)
2. offset = (addition done to noise after it is generated) this is where the noise is centred, this means rather than flattening mountians, you can lower them below the other flat terrain noises you have made (also useful for raising areas of land that were flattened too much - lowering them also reduces the number of floaty bits - making them more like 2d mountains)

Re: Less Extreme Maps

PostPosted: Fri Nov 06, 2015 00:43
by benrob0329
mapgen v6 or v5 should work.

Re: Less Extreme Maps

PostPosted: Fri Nov 06, 2015 01:03
by Dragonop
Choose a different mapgen. Mapgen v5 (mgv5) does what you describe. Mapgen v6 (mgv6) is mostly flat, but boring. Mapgen v7 (mgv7) is mostly flat, with some mountains and hills, plenty of biomes, this is the right mapgen for you if you don't mind slower world generation.

There are also some mods that alter the mapgen, try valleys_mapgen (wich has some plains, and lots of mountains, or valleys), or ethereal (mostly plain) Mapgen mods will slow your game, also, most of them use mgv7.

Re: Less Extreme Maps

PostPosted: Fri Nov 06, 2015 01:22
by paramat
In which mapgen? I'll suggest noise parameters.

Re: Less Extreme Maps

PostPosted: Fri Nov 06, 2015 04:57
by duane
Is this more like what you're after? It's still got hills, forests and rivers, but very gentle terrain. It's not perfectly flat though.

Image

I did it by changing two variables in valleys mapgen.

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
diff --git a/mapgen.lua b/mapgen.lua
index ac5dcb0..14fd808 100644
--- a/mapgen.lua
+++ b/mapgen.lua
@@ -292,8 +292,8 @@ function vmg.generate(minp, maxp, seed)
                        v2 = math.abs(v2) - river_size -- v2 represents the distance from the river, in arbitrary units.
                        local river = v2 < 0 -- the rivers are placed where v2 is negative, so where the original v2 value is close to zero.
                        local valleys = v3 * (1 - math.exp(- (v2 / v4) ^ 2)) -- use the curve of the function 1−exp(−(x/a)²) to modelise valleys. Making "a" varying 0 < a ≤ 1 changes the shape of the valleys. Try it with a geometry software ! (here x = v2 and a = v4). This variable represents the height of the terrain, from the rivers.
-                       local mountain_ground = base_ground + valleys -- approximate height of the terrain at this point (could be slightly modified by the 3D noise #6)
-                       local slopes = v5 * valleys -- This variable represents the maximal influence of the noise #6 on the elevation. v5 is the rate of the height from rivers (variable "valleys") that is concerned.
+                       local mountain_ground = base_ground
+                       local slopes = 0
 
                        if river then
                                local depth = river_depth * math.sqrt(1 - (v2 / river_size + 1) ^ 2) -- use the curve of the function −sqrt(1−x²) which modelizes a circle.

Re: Less Extreme Maps

PostPosted: Fri Nov 06, 2015 08:31
by firefox
Ethereal only overwrites the biomes, it is still mapgen7.
some of the custom lua mapgens (like valleys) make different terrain, but they are usually slower than mapgen7.

mapgen6 has flat terain even on mountains because it turns them into plateaus, but it only has either grass or desert and isn't very interesting.

Re: Less Extreme Maps

PostPosted: Fri Nov 06, 2015 08:59
by TenPlus1
Ethereal has biome height limitations that stop extreme hills and cliffs in certain areas only.

Re: Less Extreme Maps

PostPosted: Fri Nov 06, 2015 14:48
by larkguit
Duane: Perfect! Thanks!

Re: Less Extreme Maps

PostPosted: Fri Nov 06, 2015 19:23
by Gael de Sailly
duane wrote:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
diff --git a/mapgen.lua b/mapgen.lua
index ac5dcb0..14fd808 100644
--- a/mapgen.lua
+++ b/mapgen.lua
@@ -292,8 +292,8 @@ function vmg.generate(minp, maxp, seed)
                        v2 = math.abs(v2) - river_size -- v2 represents the distance from the river, in arbitrary units.
                        local river = v2 < 0 -- the rivers are placed where v2 is negative, so where the original v2 value is close to zero.
                        local valleys = v3 * (1 - math.exp(- (v2 / v4) ^ 2)) -- use the curve of the function 1−exp(−(x/a)²) to modelise valleys. Making "a" varying 0 < a ≤ 1 changes the shape of the valleys. Try it with a geometry software ! (here x = v2 and a = v4). This variable represents the height of the terrain, from the rivers.
-                       local mountain_ground = base_ground + valleys -- approximate height of the terrain at this point (could be slightly modified by the 3D noise #6)
-                       local slopes = v5 * valleys -- This variable represents the maximal influence of the noise #6 on the elevation. v5 is the rate of the height from rivers (variable "valleys") that is concerned.
+                       local mountain_ground = base_ground
+                       local slopes = 0
 
                        if river then
                                local depth = river_depth * math.sqrt(1 - (v2 / river_size + 1) ^ 2) -- use the curve of the function −sqrt(1−x²) which modelizes a circle.

In fact you've simply disabled valleys…
A cleaner solution : change noises 2 and 3 in minetest.conf. It don't disable valleys, it just makes it smoother and larger.
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
vmg_noise_2 = 0, 1, (512,512,512), -6050, 5, 0.6, 2
vmg_noise_3 = 3, 2, (512,512,512), -1914, 1, 1, 2

Re: Less Extreme Maps

PostPosted: Sat Nov 07, 2015 00:41
by duane
Gael de Sailly wrote:In fact you've simply disabled valleys…
A cleaner solution : change noises 2 and 3 in minetest.conf. It don't disable valleys, it just makes it smoother and larger.
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
vmg_noise_2 = 0, 1, (512,512,512), -6050, 5, 0.6, 2
vmg_noise_3 = 3, 2, (512,512,512), -1914, 1, 1, 2


That produces gentler terrain as well as making the rivers larger and farther apart, which might be an advantage. It also tends to make larger forests and plains. (Same map seed in both pics.)

Image

Re: Less Extreme Maps

PostPosted: Sat Nov 07, 2015 01:23
by Sokomine
duane wrote:That produces gentler terrain as well as making the rivers larger and farther apart, which might be an advantage. It also tends to make larger forests and plains. (Same map seed in both pics.)

The terrain shown in the screenshot looks very good. The mg v5 terrain sometimes has something to it; but mostly I prefer more natural looking landscapes like in v6 or as shown here.