Thanks, Sig, but I owe a large amount of credit to Redrobes for getting my brain working with his city patterns (thanks Red).
Thanks, Sig, but I owe a large amount of credit to Redrobes for getting my brain working with his city patterns (thanks Red).
If the radiance of a thousand suns was to burst at once into the sky, that would be like the splendor of the Mighty One...I am become Death, the Shatterer of worlds.
-J. Robert Oppenheimer (father of the atom bomb) alluding to The Bhagavad Gita (Chapter 11, Verse 32)
My Maps ~ My Brushes ~ My Tutorials ~ My Challenge Maps
Cool job Ascension - I will have a similar hack at it in a while. Cities are a lot of work right now and I for one welcome some ways to automate some parts of it. We did scripts for tiles a while back and they work well. Robs dungeon script is certainly well developed now and I reckon that chugs out dungeons to a standard thats quite hard to match by hand. Terrain has almost always been scripted usually off of some random starting point too so if we can get cities into that same league then were really cookin.
I have always wanted a big app which makes great random terrain then fills it with virtual people which build houses get jobs, marry have kids which go on to get other jobs and so on building up the virtual world with a full list of buildings and people who live in them. A sort of genetic algo RPG world builder. Thats a bit of a way off at this point tho The bits of scripts and tools are like that metallic bits of The Terminator when hes all molten, coming together bit by bit. Maybe one day we will say "ah we can chug out terrain no problem and we can chug out cities no problem and dungeons too, we have character stat builder and all the monster stats and the scripts which run the rules to know who would likely win in battles so lets glue all of those parts together". Pipe dream I reckon but no harm in traveling on that road for a while huh ?
That's exactly where I'd like to go, creating an entire fantasy world from the ground up just by pushing a few buttons, then combine it with Sigurd's find of that awesome German terrain renderer, then get something like the Sims to populate the place and I could have my own world/ant farm and with some powerful 3d apps I could walk among the people. Might need to get some of Pixar's computers or ILM's for that tho
If the radiance of a thousand suns was to burst at once into the sky, that would be like the splendor of the Mighty One...I am become Death, the Shatterer of worlds.
-J. Robert Oppenheimer (father of the atom bomb) alluding to The Bhagavad Gita (Chapter 11, Verse 32)
My Maps ~ My Brushes ~ My Tutorials ~ My Challenge Maps
I wrote up a quick GIMP script that does MOST of this automatically.
Things I'd like to improve:
- Beveling the rooftops. Right now, this just sets the rooftops to a set color.
- Running the threshold to make the buildings interactively instead of setting values for them in the front end. If you guys know a way to do this, please let me know. This filter doesn't have the interactive/non-interactive flag.
- Any other suggestions you guys might have. :-)
The roads are generated using a Mosaic plug-in, and the somewhat roughened up by a displace map of random noise.
Great tutorial!
Last edited by sambrookjm; 02-02-2009 at 06:02 PM. Reason: Attachment
I think I've had this Deja Vu before...
Attached is a mod of your script. (funny to see how other code )
This adds a bevel roof layer (overlay mode)
I also changed the simple motion blur into a motion-blur/threshold alpha/gausian blur which (imoo) gives a better result. Also set the opacity down on this layer.
Funny that the threshold doesn't have an interactive mode... should post this on the gimp devel list as it could be an oversight.
I changed the road spacing and width to be /4 so the slider is in pixels.
I also changed where it registers. I moved it to File>Create, which is were (afaik) they gimp devels are suggesting image creation scripts should register.
-Rob A>
My tutorials: Using GIMP to Create an Artistic Regional Map ~ All My Tutorials
My GIMP Scripts: Rotating Brush ~ Gradient from Image ~ Mosaic Tile Helper ~ Random Density Map ~ Subterranean Map Prettier ~ Tapered Stroke Path ~ Random Rotate Floating Layer ~ Batch Image to Pattern ~ Better Seamless Tiles ~ Tile Shuffle ~ Scale Pattern ~ Grid of Guides ~ Fractalize path ~ Label Points
My Maps: Finished Maps ~ Challenge Entries ~ My Portfolio: www.cartocopia.com
Hopefully, it wasn't too difficult for you to follow! I'm still a relative neophyte when it comes to scripting this sort of stuff...
Yeah, that does give a better result. Very nice technique.
I was really surprised by that as well...but this is the first time I've used the threshold filter in a place where it would be useful to run it interactively.
*smack* Good catch. Those values were left over from when all of the layers were originally the full mage size. Then I realized that making them one-quarter size would make the script run much quicker and changed the script to do that...but forgot to change them back. I was just happy to get the darn thing working!
I'll remember that. Thanks for the tips and improvements!
I think I've had this Deja Vu before...
I made a couple of changes to your modded script after running it through a few more times.
I used your threshold-alpha filter on the building level to remove all of the buldings that were underneath the roads. With the feathered selection you used for the roads, there ended up being too many shadows. Running the threshold-alpha filter with a value of 200 on the town layer got rid of the buildings under the roads, which eliminated any extra shadows. The method you used to generate the shadows is still in place, though.
I also changed the script so that the random maps no longer have to be square. The maps can be anywhere from 300 to 3000 pixels in either dimension.
Your additions were noted in the comments in the script. Credit is given where credit is due!!
I attached a zip containing the new script, as well as a picture of what my run looked like with the default values. This was a great tutorial to code up, and now I know how to bevel stuff!
I think I've had this Deja Vu before...