[Mod][Merged] Valleys Mapgen [valleys_mapgen]

Post Reply
User avatar
duane
Member
Posts: 1715
Joined: Wed Aug 19, 2015 19:11
GitHub: duane-r
Location: Oklahoma City
Contact:

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by duane » Post

amadin wrote:Thanks for this mod.
- How decrease the amount (quantity) of rives?
You can make rivers occur farther apart by changing noise #2. Put something like the following in your minetest.conf file:

Code: Select all

vmg_noise_2 = 0, 1, (768,768,768), -6050, 5, 0.6, 2
- In README.md: "First, make sure that you've added the `valleys_mapgen` dependancy in your depends.txt (followed by a question mark if optional)" - so i must to add it in all mods?
That's only necessary for other mods that want to use the plants api, so unless you are developing a mod, you can ignore it.
- Does where a way to increase speed of valleys_mapgen? Maybe if turn off some options in settings or something else.
Turning off cave generation will make the mod run up to twice as fast. To do that, put this in your minetest.conf:

Code: Select all

vmg_caves = false
However, you can get a significant improvement and still have caves by using the simple caves switch instead:

Code: Select all

vmg_simple_caves = true
Believe in people and you don't need to believe anything else.

amadin
Member
Posts: 549
Joined: Tue Jun 16, 2015 16:23

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by amadin » Post

Only now I noticed the almost complete absence of grass (default_grass_1, default_grass_2 etc) and flowers on many big areas. I see grass near trees only, but on areas without trees - no any grass. I'm not find grass in settingtypes.txt. What can i do to add a grass on areas without trees?

Image

User avatar
Gael de Sailly
Member
Posts: 845
Joined: Sun Jan 26, 2014 17:01
GitHub: gaelysam
IRC: Gael-de-Sailly
In-game: Gael-de-Sailly gaelysam
Location: Voiron, France

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Gael de Sailly » Post

amadin wrote:- I think the better file settingtypes.txt name will be setting_exaple.txt because i tryed to change values in it at first :)
The file settingtypes.txt is used by the game to show the settings if you have a very recent Minetest version, so I can't rename it.
Go to the "Settings" tab, and in mods/valleys_mapgen. All settings are here !
amadin wrote:Only now I noticed the almost complete absence of grass (default_grass_1, default_grass_2 etc) and flowers on many big areas.
We should rework the plants parameters. I'm sorry but I've really not the time to do it.
We should also rewrite the README to put at first the instructions for users, then the instructions for developers, and finally the changelog.
Just realize how bored we would be if the world was perfect.

User avatar
duane
Member
Posts: 1715
Joined: Wed Aug 19, 2015 19:11
GitHub: duane-r
Location: Oklahoma City
Contact:

Glowees

by duane » Post

For a lark, I added some glowing plants to ValC. They are decidedly unnatural, and so disabled by default, but I like them. I don't know if you can tell, but the moss on the trees in the background also glows faintly.

Image
Believe in people and you don't need to believe anything else.

sofar
Developer
Posts: 2146
Joined: Fri Jan 16, 2015 07:31
GitHub: sofar
IRC: sofar
In-game: sofar

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by sofar » Post

amadin wrote:Only now I noticed the almost complete absence of grass (default_grass_1, default_grass_2 etc) and flowers on many big areas. I see grass near trees only, but on areas without trees - no any grass. I'm not find grass in settingtypes.txt. What can i do to add a grass on areas without trees?

Image
I'm using the lua version, and seeing this too.

The plants.lua defines only a SINGLE setting for all grass nodes, which causes the problems.

Grass is so abundant and should be present in almost all biomes. In some biomes grass should be mostly short, and sparse (grass_1, 10% or less coverage), and in some biomes grass should be abundantly long (grass_4 and 5) and omnipresent (80% coverage)

So what needs to happen is plants.lua needs to have several listings placing different densities and grass lengths in all the biomes. I'd say it'll end up being 20 or so register_plant lines to fix or at least make a decent spread and variation.

Please fix this.

sofar
Developer
Posts: 2146
Joined: Fri Jan 16, 2015 07:31
GitHub: sofar
IRC: sofar
In-game: sofar

Re: Nerd Poles

by sofar » Post

duane wrote:I think I've eliminated the nerd poles spawning in the mountains. Here's two shots of the same spot in the same game, before...
Spoiler
Image
and after.
Spoiler
Image
I can do the same with the lua mapgen, if anyone's interested. Does the broken terrain bother anyone?

Edit: It turns out that this isn't a problem with the lua after all.
I'm assuming you are smoothing the landscape here?

If so, it appears you are using a uniform smoothing value. You could create a 2d perlin noise map and smooth each chunk according to the value in the map for each spot/chunk.

That would still create cliffs, which I like a bit. It also differentiates the boring flat and curved surfaces a bit.

User avatar
duane
Member
Posts: 1715
Joined: Wed Aug 19, 2015 19:11
GitHub: duane-r
Location: Oklahoma City
Contact:

Re: Nerd Poles

by duane » Post

sofar wrote:I'm assuming you are smoothing the landscape here?

If so, it appears you are using a uniform smoothing value. You could create a 2d perlin noise map and smooth each chunk according to the value in the map for each spot/chunk.

That would still create cliffs, which I like a bit. It also differentiates the boring flat and curved surfaces a bit.
I'm a bit confused. The post you quoted referred to Valleys C, which has changed quite a bit since then. I've already added cliffs and rougher terrain in the heights.

The original Valleys never had the problem to begin with, and already produces cliffs.
Believe in people and you don't need to believe anything else.

User avatar
duane
Member
Posts: 1715
Joined: Wed Aug 19, 2015 19:11
GitHub: duane-r
Location: Oklahoma City
Contact:

Grasses

by duane » Post

I'm not sure why there's suddenly discontent with the grass in version 2.3. As far as I can reproduce on my machine, both 2.2 and 2.3 produce about the same amount of grass, for the same reason -- both are checking soil types, which greatly restricts its range. I don't think it's possible to have widespread grass given the way we assign soil types without removing grass' dependence on any particular range of types. At least I haven't been able to find any range that works.

I don't see a problem with letting grass grow on any soil; grasses grow pretty much anywhere, but it's a bit of a departure from the spirit of the mod. And we could stunt grass growing on some types, if you like.

Bear in mind that Valleys (lua) doesn't use biomes. Everything is planted by raw temperature, humidity, altitude, and soil type.
Believe in people and you don't need to believe anything else.

User avatar
Gael de Sailly
Member
Posts: 845
Joined: Sun Jan 26, 2014 17:01
GitHub: gaelysam
IRC: Gael-de-Sailly
In-game: Gael-de-Sailly gaelysam
Location: Voiron, France

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Gael de Sailly » Post

duane wrote:I'm not sure why there's suddenly discontent with the grass in version 2.3. As far as I can reproduce on my machine, both 2.2 and 2.3 produce about the same amount of grass, for the same reason -- both are checking soil types, which greatly restricts its range. I don't think it's possible to have widespread grass given the way we assign soil types without removing grass' dependence on any particular range of types. At least I haven't been able to find any range that works.
The grasses spawning conditions have not changed from 2.0. That was already a problem. I'll try to redefine all plants conditions as soon as possible (around December 20th), and release 2.3.
Just realize how bored we would be if the world was perfect.

User avatar
duane
Member
Posts: 1715
Joined: Wed Aug 19, 2015 19:11
GitHub: duane-r
Location: Oklahoma City
Contact:

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by duane » Post

This produces a little more grass without planting it on bare sand or clay. It still leaves big bare patches.

Code: Select all

diff --git a/plants.lua b/plants.lua
index e787412..c87684e 100644
--- a/plants.lua
+++ b/plants.lua
@@ -1,4 +1,8 @@
 if vmg.define("plants", true) then
+	local clay_threshold = vmg.define("clay_threshold", 1)
+	local sand_threshold = vmg.define("sand_threshold", 0.75)
+	local silt_threshold = vmg.define("silt_threshold", 1)
+
 	vmg.register_plant({
 		nodes = {"default:papyrus", n=4},
 		cover = 0.030,
@@ -39,15 +43,17 @@ if vmg.define("plants", true) then
 		end,
 	})
 
-	vmg.register_plant({
-		nodes = {"default:grass_1", "default:grass_2", "default:grass_3", "default:grass_4", "default:grass_5"},
-		cover = 0.60,
-		density = 0.24,
-		priority = 59,
-		check = function(t, pos)
-			return t.v15 < 0.65 and t.temp >= 0.65 and t.temp < 1.5 and t.humidity < 2.6 and t.v16 < 1.5 and t.v13 < 0.8
-		end,
-	})
+	for i = 1, 5 do
+		vmg.register_plant({
+			nodes = { "default:grass_"..i},
+			cover = 0.60,
+			density = 0.24,
+			priority = 59,
+			check = function(t, pos)
+				return t.v15 < sand_threshold - (i - 1) * 0.1 and t.temp >= 1 and t.temp < 1.5 and t.humidity < 2.6 and t.v13 < clay_threshold - (i - 1) * 0.1
+			end,
+		})
+	end
 
 	vmg.register_plant({
 		nodes = {"default:junglegrass"},
Believe in people and you don't need to believe anything else.

User avatar
paramat
Developer
Posts: 3700
Joined: Sun Oct 28, 2012 00:05
GitHub: paramat
IRC: paramat
Location: UK

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by paramat » Post

Let me know when you have the C++ version fairly complete then we can review it and perhaps work towards adding as a core mapgen.

sofar
Developer
Posts: 2146
Joined: Fri Jan 16, 2015 07:31
GitHub: sofar
IRC: sofar
In-game: sofar

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by sofar » Post

paramat wrote:Let me know when you have the C++ version fairly complete then we can review it and perhaps work towards adding as a core mapgen.
+1!

Ivà
Member
Posts: 115
Joined: Sun Feb 22, 2015 07:11
GitHub: melzua
IRC: melzua
In-game: melzua
Location: Catalonia

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Ivà » Post

sofar wrote:
paramat wrote:Let me know when you have the C++ version fairly complete then we can review it and perhaps work towards adding as a core mapgen.
+1!
+1 too!

User avatar
afflatus
Member
Posts: 362
Joined: Tue Apr 01, 2014 19:47
GitHub: 0-afflatus
IRC: afflatus
In-game: afflatus
Location: Avalonia
Contact:

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by afflatus » Post

+1 and me! :D
Grailtest is stirring ...

User avatar
kaadmy
Member
Posts: 706
Joined: Thu Aug 27, 2015 23:07
GitHub: kaadmy
IRC: KaadmY
In-game: KaadmY kaadmy NeD

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by kaadmy » Post

+1 for this being a core mapgen!
Never paint white stripes on roads near Zebra crossings.

Pixture

User avatar
paramat
Developer
Posts: 3700
Joined: Sun Oct 28, 2012 00:05
GitHub: paramat
IRC: paramat
Location: UK

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by paramat » Post

.. That is, of course, if the original author agrees to it.

User avatar
Nathan.S
Member
Posts: 1147
Joined: Wed Sep 24, 2014 17:47
GitHub: NathanSalapat
IRC: NathanS21
In-game: NathanS21
Location: Bigsby Texas
Contact:

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Nathan.S » Post

I would love for this to be a core mapgen as well.
I record Minetest videos, Mod reviews, Modding tutorials, and Lets plays.
Check out my website, and brand new Minetest Modding Course

User avatar
Minetestforfun
Member
Posts: 940
Joined: Tue Aug 05, 2014 14:09
GitHub: MinetestForFun
IRC: MinetestForFun
In-game: MinetestForFun
Location: On earth
Contact:

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Minetestforfun » Post

It will be a great add to include this mod in a core mapgen :)

User avatar
Fixer
Member
Posts: 904
Joined: Sun Jul 31, 2011 11:23
IRC: Fixer
In-game: Fixer
Location: Ukraine

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Fixer » Post

+1 for inclusion in core minetest, it is amazing mapgen, really amazing.

btw, do I need 64bit minetest for that? I'm testing on 32bit git version and when approaching 1.4 Gb it gives me lua error about "getperlinnoise or possibly no memory error". My view is 240 nodes, even on default mapgens with forests it can break 32 bit limit.

Also, MT-related complaint... we need flowing water sound and very slight wind sound with tree leaves wind sound, that will be so amazing in this environment.

Getting some crashes, info in debug.txt, valleys mapgen 2.2 + krocks build of mt from 15 dec 2015:

Code: Select all

2015-12-18 18:54:47: [Emerge-0]:  >> === FATAL ERROR ===
2015-12-18 18:54:47: [Emerge-0]:  >> Unknown exception (Exception 0xC0000029) at 0x77010B0A
2015-12-18 18:54:47: [Emerge-0]:  >> Failed to save dump

User avatar
kaadmy
Member
Posts: 706
Joined: Thu Aug 27, 2015 23:07
GitHub: kaadmy
IRC: KaadmY
In-game: KaadmY kaadmy NeD

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by kaadmy » Post

Fixerol wrote:[...]
we need flowing water sound and very slight wind sound with tree leaves wind sound, that will be so amazing in this environment.
[...]
You mean like this: https://github.com/kaadmy/pixture/tree/ ... s/ambiance

No wind sound yet, but could be added in a couple of minutes.
Feel free to make a PR for more ambient sounds :)
Never paint white stripes on roads near Zebra crossings.

Pixture

User avatar
Fixer
Member
Posts: 904
Joined: Sun Jul 31, 2011 11:23
IRC: Fixer
In-game: Fixer
Location: Ukraine

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Fixer » Post

kaadmy wrote:
Fixerol wrote:[...]
Feel free to make a PR for more ambient sounds :)
I've listened to that sounds, their quality is awful, feels like 8KHz 32kbit/sec mono, please find better sources :} Maybe here, for example: http://www.freesound.org/search/?q=wind , same for birds
Also, I'm sorry for offtopic here.

User avatar
Gael de Sailly
Member
Posts: 845
Joined: Sun Jan 26, 2014 17:01
GitHub: gaelysam
IRC: Gael-de-Sailly
In-game: Gael-de-Sailly gaelysam
Location: Voiron, France

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Gael de Sailly » Post

paramat wrote:.. That is, of course, if the original author agrees to it.
Ok for merging, of course :)
The only problem is that I can't write in C++. I'll continue to code on the Lua. You can write it in the core, but you will manage it yourself.

I have to change the license for that ?
Just realize how bored we would be if the world was perfect.

User avatar
Gael de Sailly
Member
Posts: 845
Joined: Sun Jan 26, 2014 17:01
GitHub: gaelysam
IRC: Gael-de-Sailly
In-game: Gael-de-Sailly gaelysam
Location: Voiron, France

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by Gael de Sailly » Post

I don't manage to compile valleys_c :

Code: Select all

CMakeFiles/minetest.dir/mapgen_v7.cpp.o: in function « MapgenV7::generateCaves(short) »:
mapgen_v7.cpp:(.text+0x38f3): undefined reference to « CaveV7plus<MapgenV7>::CaveV7plus(MapgenV7*, PseudoRandom*) »
mapgen_v7.cpp:(.text+0x3964): undefined reference to « CaveV7plus<MapgenV7>::makeCave(irr::core::vector3d<short>, irr::core::vector3d<short>, int) »
mapgen_v7.cpp:(.text+0x398e): undefined reference to « CaveV7plus<MapgenV7>::CaveV7plus(MapgenV7*, PseudoRandom*) »
mapgen_v7.cpp:(.text+0x39f5): undefined reference to « CaveV7plus<MapgenV7>::makeCave(irr::core::vector3d<short>, irr::core::vector3d<short>, int) »
mapgen_v7.cpp:(.text+0x3a14): undefined reference to « CaveV7plus<MapgenV7>::CaveV7plus(MapgenV7*, PseudoRandom*) »
mapgen_v7.cpp:(.text+0x3a7c): undefined reference to « CaveV7plus<MapgenV7>::makeCave(irr::core::vector3d<short>, irr::core::vector3d<short>, int) »
mapgen_v7.cpp:(.text+0x3a8e): undefined reference to « CaveV7plus<MapgenV7>::CaveV7plus(MapgenV7*, PseudoRandom*) »
mapgen_v7.cpp:(.text+0x3af6): undefined reference to « CaveV7plus<MapgenV7>::makeCave(irr::core::vector3d<short>, irr::core::vector3d<short>, int) »
collect2: error: ld returned 1 exit status
make[2]: *** [bin/minetest] Erreur 1
make[1]: *** [src/CMakeFiles/minetest.dir/all] Erreur 2
make: *** [all] Erreur 2
The error message was partly in French, I've translated.
Just realize how bored we would be if the world was perfect.

User avatar
duane
Member
Posts: 1715
Joined: Wed Aug 19, 2015 19:11
GitHub: duane-r
Location: Oklahoma City
Contact:

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by duane » Post

Gael de Sailly wrote:I have to change the license for that ?
You would just have to give permission for Valleys C to switch from gpl3 (derived from the original) to lgpl2.1, which matches the minetest game, since your copyright is the only one on a different license.

Edit: The Valleys C support mod (the lua part), which contains all the graphics peculiar to valleys, is still (and can remain) gpl3. The actual mapgen only creates terrain and water and uses the minetest default game for vegetation, etc. unless told otherwise.
Last edited by duane on Sat Dec 19, 2015 02:38, edited 1 time in total.
Believe in people and you don't need to believe anything else.

User avatar
duane
Member
Posts: 1715
Joined: Wed Aug 19, 2015 19:11
GitHub: duane-r
Location: Oklahoma City
Contact:

Re: [Mod][WIP] Valleys Mapgen [valleys_mapgen]

by duane » Post

Gael de Sailly wrote:I don't manage to compile valleys_c :

Code: Select all

CMakeFiles/minetest.dir/mapgen_v7.cpp.o: in function « MapgenV7::generateCaves(short) »:
mapgen_v7.cpp:(.text+0x38f3): undefined reference to « CaveV7plus<MapgenV7>::CaveV7plus(MapgenV7*, PseudoRandom*) »
mapgen_v7.cpp:(.text+0x3964): undefined reference to « CaveV7plus<MapgenV7>::makeCave(irr::core::vector3d<short>, irr::core::vector3d<short>, int) »
mapgen_v7.cpp:(.text+0x398e): undefined reference to « CaveV7plus<MapgenV7>::CaveV7plus(MapgenV7*, PseudoRandom*) »
mapgen_v7.cpp:(.text+0x39f5): undefined reference to « CaveV7plus<MapgenV7>::makeCave(irr::core::vector3d<short>, irr::core::vector3d<short>, int) »
mapgen_v7.cpp:(.text+0x3a14): undefined reference to « CaveV7plus<MapgenV7>::CaveV7plus(MapgenV7*, PseudoRandom*) »
mapgen_v7.cpp:(.text+0x3a7c): undefined reference to « CaveV7plus<MapgenV7>::makeCave(irr::core::vector3d<short>, irr::core::vector3d<short>, int) »
mapgen_v7.cpp:(.text+0x3a8e): undefined reference to « CaveV7plus<MapgenV7>::CaveV7plus(MapgenV7*, PseudoRandom*) »
mapgen_v7.cpp:(.text+0x3af6): undefined reference to « CaveV7plus<MapgenV7>::makeCave(irr::core::vector3d<short>, irr::core::vector3d<short>, int) »
collect2: error: ld returned 1 exit status
make[2]: *** [bin/minetest] Erreur 1
make[1]: *** [src/CMakeFiles/minetest.dir/all] Erreur 2
make: *** [all] Erreur 2
The error message was partly in French, I've translated.
I don't think you're using the same version that I am, since I commented out the generateCaves function a while ago. [Actually, that's the v7 that's complaining, but it doesn't do so on my system.] The one I'm pushing to is https://github.com/duane-r/minetest/tree/valleys_c (zip from https://github.com/duane-r/minetest/arc ... leys_c.zip).

However, let me download everything fresh and check.

Edit: Ok, after cloning with:

Code: Select all

git clone https://github.com/duane-r/minetest.git
I checkout valleys_c:

Code: Select all

git checkout valleys_c
I configure:

Code: Select all

cmake . -DRUN_IN_PLACE=TRUE
and make:

Code: Select all

make
and after several eons... it compiles with the usual error about the locale directory, but it works.

I modified the cavegen.* files to use a template, so that I could have two versions, for v7 and for valleys, but I may end up striking the v7 caves from valleys altogether. In any case, it's not affecting compile for me.

What system/compiler are you using? Maybe other compilers aren't dealing with templates the same way.
Believe in people and you don't need to believe anything else.

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 15 guests