OnNpcTextArrived
function · ui · orchestration
- Address
0x4e22d0· 71 bytes, up to0x4e2316- Meaning
- Rebuilds the greeting when the NPC text arrives, or closes gossip when it failed
- Confidence
- verified, proof one
- Finding
- ui/gossip#the-greeting
Finding: The greeting in ui: the gossip window
After the message the handler asks the NPC text cache (query opcode 0x17f) for the text id. A text id of
0 or a cache miss makes the greeting pending (0xbbb670 = 1) and shows nothing. With the record it takes a
column from the NPC's gender and draws one of the eight entries at random, weighted by their
probabilities among those with text in that column. The text is expanded for $ macros (questtext),
run through the language rewrite (chatlanguage) and stored, and GOSSIP_SHOW (id 297) fires. With no entry
having text it logs Missing gossip text! and closes the window (GOSSIP_CLOSED, id 299).
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.