Converting games from 2.5D to 3D is simple – make a terrain, put some 3D houses and units, setup perspective projection camera. Game logic still remains the 2D. Starting from the top – is it really that simple to make a terrain in 3D?
Before we start, there are several approaches to making a terrain in 3D, let’s list them:
- terrain that is made from unit cubes (Minecraft)
- large uniform grid terrain with slopes (Transport Tycoon Deluxe)
- mostly heightmap terrain (Majesty 2, Banished)
- custom modeled terrain based on a heighmap (Settlers 7)
- voxel terrain (can’t remember any recent examples)
Each has an obvious pros and some cons. Blocky-slopy styles are simple to code, but they lack artisticity, they look too “mechanical” for a kind of game we want to make. Heightmaps are more natural looking, smooth, however that is their weakness, they are good for hills, but there’s just no way to make a nice mountain with sharp creases and cliffs. Voxel terrains are out of question for they are too performance greedy and hard to code – I can’t even remember which modern games use them. Custom modeled terrain sounds like the best artistic option .. until we think about mapmakers, who should to be able to use simplest tools to create maps. Even us, I shiver when thinking about modeling terrain for at least a complete campaign (20 maps) … we need something simpler.
Having this in mind it’s time to mix in few ideas and find a unique method. Main goal was to invent an approach that would combine simplicity, yet allow to use artistic elements. Something that is rigid, yet malleable within bounds. Grid-based with heights editing sounds familiar, but in 3D. Another consideration is to allow to mix terrain types without need of creating N^2*3/2 transition models. What if we have generic terrain types (flat, water, mountain) and generic transitions between them (soft and hard). In theory that allows for 4 terrains meeting at single tile, but that is way ahead. Let’s try something simpler in 3D modelling app first:
These are generic 3D tiles of transitions (flat-flat) and sharpness (hard, medium, soft, none). The idea is that tile morphs to fit terrain heights and can be combined with each other (top-right). Of course that leaves the question about combining those with each other (top-left) – now we need transitions between transitions! xD
This is one of the first working in-game implementations (which dates back to 31-Oct-2013):
There are only two surfaces (water and grass) and a sharp transition between them. Important thing is that this image consists of only 4 models, rotated and morphed by height. There’s also pixely texture, that was removed later on in favor of surface colors.