benilla-re systems structs docs

SetCustomCursor

function · ui · orchestration

Address
0x523c40 · 207 bytes, up to 0x523d0e
Signature
uint32_t __fastcall (const char *name)
Meaning
Loads the 32 by 32 texture at a path, as given, as the mode 41 cursor, returning 1 when it is shown
Confidence
verified, proof one
Finding
ui/worldcursor#custom-cursors

Finding: Custom cursors in ui: the pointer picture

0x523c40(name) loads the texture at the path name, as given, as the mode 41 cursor: SetCursor passes the script's string, and a game object its formatted Interface\Cursor\<name>.blp, or Interface\Cursor\Unable<name>.blp when unusable. It returns 1 at once when the shown mode is 41 and the name equals the last one, without case. Otherwise it loads the texture, which must be 32 by 32, copies it to image slot 41 (0xc0bd80), stores mode 41 and sends it, remembers the name in 0xbe2c70, and returns 1. A texture that cannot be loaded or has another size returns 0 and changes nothing. 0x523d40(name) maps a name back to a mode: the first mode from 1 up whose table name matches without case, or 0.

The derivation is in the doc.

Callers 2

Callees 7

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