benilla-re systems structs docs

s_flaggedSwitchList

global · storm

Address
0xc53f24 · 12 bytes, up to 0xc53f2f
Type
uint32_t[3]
Meaning
Holds the list of switches with a flag bit of 0x3000000: link offset and terminator
Confidence
verified, proof one
Finding
storm/scmd#reading-a-switch-by-id

Finding: Reading a switch by id in storm: command-line switches

SCmdGetNum(id) walks the list at 0xc53f24, then the one at 0xc53f30, and returns the value word +0x3c of the first node whose id +0xc equals id, or 0 when none does. SCmdGetBool(id) is SCmdGetNum(id) != 0. SCmdGetString(id, buffer, size) raises error 0x57 and returns 0 for a null buffer or a zero size, writing 0 to buffer[0] first whenever the buffer is not null; otherwise it finds the node the same way, copies the string +0x3c points to with SStrCopy(buffer, string, size) when it is not null, and returns 1, or returns 0 with the buffer empty when no node has the id.

The derivation is in the doc.