benilla-re systems structs docs

PickupBookSpell

function · ui · orchestration

Address
0x4b3260 · 123 bytes, up to 0x4b32da
Signature
void __fastcall (uint32_t index, bool pet)
Meaning
Puts a book spell on the cursor, or drops a held copy of it back
Confidence
verified, proof one
Finding
ui/spellbook#picking-up-a-book-spell

Finding: Picking up a book spell in ui: the spell book

PickupSpell (0x4b42a0) runs 0x4b3260(slot, book). It clears the cursor first. If the cursor held the same spell it plays igSpellBookSpellIconDrop; if it held another spell, or the slot holds no spell, it stops there. Otherwise the slot's spell goes onto the cursor, as a spell (0x494d20) or, for the pet book, as a pet action (0x494e20 of the pet spell record from 0x4bd160), with the sound igSpellBookSpellIconPickup, after the setter returns, whether or not the cursor took the spell. The two kits are 0x4b32e0 (drop) and 0x4b32f0 (pickup): each loads its name into ecx and jumps to SndInterfacePlayInterfaceSound (0x458030), so what is heard is the interface sound row of that name (sound/interface#interface-sounds-by-name); the exe holds only the name.

The derivation is in the doc.

Callers 2

Callees 7

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