Fractal heightmaps: Now with Gui!

Post your custom scenarios here. Saved games also welcome. All Transport Tycoon games acceptable (including TTDPatch and OpenTTD).
zooks
Transport Coordinator
Transport Coordinator
Posts: 262
Joined: 29 Jun 2006 08:36

Re: Fractal heightmaps

Post by zooks »

MisterX wrote:
On windows platform, you have 2 choices:

1.
In a command line terminal, type

c:\python23\python xxxx.py

2.
Open the python editor IDLE from the menu, and open xxxx.py, then press F5 to run it.
1 gives still an error, i think a do still something wrong, but with 2 i can make maps. But then he used the predefined sizes. Standard 256x256, so the first time i tried 2, i get a 256x256 map. But in mapgen.py, i easiely can change the standard, so as second a 2048 x 2048 was made. So i can make some heightmaps with it.
For (1), you first need to cd to the directory where mapgen.py is located. And use python27. Please post the error.

For (2), there is no way to pass command-line arguments withing idle as far as I know. Your solution to change them in the script itself seems best to me.
MisterX wrote:
How big could you choose seedstart and seedend? Are there some limits?
I believe the limit would be as big as python's ints go (around 10^18)
MisterX
Engineer
Engineer
Posts: 36
Joined: 25 Mar 2013 18:24

Re: Fractal heightmaps

Post by MisterX »

I made 100 1024x1024, to see how most maps behave. I think the most have to much water.


Image

Image

Image

Image

Image

Image

Image

Image

Image

Image

Image

Image

Image

Image

Image

Just some examples. There is really to much water and to less land, to my opion. In your first post, you said you force the script to make some water. Maybe you have to force the script a little less? Or maybe you could implement this as paramater. So you can just choose how much water you want. I don't know if this is possible.
For (1), you first need to cd to the directory where mapgen.py is located. And use python27. Please post the error.
I used the python27. I also place the py-file in c:/python27 itself. So far as i see, python doesn't like the : in c:\python27\python mapgen.py. He gives a SyntaxError: invalid syntax. Try it again without the : gives the same error on the word mapgen... Just tried some other possiblities, but still getting errors. I make somewhere a typo i guess... Or it is my lack of knowledge about python etc.
zooks
Transport Coordinator
Transport Coordinator
Posts: 262
Joined: 29 Jun 2006 08:36

Re: Fractal heightmaps

Post by zooks »

MisterX wrote:I made 100 1024x1024, to see how most maps behave. I think the most have to much water.

Just some examples. There is really to much water and to less land, to my opion. In your first post, you said you force the script to make some water. Maybe you have to force the script a little less? Or maybe you could implement this as paramater. So you can just choose how much water you want. I don't know if this is possible.
I don't think this would be simple. But in my experience, the amount of water is quite random and varies a lot in different maps. I got some huge continents out of it. I mostly create ~500 maps, then quickly look over the coloured images for maps that I find interesting.
MisterX wrote:
For (1), you first need to cd to the directory where mapgen.py is located. And use python27. Please post the error.
I used the python27. I also place the py-file in c:/python27 itself. So far as i see, python doesn't like the : in c:\python27\python mapgen.py. He gives a SyntaxError: invalid syntax. Try it again without the : gives the same error on the word mapgen... Just tried some other possiblities, but still getting errors. I make somewhere a typo i guess... Or it is my lack of knowledge about python etc.
Can you copy paste the stuff here? I have no clue about working with windows..
MisterX
Engineer
Engineer
Posts: 36
Joined: 25 Mar 2013 18:24

Re: Fractal heightmaps

Post by MisterX »

zooks wrote:I don't think this would be simple. But in my experience, the amount of water is quite random and varies a lot in different maps. I got some huge continents out of it. I mostly create ~500 maps, then quickly look over the coloured images for maps that I find interesting.
I modified some numbers of the script and i see indeed a huge variation between the maps. Some maps are almost fully filled with water (99+%), other maps hasn't almost none water. Some maps are filled with one or more Island, the other map is almost filled with land, but with some lakes. In again an other map, there seems to be a kind of river crossing the map (altrough they are mostly way to big, so you can't really build bridges over it).
zooks wrote:Can you copy paste the stuff here? I have no clue about working with windows..
It is not really an issue for me. The other way works fine for me. Just clicking twice on mapgen.py is also an option.
MisterX
Engineer
Engineer
Posts: 36
Joined: 25 Mar 2013 18:24

Re: Fractal heightmaps

Post by MisterX »

Made some non-islands map. Delete the very bad ones and attach the some better ones. Some are maybe not useful for 2048x2048, but you can cut off a part of the map and make it 1024x2028 or something like that.

In attachment:
256x256 maps: 30
2024x2024 maps: 108

Added the colored and greyed maps. So you could have a look at both.

http://www.sendspace.com/file/8x89g8

(The forumupload is very slow, so i decides to use sendspace to upload the file)
zooks
Transport Coordinator
Transport Coordinator
Posts: 262
Joined: 29 Jun 2006 08:36

Re: Fractal heightmaps

Post by zooks »

I made a Gui, it's added in the first post :D

cheers!
leifbk
Chairman
Chairman
Posts: 814
Joined: 23 Dec 2013 16:33
Location: Bærum, Norway

Re: Fractal heightmaps: Now with Gui!

Post by leifbk »

newmap.png
newmap.png (58.19 KiB) Viewed 3480 times
I like playing with ships, that's why I started to search for a map generator able to create continents and archipelagoes. I've downloaded your script, and I'm currently playing on a 512x512 map made from a generated heightmap, with parameters {13, 2}. Great work! :bow:

I suppose that if you want to create a map with continents, you may set the midpoint to zero in the first iteration, and for archipelagoes also in the second and maybe third iteration.

I'd like to see a little smoother map, though, as well as some more flat land. The two islands / continents to the southeast are too hilly even for my taste, even if it looks a lot like Norway. I haven't studied the script thoroughly yet, as I was too eager to start playing :D
Post Reply

Return to “Scenarios and Saved Games”

Who is online

Users browsing this forum: No registered users and 20 guests