Null Vector Studios

Simulating a planet to generate a map for a 4X game

Sep 29, 2026 · The Next Game


Simulating a planet to generate a map for a 4X game

Take the tank from the last post. It rolls out of the factory with a diesel engine, a decent gun and enough armor to survive the first hit. On a world like ours, it's a perfectly good tank.

On a planet with twice Earth's gravity, the same tank weighs twice as much, and the first hill brings it to a crawl. On a world where nothing ever lived, there is no oil in the ground, so the diesel has to go: hydrogen, batteries or a heavy nuclear reactor, each with its own drawbacks. And where the air cannot sustain a flame, the diesel needs its oxygen delivered too.

A world where nothing ever lived: grey dust, bare rock and worn-down mountains, and no oil in the ground.
A world where nothing ever lived: grey dust, bare rock and worn-down mountains, and no oil in the ground.

All of these rules come from real physics. Once the rules worked like that, a map painted with random noise stopped fitting. If oil comes from ancient life, and life needs water, then the water has to come from somewhere too. We wanted maps that are believable, where every desert, forest and river is there for a reason. So the map is built roughly the way a planet is.

The physics runs through the whole generator. Ice only forms where snow actually falls, so a cold, dry world stays bare rock. High ground is colder than the lowlands. Metal tends to be richer in the mountains, and oil in the lowlands. Most of this post follows one thread of it, the rain: one planet, the same region at every step.

Rock: where the mountains come from

Tectonic plates, each arrow showing which way its plate drifts. The mountain range rises along the seam where the plates push into each other
Tectonic plates, each arrow showing which way its plate drifts. The mountain range rises along the seam where the plates push into each other.

Every map starts with tectonic plates. The surface is split into a handful of them, each drifting in its own direction at its own speed. Where two plates collide, the crust piles up into a mountain belt along the seam. Where they pull apart, the land sinks into rift valleys and inland seas.

Elevation: the high ground follows the collision seam between the plates
Elevation: the high ground follows the collision seam between the plates.

The planet's age decides how much of that survives. On a young world the mountain ranges are wide and tall. On an old one, billions of years of erosion have worn them down to hills. Mountains slow down armies and supply lines, and as we will see, they also decide where the rain falls.

Sun and sea: where the heat goes

Temperature: warm bands near the equator, cold toward the poles, with the sea softening the coasts
Temperature: warm bands near the equator, cold toward the poles, with the sea softening the coasts.

Sunlight is strongest at the equator and weakest toward the poles, so the planet starts in warm and cold bands. Then the ocean moves the heat around.

Ocean currents: the water runs west near the equator and turns along the coastlines into great loops. Red arrows carry water warmer than its latitude, blue colder
Ocean currents: the water runs west near the equator and turns along the coastlines into great loops. Red arrows carry water warmer than its latitude, blue colder.

Currents are driven by the wind and shaped by the coastlines. Where a continent blocks them, they turn into great circular loops, and the direction the planet spins decides which way the loops turn. Warm water travels from the equator toward the poles along one side of each loop, and cold water comes back along the other. The sea then softens the land beside it: coasts are milder than the interior, and one coast can be warm while another at the same latitude is cold.

Wind: the spin and the air

Wind: trade winds blow in off the sea near the equator, westerlies further out. Red arrows bring warmer air, blue colder
Wind: trade winds blow in off the sea near the equator, westerlies further out. Red arrows bring warmer air, blue colder.

The planet's spin sets the wind belts. Near the equator the trade winds blow toward it; further out, the westerlies blow the other way; near the poles, the easterlies return. Between the belts are calm zones where the wind dies.

Every planet has its own rotation speed, and a faster spin means stronger winds. Occasionally a planet spins backwards, which reverses every wind and current on the map. The atmosphere matters too: thicker air blows harder.

The land bends the pattern. Warm continents pull air in off the sea, cold seas push it away, and mountains deflect the wind around them. That bending is what keeps the map from looking like stripes.

Rain: the two sides of a mountain

Rainfall: the windward coast is soaked, while the land behind the mountains gets very little
Rainfall: the windward coast is soaked, while the land behind the mountains gets very little.

Rain needs moisture, and moisture comes from the sea. Warm water evaporates much faster than cold water, so warm seas load the passing air with far more of it.

The wind carries that moisture inland, and some of it falls on every stretch of land it crosses. But when the air meets a mountain range, it is forced upward, cools, and drops most of what is left on the windward slope. By the time it crosses the ridge there is little left, and the far side lies in a rain shadow. The same thing happens where two winds meet and push the air up between them, which is why the equator gets a belt of heavy rain.

From rain to terrain

Rain against heat: forest and swamp where the rain falls, dry land and desert behind the ridge
Rain against heat: forest and swamp where the rain falls, dry land and desert behind the ridge.

Rain alone does not decide whether land is green. What matters is rain against heat. The same rainfall that keeps a cold steppe green leaves a hot plain dry. So a hot planet needs torrential rain to grow forests, and a cold one turns to tundra and ice.

Water flow: rain gathers into rivers on the wet side of the range and runs down to the sea. Thicker, darker arrows carry more water
Water flow: rain gathers into rivers on the wet side of the range and runs down to the sea. Thicker, darker arrows carry more water.

Rivers come from the same rain, merging as they run downhill toward the sea.

Put it all together and you have the map at the top of this post. The plates raised the mountains, the sea and the wind brought the rain, and the mountains decided where it fell. Forests and wetlands grew on the wet side, and desert spread on the other.

And it affects the gameplay too. Sunlight, wind and rain decide where solar arrays, wind turbines and rain collectors are worth building.

Planet types: pick a world, or build one

Every map is generated from a planet type: a set of dials for gravity, atmosphere, oxygen, temperature, water, the planet's age, and the plants and animals that live on it. The generator takes those dials and a seed, and builds the world from them.

The game comes with an assortment of planet types grounded in real physics: Earth-like worlds, hot deserts, frozen ice worlds, barren worlds with no vegetation, heavy worlds with thick, toxic air. Or you can let every dial roll at random for a new world each game.

If none of those is what you want, you can make your own planet types. You can even make exotic or unrealistic ones, like a planet teeming with plants and animals that has no water or oxygen.

An alien world overgrown with pink forest. Planet types can take the generator a long way from Earth
An alien world overgrown with pink forest. Planet types can take the generator a long way from Earth.

Where realism and balance disagree

A real planet is not fair. Earth did not give every country the same oil or the same rivers, and a map built purely from physics would not either. That is a problem in multiplayer. One player starts in a fertile valley, another on a windswept rock.

We made the starting positions balanced rather than realistic. They are picked to be fair in spacing, terrain and resources.

Beyond the starting area, realism currently wins over balance. We are looking into adding settings that make the maps more balanced.

What do you think: should the maps favor balance or realism?

-Zeikko

1 comment

  • Anonymous 104429Sep 29, 2026

    balancing fairness vs realism in a 4x game, whether it be the map or any other game element, is a near impossible question to answer for the designer because it depends on the preference of the individual player and the purpose of the individual scenario. A multiplayer tournament game demands fairness. A solo immersive scenario demands realism. The best a designer can do is provide a configuration switch at scenario generation time for realism vs fairness, but that of coarse increases design and development complexity which might stress the development timeline. For me personally, I lean heavily towards realism.

← All posts