Template:Infobox unit: Difference between revisions
Appearance
DTX Studios (talk | contribs) m Protected "Template:Infobox unit": Kept in step with the game's data by the maintainers ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) |
DTX Studios (talk | contribs) Infobox unit: each cost row on its own line (two costs ran together) |
||
| Line 99: | Line 99: | ||
|- | |- | ||
! colspan="2" style="background:#e3dccf;" | Cost | ! colspan="2" style="background:#e3dccf;" | Cost | ||
{{#if:{{{food|}}}| | |||
{{#if:{{{food|}}}|! Food | {{!}}- | ||
! Food | |||
{{!}} {{{food}}} | {{!}} {{{food}}} | ||
}} | |||
{{#if:{{{gold|}}}| | |||
{{!}}- | {{!}}- | ||
! Gold | |||
{{!}} {{{gold}}} | {{!}} {{{gold}}} | ||
}} | |||
{{#if:{{{wood|}}}| | |||
{{!}}- | {{!}}- | ||
! Wood | |||
{{!}} {{{wood}}} | {{!}} {{{wood}}} | ||
}} | |||
{{#if:{{{stone|}}}| | |||
{{!}}- | {{!}}- | ||
! Stone | |||
{{!}} {{{stone}}} | {{!}} {{{stone}}} | ||
}} | |||
{{#if:{{{leather|}}}| | |||
{{!}}- | {{!}}- | ||
! Leather | |||
{{!}} {{{leather}}} | {{!}} {{{leather}}} | ||
}} | |||
{{#if:{{{fibre|}}}| | |||
{{!}}- | {{!}}- | ||
! Fibre | |||
{{!}} {{{fibre}}} | {{!}} {{{fibre}}} | ||
}} | |||
|- | |||
! colspan="2" style="background:#e3dccf;" | Combat | |||
|- | |- | ||
! Hit points | ! Hit points | ||
Revision as of 21:16, 13 October 2026
This is the Infobox unit template. It shows a unit's balance numbers in a box at the top of its page.
Usage
{{Infobox unit
| name = Swordsman
| image = Icon_Unit_Swordsman.png
| caption =
| role = Infantry
| damage_type = Melee
| hp = 140
| attack = 14
| defense = 6
| range = 150
| siege_attack = 0
| cooldown = 1.7
| train_time = 24
| food = 60
| gold = 20
| wood =
| stone =
| leather =
| fibre =
| population = 1
| trained_at = [[Infantry Training Grounds]]
| ranged = No
| can_siege = No
| move_speed =
| status = In the game
}}
Parameters
| Parameter | Meaning |
|---|---|
name |
Name shown in the game. Defaults to the page name. |
image |
File name of the unit icon or portrait. |
caption |
Optional text under the image. |
role |
Tactical role: Villager, Infantry, Ranged, Cavalry, Siege, Support or Mage. |
damage_type |
Damage type label: None, Melee, Ranged, Siege, Fire, Water, Earth or Lightning. See Damage types: in the current build this label does not change damage. |
hp |
Maximum hit points. |
attack |
Damage per hit, before the target's armour. |
defense |
Flat armour, subtracted from every hit taken (minimum 1 damage per hit). |
range |
Attack range in Unreal units (uu), as the game data stores it; the box shows it in metres (100 uu = 1 m), measured to the edge of the target. |
siege_attack |
Not shown. The balance sheet has this column, but no game code reads it in the current build, so the box does not print it. |
cooldown |
Seconds between attacks. |
train_time |
Base seconds to train one unit. |
food, gold, wood, stone, leather, fibre |
Training cost. Leave empty for 0. |
population |
Population slots the unit uses. |
trained_at |
The building that trains it. |
ranged |
Yes or No. |
can_siege |
Yes or No. |
move_speed |
Optional. Movement speed in uu per second, only where a source confirms it; the box shows metres per second. |
status |
In the game, Story only, Not in the game, or Planned. |