Home Game Design • Generating fantasy maps

Generating fantasy maps

Martin O’Leary has created an excellent Fantasy Map Generator — and shared the source code!

I wanted to make maps that look like something you’d find at the back of one of the cheap paperback fantasy novels of my youth. I always had a fascination with these imagined worlds, which were often much more interesting than whatever luke-warm sub-Tolkien tale they were attached to.

At the same time, I wanted to play with terrain generation with a physical basis. There are loads of articles on the internet which describe terrain generation, and they almost all use some variation on a fractal noise approach, either directly (by adding layers of noise functions), or indirectly (e.g. through midpoint displacement). These methods produce lots of fine detail, but the large-scale structure always looks a bit off. Features are attached in random ways, with no thought to the processes which form landscapes. I wanted to try something a little bit different.

There are a few different stages to the generator. First we build up a height-map of the terrain, and do things like routing water flow over the surface. Then we can render the ‘physical’ portion of the map. Finally we can place cities and ‘regions’ on the map, and place their labels.

O’Leary does a first-rate job of explaining the process in clear and comprehensive terms. Best of all, he has provided a series of interactive examples, which are both fun and instructive.


Via Boing Boing:



Leave a Reply