Game rules
What setrule changes and how each rule takes its value: a number, a switch, a content item or an area. Ten multipliers also need a team in the third field — without it the line does nothing (v160.4).
| Rule | Takes | Description |
|---|---|---|
currentWaveTime | numberin seconds | How many seconds are left until the next wave |
waveTimer | on/off | Whether the countdown to a wave is running |
waves | on/off | Whether this map has waves at all |
wave | number | The number of the current wave, no less than one |
waveSpacing | numberin seconds | How many seconds between waves |
waveSending | on/off | Whether to send a wave right now |
attackMode | on/off | Attack mode: the goal is the enemy cores |
enemyCoreBuildRadius | numberin tiles | How far from an enemy core building is forbidden |
dropZoneRadius | numberin tiles | The radius of the forbidden zone around a drop point |
unitCap | number | The limit on the number of units |
mapArea | four numbers | The playable part of the map. The only rule that needs all four fields |
lighting | on/off | Darkness on the map |
canGameOver | on/off | Whether the game can be lost |
ambientLight | number | The colour of the darkness — as a packed colour |
unitLight | on/off | Whether units give light in the dark |
solarMultiplier | number | A multiplier for solar panel output |
dragMultiplier | number | A friction multiplier: how much faster speed dies away |
ban | block or unit | Forbid a block or a unit type |
unban | block or unit | Lift a ban |
pauseDisabled | on/off | Forbid pausing |
musicVolume | number | Music volume, from zero to one |
buildSpeed | numberneeds a teamfrom 0.001 to 50 | The speed of building by a player |
unitHealth | numberneeds a teamat least 0.001 | Divides damage to units rather than raising their health |
unitBuildSpeed | numberneeds a teamfrom 0 to 50 | The speed at which units build |
unitMineSpeed | numberneeds a teamat least 0 | The speed at which units mine |
unitCost | numberneeds a teamat least 0 | A multiplier for the cost of units |
unitDamage | numberneeds a teamat least 0 | A multiplier for damage dealt by units |
blockHealth | numberneeds a teamat least 0.001 | Divides damage to buildings |
blockDamage | numberneeds a teamat least 0 | A multiplier for damage dealt by buildings |
rtsMinWeight | numberneeds a team | The strength threshold at which a squad decides to attack |
rtsMinSquad | numberneeds a teamwhole numbers only | How many units have to gather into a squad |
Data taken from Mindustry v160.4 by the project generators.
Unofficial fan project, not affiliated with Anuke. Mindustry sprites, fonts and translations © Anuke, used under GPL-3.0; Fira Code under OFL-1.1. Site code is GPL-3.0.