benilla-re systems structs docs

HandleReceivedMailPacket

function · ui · primitive

Address
0x4ad620 · 141 bytes, up to 0x4ad6ac
Signature
uint32_t __fastcall (void *param, uint32_t opcode, uint32_t time, CDataStore *msg)
Meaning
Notes a re-query while the mailbox is open, else keeps the smaller next-mail time and signals near zero
Confidence
verified, proof one
Name from
the community database (idb)
Finding
ui/mail#pending-mail
Test
ui::glue_4a8_4ad620_set_value

Finding: Pending mail in ui: the mailbox and the inbox

The float 0x845eac is the time until the next mail the server will deliver: -1.0 means unknown, 0 means mail is waiting. HasNewMail() returns 1 when its absolute value is below 2^-22 and nil otherwise. Init sets -1.0 and asks the server (opcode 0x284); the answer overwrites it and raises UPDATE_PENDING_MAIL. A received-mail packet (0x285, one f32) sets the flag only to remember a re-query when the mailbox is open; closed, a value near zero is stored and signalled, a larger one is stored only when the old value is unknown or larger. A per-frame step lowers a positive value by the frame time to a floor of 0 and signals once on reaching it.

The derivation is in the doc.

Callers 0

None by a direct call or jump.

Callees 2

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