benilla-re systems structs docs

GetAreaId

function · terrain · primitive

Address
0x69b120 · 157 bytes, up to 0x69b1bc
Signature
uint32_t __thiscall (void *this)
Meaning
Returns the MCNK area id of the chunk under a point, or 0
Confidence
verified, proof one
Finding
terrain/queries#area-id
Test
terrain::area_id_lookup_difftest

Finding: Area id in terrain: queries

0x69b120(point) returns the MCNK area id (+0x16c) of the chunk under the point, or 0 where no chunk is loaded; for a point off the map, that of the chunk its coordinates wrap to. Its chunk coordinates use k = 0.03; y's is one rounding of the product, x's two, the difference being stored as a float before it is multiplied.

The derivation is in the doc.

Callers 3

Callees 0

None by a direct call or jump.

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