Super Flat Mapgen

For people working on the C++ code.
Post Reply
User avatar
PilzAdam
Member
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam
Location: Germany

Super Flat Mapgen

by PilzAdam » Post

Obsolete You can add "flat" to "mg_flags" in minetest.conf to get a flat map in Minetest 0.4.5 or later.

Hello everyone!
Many people try to make a flat mapgen by creating mods in Lua. This mods are very slow and also have some bugs.
So I changed the C++ mapgen to be super flat and here is the result:
Image

There is one layer of grass, one dirt and the rest is stone (there are no caves).
The trees and everything that is added by Lua mods (by default ores and junglegrass) spawns normally.

You have to compile the source yourself and be sure to create a new world and dont open existing worlds with this.

It is not only super flat it is also super fast because I deleted 90% of the old mapgenerator.

I try to keep this branch up-to-date with the official minetest.

GitHub:
https://github.com/PilzAdam/minetest/tree/flat

Download the source:
https://github.com/PilzAdam/minetest/archive/flat.zip

Windows build:
http://minetest.ru/builds/minetest-flat ... 96ad63.zip (provided by thexyz)
Last edited by PilzAdam on Thu Mar 14, 2013 18:52, edited 1 time in total.

Ragnar
Member
Posts: 849
Joined: Thu Oct 25, 2012 15:19
Location: Estonia
Contact:

by Ragnar » Post

I am from the near future, here to warn everybody of the huge fame Minetest is gonna get soon!
Proof:
PilzAdam wrote:
Ragnar wrote:btw, how do i compile?
what do i need, what are the commands etc...
Read the Readme.txt file.
Oh, and please bring all of your questions/comments in one post and dont post multiple times in a row. Think before you post :-)
Dont say, i didnt warn you!
Last edited by Ragnar on Fri Jan 11, 2013 15:39, edited 1 time in total.
Are you saying that I put an abnormal brain into a seven and a half foot long, fifty-four inch wide GORILLA?

Ragnar
Member
Posts: 849
Joined: Thu Oct 25, 2012 15:19
Location: Estonia
Contact:

by Ragnar » Post

btw, how do i compile?
what do i need, what are the commands etc...
Are you saying that I put an abnormal brain into a seven and a half foot long, fifty-four inch wide GORILLA?

User avatar
PilzAdam
Member
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam
Location: Germany

by PilzAdam » Post

Ragnar wrote:btw, how do i compile?
what do i need, what are the commands etc...
Read the Readme.txt file.
Oh, and please bring all of your questions/comments in one post and dont post multiple times in a row. Think before you post :-)

User avatar
PilzAdam
Member
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam
Location: Germany

by PilzAdam » Post

Windows build by thexyz added (see first post).

Ragnar
Member
Posts: 849
Joined: Thu Oct 25, 2012 15:19
Location: Estonia
Contact:

by Ragnar » Post

hey, if i make an Ubuntu 12.10 i686 build, it will work on all of the other ones with Ubuntu 12.10 i686?
AWESOME *starts making build*
Are you saying that I put an abnormal brain into a seven and a half foot long, fifty-four inch wide GORILLA?

4aiman
Member
Posts: 1208
Joined: Mon Jul 30, 2012 05:47

by 4aiman » Post

PilzAdam, is that possible to make it configurable whether use flat or normal mapgen?

Also, some thoughts:
It would be nice to have the ability to make an influence onto the mapgen using some variables defined in the world.mt, like
- type of mapgen*: [normal/super flat/external]
- caves average size** [some integer value]
- enabled_bioms [list of enabled bioms, so it would be possible to make a map with only 1-2 biomes***]
- zero_ground**** [some integer value]

_________
Commentaries:
* I doubt there are people who would rush in and start to code different mapgens but it would be nice to define shared library path so it's one and only exported function called smth like "generate_world" would be called instead of in-built. That will save anyone from recompilation. Those who afraid of malicious software may consider this as a plug-in. No one's afraid of plug-ins, right? ;)
** super flat world too! setting this to 0 will result in no caves at all
*** may be useful for some contest/survival maps
**** there are too much of unused space up in the sky, so this value will define which height is considered as 0 meters above the sea.

Please, do comment.

User avatar
PilzAdam
Member
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam
Location: Germany

by PilzAdam » Post

4aiman wrote:PilzAdam, is that possible to make it configurable whether use flat or normal mapgen?

Also, some thoughts:
It would be nice to have the ability to make an influence onto the mapgen using some variables defined in the world.mt, like
- type of mapgen*: [normal/super flat/external]
- caves average size** [some integer value]
- enabled_bioms [list of enabled bioms, so it would be possible to make a map with only 1-2 biomes***]
- zero_ground**** [some integer value]

_________
Commentaries:
* I doubt there are people who would rush in and start to code different mapgens but it would be nice to define shared library path so it's one and only exported function called smth like "generate_world" would be called instead of in-built. That will save anyone from recompilation. Those who afraid of malicious software may consider this as a plug-in. No one's afraid of plug-ins, right? ;)
** super flat world too! setting this to 0 will result in no caves at all
*** may be useful for some contest/survival maps
**** there are too much of unused space up in the sky, so this value will define which height is considered as 0 meters above the sea.

Please, do comment.
If you want this, code it! Sorry, but I wont do all of this. Maybe I will make the flat mapgen configureable, but dunno.

4aiman
Member
Posts: 1208
Joined: Mon Jul 30, 2012 05:47

by 4aiman » Post

You've got it wrong, PilzAdam.
Sorry if that sounded like I want you to make that.
I only asked of you if you would make switching normal/superflat by configuring that. (And you have answered already - thanks for quick reply!)

I'm not asking to make anything else. By no means. That's just some thoughts in case someone can and will do that.
As for myself - I can't at the moment, first I must learn c++ ...
Last edited by 4aiman on Fri Jan 11, 2013 19:23, edited 1 time in total.

User avatar
dannydark
Member
Posts: 428
Joined: Fri Aug 12, 2011 21:28
Location: Manchester, UK

by dannydark » Post

Nice work PilzAdam, btw you do know that mapgen v7 has a flat type biome, so in theory you could just setup a single biome world using the flat biome to achieve the same results, although I'm not sure its ready for upstream merge yet.

Also hmmmm's new mapgen branch adds a lot of config options so maybe what some of the people above are asking for is already part of that branch.

In fact I should speak with hmmmm to see what's needed to be done to the new mapgen before its merged upstream as I've been using it now for a few months without any problems, although there is one commit I've seen in his branch that I don't have but its not related to the mapgen...but I will merge that with my local copy on my windows system just to make sure no issues arise.

Anyway nice work ^_^ flat worlds are always useful when building stupidly big mesecon structures.

Sokomine
Member
Posts: 4290
Joined: Sun Sep 09, 2012 17:31
GitHub: Sokomine
IRC: Sokomine
In-game: Sokomine

by Sokomine » Post

Thank you for your super flat world! It is very very helpful for importing Minecraft classic maps with my mcimport mod. With the normal mapgen, it took far too long to create a large enough free space. Also this is very useful for building and getting creative. Normal mapgen usually requires to flatten the landscape first.
A list of my mods can be found here.

tinoesroho
Member
Posts: 570
Joined: Fri Feb 17, 2012 21:55
Location: Canada

by tinoesroho » Post

Thank you! I've wanted something like this for a long time. :-)
We are what we create.

I tinker and occasionally make (lousy) mods. Currently building an MMO subgame and updating mods. Pirate Party of Canada member. Sporadic author. 21 years old.

My github:
https://github.com/tinoesroho/

User avatar
Calinou
Moderator
Posts: 3169
Joined: Mon Aug 01, 2011 14:26
GitHub: Calinou
IRC: Calinou
In-game: Calinou
Location: Troyes, France
Contact:

by Calinou » Post

We should have an option for this... looks good.

User avatar
NakedFury
Member
Posts: 151
Joined: Thu Dec 08, 2011 03:55

by NakedFury » Post

Other possible world types:
Waterworld
World with very very few water, only on caves or deep underground.

Jordach
Member
Posts: 4534
Joined: Mon Oct 03, 2011 17:58
GitHub: Jordach
IRC: Jordach
In-game: Jordach
Location: Blender Scene

by Jordach » Post

This is handy for the mesecons users out there.

User avatar
PilzAdam
Member
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam
Location: Germany

by PilzAdam » Post

This is obsolete now since you can add "flat" to "mg_flags" in minetest.conf (Minetest 0.4.5 or later).

User avatar
Luke123
Member
Posts: 51
Joined: Sun Mar 31, 2013 17:51

by Luke123 » Post

This is great! Less lag and a faster working game. This is useful for the mesecons mod because it leaves you with lots of room to create and build. This is perfect! Thx PlzAdam!

-Luke

Also known as Luca
Last edited by Luke123 on Mon Apr 01, 2013 20:53, edited 1 time in total.
My minetest username is <King>
BTW I like pie <3

User avatar
PilzAdam
Member
Posts: 4026
Joined: Fri Jul 20, 2012 16:19
GitHub: PilzAdam
IRC: PilzAdam
Location: Germany

by PilzAdam » Post

Luke123 wrote:This is the best mod ever! Less lag and a faster working game. This is useful for the mesecons mod because it leaves you with lots of room to create and build. This is perfect! Thx PlzAdam!

-Luke

Also known as Luca
You dont have to use this, you can just add "flat" to "mg_flags" in minetest.conf
Also this isnt a mod, its an engine patch. Mods are written in Lua.

User avatar
Luke123
Member
Posts: 51
Joined: Sun Mar 31, 2013 17:51

by Luke123 » Post

PilzAdam wrote:
Luke123 wrote:This is the best mod ever! Less lag and a faster working game. This is useful for the mesecons mod because it leaves you with lots of room to create and build. This is perfect! Thx PlzAdam!

-Luke

Also known as Luca
You dont have to use this, you can just add "flat" to "mg_flags" in minetest.conf
Also this isnt a mod, its an engine patch. Mods are written in Lua.
That was a mistake, I know it is not a mod :-)
My minetest username is <King>
BTW I like pie <3

Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests