Make Marker
A drawing over the map that the player sees: a circle over a point, a caption, an arrow, a line
makemarker shape 1 8 7 1makemarker text 2 8 3 1makemarker line 3 4 5 1Three markers: a shape, a caption and a line. They appear on the map itself — not on a display but over the world, and the player sees them.
| Field | What is in it |
|---|---|
| first | the kind of marker |
| second | the id: what it is found by later |
| third and fourth | coordinates in tiles |
| fifth | whether to replace a marker with that id if one already exists |
A marker lives on its own
Section titled “A marker lives on its own”That is the main difference from drawing on a display. A display has to be redrawn every time; a marker is placed once and stays on the map until it is removed.
setmarker remove 1 0 0 0Hence the fifth field: makemarker with the same id and replace = 0 does nothing if the
marker already exists. That is exactly how it is placed inside a loop — the program calls
makemarker every iteration and the marker does not multiply.
What kinds there are
Section titled “What kinds there are”| Kind | What it draws |
|---|---|
shape |
a polygon: a circle, a triangle, a square |
text |
text on the map |
shapeText |
a shape with a caption under it |
line |
a segment between two points |
texture |
a picture — one of the game’s sprites |
quad |
a quadrilateral given by four corners |
point |
a point visible only on the minimap |
All of them are configured by one instruction — setmarker: colour, radius, rotation, text, drawing layer. Right
after creation a marker is plain: a white quadrilateral at the given point.
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.