Skip to content

Validator Checks

Guy Friley edited this page Nov 6, 2026 · 1 revision

Validator Checks

maptools/validate_map.py MAP.timber runs the checks below in order and prints PASS or FAIL for each, with the measured value. It exits non-zero if any check fails. Checks marked optional only run when the extra input is supplied.

Format conformance

Check What it catches
terrain levels == MaxGameTerrainHeight+1 optional, needs --blueprints. The wrong global column depth, which crashes the game on load with no in-game error
terrain <= MaxMapEditorTerrainHeight optional. Terrain taller than the editor allows
voxel array length Array size does not equal Width x Height x 23
no gaps/floating voxels A column that is not solid from z=0 upward
WaterEvaporationMap, WaterMapNew (columns and outflows), SoilMoistureSimulator, SoilContaminationSimulator lengths Any water or soil array that is not Width x Height x 2
version matches game version.txt does not equal world.json's GameVersion
singleton shapes match reference optional, needs --reference. A singleton key or value type the shipped map does not have
timestamp format matches reference optional. A timestamp the game would not parse
every component known for its template optional. A component name the reference never uses on that template
component shapes conform to reference optional. A component key or value type that differs from the reference

Terrain and entities

Check What it catches
no unwalkable cliffs Any neighbouring columns differing by 2 or more
all entities grounded An entity whose Z is not the column's solid height
no overlapping footprints Two entities claiming the same tile
unique entity ids A duplicated UUID

River

Check What it catches
a through-channel exists at the designed bed in every row A row the river does not cross at the designed depth
bed descends north to south A flat bed, which does not flow
channel reaches the outlet row A river that ends before the map edge
no long flat stretch (30 rows or fewer at one bed level) Puddling
deep water exists for pumps (2 or more below bed) Fewer than 150 channel tiles deep enough to place a pump

Water sources and drainage

Check What it catches
sources sit in a channel A source placed on dry land
total inflow is sane (2 to 8) Too little water to irrigate, or enough to flood the valley
every channel tile is fed by a source Dry ditches
water drains off a map edge A river with no exit
no closed basin A channel tile that cannot reach any edge, which floods forever
reservoirs hold 900 or more blocks in drought Not enough stored water to survive the sources shutting off
reservoirs are fed A reservoir no channel reaches

Land use

Check What it catches
arable land >= 55% Water spread too narrow to farm
some dry high ground remains for building Nowhere to build without displacing crops

Settlement

Check What it catches
exactly one starting location Zero or multiple spawn points
clear level building zone at spawn >= 28x28 A cramped or uneven start
depot is out of the way but reachable (12 to 40 tiles) Caches blocking the build zone, or too far to haul from
all land walkable from spawn Islands of unreachable land
caches walkable from spawn A cache beavers cannot reach
no vegetation touching a cache Trees in a cache's access tile, which the game deletes on load
spawn is near water No water within 10 tiles of the starting location
caches within capacity More goods than a cache can hold
goods match storage type A liquid in a pile, or a box good in a tank
ReserveTank has no visualizer A component the game rejects on tanks
berries within reach No food nearby
trees within reach No logs nearby
scrap ruins within reach No scrap metal nearby

The check also prints the starting stock summary so you can confirm the caches hold what you intended.

Adding a check

Each check is one call to chk(label, condition, extra). Keep the label short and specific, and put the measured value in extra so a failure tells you how far off the map is, not just that it is wrong. Pull requests that add a check for a map failure you hit are the most useful kind.

Clone this wiki locally