CWorld::GetEntityAreaId
function · terrain · orchestration
- Address
0x6703a0· 203 bytes, up to0x67046a- Signature
uint32_t __fastcall (void *entity, uint32_t *areaId)- Meaning
- Writes the area id of an entity from its map object group or the terrain under it and returns 1
- Confidence
- verified, proof one
- Finding
- terrain/zones#entity-area-id
Finding: Entity area id in terrain: zones
0x6703a0 returns 1 and writes an area id for an entity, or returns 0. With the map-is-one-object
flag set it is the map record's field at +0x4c, failing when that is 0. The record is the
map table 0xc0daa8 entry for the loaded map id, checked against the highest id (0x6703ba, 0x6703bc); out
of range, or null, the read is of address 0x4c. Otherwise a null entity fails. The entity's first node decides: a group def (flags +0x8 bit
0x10) gives its WMOAreaTable row's AreaTable id when that is nonzero; a def with flags bit 0x4 gives
its +0x16c field; anything else, and a zero id, gives the terrain area id 0x69b120 at the
entity position +0x24.
The derivation is in the doc.
Callers 4
- FormatErrorLogZone client
- AreaListRegisterLocation terrain
- AreaShowsBreath terrain
- UpdateMapEntityEnvironment terrain
Callees 2
- GetAreaId terrain
- FindWMOAreaRow unassigned
Calls and jumps by a bare address, from tables/calls.tsv.