Hi,

I was told that this place perhaps could help out with some ideas for a small problem I'm having.

I work on a small strategy game for the iPad and it uses maps that vary in scale from 1x1 km to about 3x3 km. The maps are rural countryside and represent something like 18th to 19th century Europeanish terrain. They look something like this:

Attachment 60698

Currently the maps are created by hand using a crude map editor that I made for the game. The maps are saved in a simple vectorized format and then rendered in the game. Making the maps totally by hand is very tedious, as every terrain type has to be plotted point for point by hand. Making roads is mind numbingly boring. So I started making a small generator for the editor that can auto generate the basic structure of a map and then allow me to do some fine tuning by hand (add objectives, adjust units etc). So far I get quite nice woods and scattered trees based on some Perlin noise maps that I run some filters on.

The editor is open source if someone would be interested, but it is obviously totally tailored to my needs and is definitely no marvel of software engineering.

Now I'd like to add roads to the maps too. For this I have basically no idea how to proceed. There should be a few roads on the map and a crossroad or two. The roads would most likely exit the map on some edge and are basically old gravel roads, no straight autobahns. However I'm stuck as to what would be a good algorithm for making roads. Randomly doing it makes it all look like spaghetti and that's no good... So, does any wizard here know of some algorithm that would allow me to generate roads that are at least a bit sane? I only need a basic set of waypoints for the road, I can manually do some smoothing to get rid of sharp corners as well as create the polygons.

Any ideas? Algorithm names, papers, URL:s etc? I'd be very happy for some pointers.