Where the ore is
Ore coordinates are not written out by hand: everybody's map is different, and the search is one line
ubind @monoulocate ore core true @copper oreX oreY found buildingucontrol mine oreX oreY 0 0 0Two lines find copper and send the mono to mine it. On this map the nearest copper lies on tile
12 7 — that is where the unit flies, and cargo starts growing.
| Field | What is in it when searching for ore |
|---|---|
| first | ore |
| second | a block flag — unused when searching for ore |
| third | “search for an enemy” — also unused |
| fourth | the item: @copper, @lead, @titanium |
| fifth and sixth | where to put the tile’s coordinates |
| seventh | whether it was found |
| eighth | the building — ore has none, emptiness arrives |
ulocate has eight fields for all four kinds of search at once, and the spare ones are simply
not looked at. The game’s editor shows this plainly: some fields go dim as soon as you
choose ore.
It finds the one nearest the unit
Section titled “It finds the one nearest the unit”The same map also has lead — on the other side. The search gives 5 3, because it measures
distance from the unit, not from the processor and not from the core.
So two units running the same program fly to different deposits: each to its own nearest one. There is no need to spread them over the map separately.
What counts as ore
Section titled “What counts as ore”The search looks for a tile the wanted item is mined from. It looks not only at the overlay — the map layer where ores are drawn — but at the floor itself: a sand floor drops sand, and for the search that is ore like any other.
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.