benilla-re systems structs docs

AsyncFileReadWait

function · client

Address
0x443bd0 · 342 bytes, up to 0x443d25
Signature
void __fastcall (void *read)
Meaning
Waits for one asynchronous read, moving it to the head of the queue and draining finished reads
Confidence
verified, proof one
Finding
glue/enterworld#waiting-for-one-read

Finding: Waiting for one read in glue: entering and leaving the world

AsyncFileReadWait(read) returns at once for a read whose done byte +0x1c is set. Otherwise it records the read as the one awaited and, unless it is the read in progress, its byte +0x1d is 0 or its byte +0x28 is set, moves it to the head of the queue 0x885688. It then drains finished reads and sleeps 1 ms until the drain clears the awaited read. A depth count is held across the wait. Texture, map object, model and terrain loads call it.

The derivation is in the doc.

Callers 6

Callees 5

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