s_gatherHalfCell
global · terrain
- Address
0x86aa2c· 4 bytes, up to0x86aa2f- Type
float- Meaning
- Holds 0.5, taken off a cell coordinate before rounding
- Confidence
- verified, proof one
- Finding
- terrain/collide#terrain-gather
Finding: Terrain gather in terrain: collide
0x6aa8b0(box, list, mask, owner) advances the two query counters, empties the list, gathers the
map objects' facets (0x6aaab0), and, unless the map is one object, the terrain's: the box's
corners map to cells by u = (17066.666 − x)·0.24, each a float, taken − 0.5 and rounded, and
every chunk whose cells the box touches is gathered with the cell rectangle. The box must lie
inside [0, 34133.332) on both axes. It returns 0 when a step fails.
The derivation is in the doc.