paramat wrote:Do you want to know a distant location before it has been generated?
burli wrote:paramat wrote:Do you want to know a distant location before it has been generated?
That would be fine, but no. I just want to make a lua mod that places schematics in the map and I want to find good places
duane wrote:The easiest way to find something is to put it there yourself. It's pretty easy to flatten an area unobtrusively.
burli wrote:Really flat regions are rare, but there are areas with really low hills.
I need an algorithm to find these areas.
maximum and minimum height.
hajo wrote:burli wrote:Really flat regions are rare, but there are areas with really low hills.
I need an algorithm to find these areas.
I found mapgen v7 can generate very 'square-wavy' terrain,
e.g. a plateau (high-up, at y>80), steep cliff down to a lake at y=1,
followed by another steep cliff up to the next high plateau.
You could use worldedit to pave a 'ceiling' over that lake,
and have a single large plateau, with a 'cave' below.maximum and minimum height.
Wouldn't find such an area directly.
I recommand to fly around, to see the landscape...
Maybe there is a mod with some flying vehicle, and a programmable autopilot ?
Also, you could make new land over water.
Best for farming - each block is in range of water,
no need for irrigation/trenches, wells etc.
burli wrote:Really flat regions are rare, but there are areas with really low hills.
I need an algorithm to find these areas.hajo wrote:You could use worldedit to pave a 'ceiling' over that lake, ..
Also, you could make new land over water.
I want to make a mod that can place structures automatically. .. I want to use the map as is
hajo wrote:One problem with that algorithm is that the mapgenerator works 'on demand'.
So you cannot check areas the player hasn't visited yet.
burli wrote:You are right, but I don't want to run this "blind". First I want to find relative flat regions.
Where can I find your code? In your old funcaves mod?
I would use the heightmap within 'on generate' and break it into 16x16 blocks and analyse the range of heights in each block, if it's small enough (=< 1 or 2) flatten the surface of the block down to the lowest height.
duane wrote:I think you're doing it the hard way, but this definitely should work (except that the heightmap is frequently incorrect in valleys mapgen):
burli wrote:I always notice that I have a very different picture of Minetest. I don't want to build a map. I want to make a mod that can place structures automatically. And I don't want to modify the map (as less as possible). I want to use the map as is
Users browsing this forum: No registered users and 5 guests