benilla-re systems structs docs

CMapChunk::LoadLiquids

function · terrain · orchestration

Address
0x6af760 · 163 bytes, up to 0x6af802
Signature
void __thiscall (CMapChunk *this, uint32_t first)
Meaning
Reads one MCLQ block per set liquid flag into the chunk's four liquid slots
Confidence
verified, proof one
Finding
terrain/chunk#liquid-blocks

Finding: Liquid blocks in terrain: chunk

CMapChunk::LoadLiquids (0x6af760) reads one 804-byte MCLQ block for each of MCNK flags bits 2 to 5 that is set, in bit order, into liquid slot 0 to 3 (+0x118): a CChunkLiquid keeps the block's two floats at +0x04 and +0x08, and the addresses of its 81 eight-byte vertices (+0x0c), 64 tile bytes (+0x10) and 80-byte trailer (+0x18), with the dword before the trailer at +0x14. A clear bit frees its slot. liquid builds the surface.

The derivation is in the doc.

Callers 1

Callees 3

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