benilla-re systems structs docs

CMapObj::FootprintCells

function · models · primitive

Address
0x6a5270 · 793 bytes, up to 0x6a5588
Signature
void __thiscall (CMapObj *this, uint32_t index, const float *box, void *list, uint32_t limit)
Meaning
Cuts a group into power-of-two tile cells and emits those the box overlaps
Confidence
verified, proof one
Finding
minimap/interior#group-tile-grid
Test
models::footprint_cell_rect_difftest, models::footprint_cell_size_difftest, models::footprint_count_bias_difftest, models::footprint_count_scale_difftest, models::footprint_extent_scale_difftest

Finding: Group tile grid in minimap: interior

0x6a5270(group, index, box, list, limit) emits the tiles of one group, unless the group's flags have 0x88 set. The group's model-space box is cut into a grid; each cell is a tile whose width and height are the next power of two of the texel extent, between 32 and 256 texels, at 0.5 yard per texel. A cell is emitted when its box overlaps the query box in x and y and the list has room. An entry has the group index, the column, the row and the six floats of the cell box.

offsetholds
+0x00group index
+0x04column
+0x08row
+0x0cmin x, min y, then z
+0x18max x, max y, then z

The derivation is in the doc.

Callers 1

Callees 5

Calls and jumps by a bare address, from tables/calls.tsv.