Store Menu Parameters

From Final Fantasy Hacktics Wiki
Revision as of 16:29, 29 November 2016 by Glain (talk | contribs) (Created page with "# ROUTINE: STORE MENU PARAMETERS # Parameters: # r4 = (p1) Menu block entry ID # r5 = (p2) Value to store at offset 0 # r6 = (p3) Value t...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
  1. ROUTINE: STORE MENU PARAMETERS
  2. Parameters:
  3. r4 = (p1) Menu block entry ID
  4. r5 = (p2) Value to store at offset 0
  5. r6 = (p3) Value to store at offset 4 (Combined text index?)
  6. r7 = (p4) Value to store at offset 8

8014ca38: 3c028016 lui r2,0x8016 8014ca3c: 8c425f98 lw r2,0x5f98(r2) # *0x80165f98 8014ca40: 00042280 sll r4,r4,0x0a # p1 * 1024 8014ca44: 00822021 addu r4,r4,r2 # ptr = (*0x80165f98 + (p1 * 1024)) 8014ca48: ac850000 sw r5,0x0000(r4) # *ptr = p2 8014ca4c: ac860004 sw r6,0x0004(r4) # *(ptr + 4) = p3 8014ca50: 03e00008 jr r31 8014ca54: ac870008 sw r7,0x0008(r4) # *(ptr + 8) = p4