Difference between revisions of "001404cc - 00140728"
Jump to navigation
Jump to search
m |
|||
Line 1: | Line 1: | ||
001404cc: 27BDFFD8 addiu r29,r29,-0x0028 | 001404cc: 27BDFFD8 addiu r29,r29,-0x0028 | ||
001404d0: AFB10014 sw r17,0x0014(r29) | 001404d0: AFB10014 sw r17,0x0014(r29) | ||
− | 001404d4: 00008821 addu r17,r0,r0 | + | 001404d4: 00008821 addu r17,r0,r0 setup menu index |
001404d8: 3C058017 lui r5,0x8017 | 001404d8: 3C058017 lui r5,0x8017 | ||
− | 001404dc: 24A54060 addiu r5,r5,0x4060 | + | 001404dc: 24A54060 addiu r5,r5,0x4060 Displayed skillset list |
001404e0: AFB3001C sw r19,0x001c(r29) | 001404e0: AFB3001C sw r19,0x001c(r29) | ||
001404e4: 3C138017 lui r19,0x8017 | 001404e4: 3C138017 lui r19,0x8017 | ||
− | 001404e8: 2673403C addiu r19,r19,0x403c | + | 001404e8: 2673403C addiu r19,r19,0x403c skillset determination list |
001404ec: 02603021 addu r6,r19,r0 | 001404ec: 02603021 addu r6,r19,r0 | ||
001404f0: 3C048015 lui r4,0x8015 | 001404f0: 3C048015 lui r4,0x8015 | ||
− | 001404f4: 8484D08A lh r4,-0x2f76(r4) | + | 001404f4: 8484D08A lh r4,-0x2f76(r4) acting Unit ID |
001404f8: 3C078017 lui r7,0x8017 | 001404f8: 3C078017 lui r7,0x8017 | ||
− | 001404fc: 24E7404C addiu r7,r7,0x404c | + | 001404fc: 24E7404C addiu r7,r7,0x404c action byte menu list |
00140500: AFBF0020 sw r31,0x0020(r29) | 00140500: AFBF0020 sw r31,0x0020(r29) | ||
00140504: AFB20018 sw r18,0x0018(r29) | 00140504: AFB20018 sw r18,0x0018(r29) | ||
Line 20: | Line 20: | ||
00140518: A0A00000 sb r0,0x0000(r5) | 00140518: A0A00000 sb r0,0x0000(r5) | ||
0014051c: 3C018017 lui r1,0x8017 | 0014051c: 3C018017 lui r1,0x8017 | ||
− | 00140520: AC229840 sw r2,-0x67c0(r1) | + | 00140520: AC229840 sw r2,-0x67c0(r1) 1 if no legal skillsets |
00140524: 0C04CA09 jal 0x00132824 [[00132824 - 00132868 BATTLE]] | 00140524: 0C04CA09 jal 0x00132824 [[00132824 - 00132868 BATTLE]] | ||
− | 00140528: 34045010 ori r4,r0,0x5010 | + | 00140528: 34045010 ori r4,r0,0x5010 Get location of text entry 0x5010 (Battle menus Act menu) |
0014052c: 0C04B7D0 jal 0x0012df40 [[0012df40 - 0012df64]] | 0014052c: 0C04B7D0 jal 0x0012df40 [[0012df40 - 0012df64]] | ||
00140530: 00409021 addu r18,r2,r0 | 00140530: 00409021 addu r18,r2,r0 | ||
Line 28: | Line 28: | ||
00140538: 00402021 addu r4,r2,r0 | 00140538: 00402021 addu r4,r2,r0 | ||
0014053c: 34030002 ori r3,r0,0x0002 | 0014053c: 34030002 ori r3,r0,0x0002 | ||
− | 00140540: 14430011 bne r2,r3,0x00140588 | + | 00140540: 14430011 bne r2,r3,0x00140588 branch if not underwater |
− | 00140544: 340300FA ori r3,r0,0x00fa | + | 00140544: 340300FA ori r3,r0,0x00fa {None} (0 width space) |
00140548: 00008021 addu r16,r0,r0 | 00140548: 00008021 addu r16,r0,r0 | ||
0014054c: 34040001 ori r4,r0,0x0001 | 0014054c: 34040001 ori r4,r0,0x0001 | ||
00140550: 3403000D ori r3,r0,0x000d | 00140550: 3403000D ori r3,r0,0x000d | ||
− | 00140554: 02603021 addu r6,r19,r0 | + | 00140554: 02603021 addu r6,r19,r0 skillset determination list |
− | 00140558: A0C40000 sb r4,0x0000(r6) | + | 00140558: A0C40000 sb r4,0x0000(r6) set skillset as unusable |
0014055c: 3C018017 lui r1,0x8017 | 0014055c: 3C018017 lui r1,0x8017 | ||
00140560: 00300821 addu r1,r1,r16 | 00140560: 00300821 addu r1,r1,r16 | ||
− | 00140564: 9022404C lbu r2,0x404c(r1) | + | 00140564: 9022404C lbu r2,0x404c(r1) action byte menu list |
00140568: 00000000 nop | 00140568: 00000000 nop | ||
− | 0014056c: 14430002 bne r2,r3,0x00140578 | + | 0014056c: 14430002 bne r2,r3,0x00140578 branch if action menu is not Unknown 1 (...?) |
00140570: 26100001 addiu r16,r16,0x0001 | 00140570: 26100001 addiu r16,r16,0x0001 | ||
− | 00140574: A0C00000 sb r0,0x0000(r6) | + | 00140574: A0C00000 sb r0,0x0000(r6) set skillset as usable (?) |
00140578: 2A020006 slti r2,r16,0x0006 | 00140578: 2A020006 slti r2,r16,0x0006 | ||
− | 0014057c: 1440FFF6 bne r2,r0,0x00140558 | + | 0014057c: 1440FFF6 bne r2,r0,0x00140558 check all skillsets |
00140580: 24C60001 addiu r6,r6,0x0001 | 00140580: 24C60001 addiu r6,r6,0x0001 | ||
− | 00140584: 340300FA ori r3,r0,0x00fa | + | 00140584: 340300FA ori r3,r0,0x00fa {None} |
+ | |||
00140588: 34100005 ori r16,r0,0x0005 | 00140588: 34100005 ori r16,r0,0x0005 | ||
− | 0014058c: 26420019 addiu r2,r18,0x0019 | + | 0014058c: 26420019 addiu r2,r18,0x0019 Text ptr + 0x19 |
− | 00140590: A0430003 sb r3,0x0003(r2) | + | 00140590: A0430003 sb r3,0x0003(r2) save {None} as buffer |
00140594: 2610FFFF addiu r16,r16,-0x0001 | 00140594: 2610FFFF addiu r16,r16,-0x0001 | ||
− | 00140598: 0601FFFD bgez r16,0x00140590 | + | 00140598: 0601FFFD bgez r16,0x00140590 loop while not yet set all rows to have {None} |
0014059c: 2442FFFB addiu r2,r2,-0x0005 | 0014059c: 2442FFFB addiu r2,r2,-0x0005 | ||
− | 001405a0: 00008021 addu r16,r0,r0 | + | 001405a0: 00008021 addu r16,r0,r0 Setup index 2 |
− | 001405a4: 340A00FA ori r10,r0,0x00fa | + | 001405a4: 340A00FA ori r10,r0,0x00fa {None} |
− | 001405a8: 340900FF ori r9,r0,0x00ff | + | 001405a8: 340900FF ori r9,r0,0x00ff End List skillset |
− | 001405ac: 34080004 ori r8,r0,0x0004 | + | 001405ac: 34080004 ori r8,r0,0x0004 {...: Gray} |
− | 001405b0: 3407B000 ori r7,r0,0xb000 | + | 001405b0: 3407B000 ori r7,r0,0xb000 ... not sure yet. unusability message related? |
001405b4: 3C068017 lui r6,0x8017 | 001405b4: 3C068017 lui r6,0x8017 | ||
− | 001405b8: 24C64060 addiu r6,r6,0x4060 | + | 001405b8: 24C64060 addiu r6,r6,0x4060 Displayed skillset list |
001405bc: 3C058016 lui r5,0x8016 | 001405bc: 3C058016 lui r5,0x8016 | ||
− | 001405c0: 24A56A40 addiu r5,r5,0x6a40 | + | 001405c0: 24A56A40 addiu r5,r5,0x6a40 act menu select function list |
001405c4: 02402021 addu r4,r18,r0 | 001405c4: 02402021 addu r4,r18,r0 | ||
001405c8: 3C038016 lui r3,0x8016 | 001405c8: 3C038016 lui r3,0x8016 | ||
− | 001405cc: 24635EF4 addiu r3,r3,0x5ef4 | + | 001405cc: 24635EF4 addiu r3,r3,0x5ef4 calculator type ability ID? |
− | 001405d0: 00111080 sll r2,r17,0x02 | + | 001405d0: 00111080 sll r2,r17,0x02 setup Index * 4 |
001405d4: 00431821 addu r3,r2,r3 | 001405d4: 00431821 addu r3,r2,r3 | ||
− | 001405d8: A08A0003 sb r10,0x0003(r4) | + | 001405d8: A08A0003 sb r10,0x0003(r4) Store {None} |
001405dc: 90C20000 lbu r2,0x0000(r6) | 001405dc: 90C20000 lbu r2,0x0000(r6) | ||
001405e0: 00000000 nop | 001405e0: 00000000 nop | ||
− | 001405e4: 1049001F beq r2,r9,0x00140664 | + | 001405e4: 1049001F beq r2,r9,0x00140664 branch if end of list |
001405e8: 00000000 nop | 001405e8: 00000000 nop | ||
001405ec: 3C018017 lui r1,0x8017 | 001405ec: 3C018017 lui r1,0x8017 | ||
001405f0: 00300821 addu r1,r1,r16 | 001405f0: 00300821 addu r1,r1,r16 | ||
− | 001405f4: 9022403C lbu r2,0x403c(r1) | + | 001405f4: 9022403C lbu r2,0x403c(r1) skillset determination |
001405f8: 00000000 nop | 001405f8: 00000000 nop | ||
− | 001405fc: 10400003 beq r2,r0,0x0014060c | + | 001405fc: 10400003 beq r2,r0,0x0014060c branch if usable |
− | 00140600: 34021003 ori r2,r0,0x1003 | + | 00140600: 34021003 ori r2,r0,0x1003 select function 0x1003 (bring up error message) |
00140604: 08050185 j 0x00140614 | 00140604: 08050185 j 0x00140614 | ||
− | 00140608: A0880001 sb r8,0x0001(r4) | + | 00140608: A0880001 sb r8,0x0001(r4) set text {Color: Gray} |
− | 0014060c: 34020003 ori r2,r0,0x0003 | + | |
+ | 0014060c: 34020003 ori r2,r0,0x0003 select function 0x0003 (bring up ability menu) | ||
00140610: A0800001 sb r0,0x0001(r4) | 00140610: A0800001 sb r0,0x0001(r4) | ||
− | 00140614: A4A20000 sh r2,0x0000(r5) | + | 00140614: A4A20000 sh r2,0x0000(r5) store select function |
00140618: 3C028017 lui r2,0x8017 | 00140618: 3C028017 lui r2,0x8017 | ||
− | 0014061c: 8C429840 lw r2,-0x67c0(r2) | + | 0014061c: 8C429840 lw r2,-0x67c0(r2) load if any legal skillsets |
00140620: 00000000 nop | 00140620: 00000000 nop | ||
− | 00140624: 10400003 beq r2,r0,0x00140634 | + | 00140624: 10400003 beq r2,r0,0x00140634 branch if so |
00140628: 00000000 nop | 00140628: 00000000 nop | ||
0014062c: 08050191 j 0x00140644 | 0014062c: 08050191 j 0x00140644 | ||
− | 00140630: AC670000 sw r7,0x0000(r3) | + | 00140630: AC670000 sw r7,0x0000(r3) store 0xb000 to calculator type ability ID? |
00140634: 90C20000 lbu r2,0x0000(r6) | 00140634: 90C20000 lbu r2,0x0000(r6) | ||
00140638: 00000000 nop | 00140638: 00000000 nop | ||
0014063c: 00471021 addu r2,r2,r7 | 0014063c: 00471021 addu r2,r2,r7 | ||
− | 00140640: AC620000 sw r2,0x0000(r3) | + | 00140640: AC620000 sw r2,0x0000(r3) otherwise store 0xb0## (## skillset ID) |
00140644: 24630004 addiu r3,r3,0x0004 | 00140644: 24630004 addiu r3,r3,0x0004 | ||
00140648: 26310001 addiu r17,r17,0x0001 | 00140648: 26310001 addiu r17,r17,0x0001 | ||
Line 99: | Line 101: | ||
00140654: 26100001 addiu r16,r16,0x0001 | 00140654: 26100001 addiu r16,r16,0x0001 | ||
00140658: 2A020006 slti r2,r16,0x0006 | 00140658: 2A020006 slti r2,r16,0x0006 | ||
− | 0014065c: 1440FFDE bne r2,r0,0x001405d8 | + | 0014065c: 1440FFDE bne r2,r0,0x001405d8 loop 6 skillsets |
00140660: 24840005 addiu r4,r4,0x0005 | 00140660: 24840005 addiu r4,r4,0x0005 | ||
00140664: 0C04ED64 jal 0x0013b590 [[Get Script Variable]] | 00140664: 0C04ED64 jal 0x0013b590 [[Get Script Variable]] | ||
− | 00140668: 34040063 ori r4,r0,0x0063 | + | 00140668: 34040063 ori r4,r0,0x0063 get script variable 0x63 ("Anything" |
− | 0014066c: 10400019 beq r2,r0,0x001406d4 | + | 0014066c: 10400019 beq r2,r0,0x001406d4 skip if 0 |
00140670: 2A020006 slti r2,r16,0x0006 | 00140670: 2A020006 slti r2,r16,0x0006 | ||
− | 00140674: 10400017 beq r2,r0,0x001406d4 | + | 00140674: 10400017 beq r2,r0,0x001406d4 branch if unit does not have all 6 skillsets |
00140678: 00112080 sll r4,r17,0x02 | 00140678: 00112080 sll r4,r17,0x02 | ||
− | 0014067c: 26310001 addiu r17,r17,0x0001 | + | 0014067c: 26310001 addiu r17,r17,0x0001 if "Anything" is enabled, increase index properly for below. |
− | 00140680: 00101080 sll r2,r16,0x02 | + | 00140680: 00101080 sll r2,r16,0x02 index * 4 |
− | 00140684: 00501021 addu r2,r2,r16 | + | 00140684: 00501021 addu r2,r2,r16 index * 5 |
− | 00140688: 00521021 addu r2,r2,r18 | + | 00140688: 00521021 addu r2,r2,r18 + text |
− | 0014068c: 00101840 sll r3,r16,0x01 | + | 0014068c: 00101840 sll r3,r16,0x01 index half |
− | 00140690: A0400001 sb r0,0x0001(r2) | + | 00140690: A0400001 sb r0,0x0001(r2) clear colour |
00140694: 34020016 ori r2,r0,0x0016 | 00140694: 34020016 ori r2,r0,0x0016 | ||
00140698: 3C018016 lui r1,0x8016 | 00140698: 3C018016 lui r1,0x8016 | ||
0014069c: 00230821 addu r1,r1,r3 | 0014069c: 00230821 addu r1,r1,r3 | ||
− | 001406a0: A4226A40 sh r2,0x6a40(r1) | + | 001406a0: A4226A40 sh r2,0x6a40(r1) set "anything" |
001406a4: 340200BC ori r2,r0,0x00bc | 001406a4: 340200BC ori r2,r0,0x00bc | ||
001406a8: 3C018017 lui r1,0x8017 | 001406a8: 3C018017 lui r1,0x8017 | ||
001406ac: 00300821 addu r1,r1,r16 | 001406ac: 00300821 addu r1,r1,r16 | ||
− | 001406b0: A0224060 sb r2,0x4060(r1) | + | 001406b0: A0224060 sb r2,0x4060(r1) set skillset 0xbc display "anything" |
001406b4: 340200FF ori r2,r0,0x00ff | 001406b4: 340200FF ori r2,r0,0x00ff | ||
001406b8: 3C018017 lui r1,0x8017 | 001406b8: 3C018017 lui r1,0x8017 | ||
001406bc: 00300821 addu r1,r1,r16 | 001406bc: 00300821 addu r1,r1,r16 | ||
− | 001406c0: A0224061 sb r2,0x4061(r1) | + | 001406c0: A0224061 sb r2,0x4061(r1) set skillset 0xff display |
001406c4: 3402B0BC ori r2,r0,0xb0bc | 001406c4: 3402B0BC ori r2,r0,0xb0bc | ||
001406c8: 3C018016 lui r1,0x8016 | 001406c8: 3C018016 lui r1,0x8016 | ||
001406cc: 00240821 addu r1,r1,r4 | 001406cc: 00240821 addu r1,r1,r4 | ||
− | 001406d0: AC225EF4 sw r2,0x5ef4(r1) | + | 001406d0: AC225EF4 sw r2,0x5ef4(r1) store selection function 0xb0bc "anything" |
− | 001406d4: 00112100 sll r4,r17,0x04 | + | |
+ | 001406d4: 00112100 sll r4,r17,0x04 | ||
001406d8: 24840010 addiu r4,r4,0x0010 | 001406d8: 24840010 addiu r4,r4,0x0010 | ||
001406dc: 00111080 sll r2,r17,0x02 | 001406dc: 00111080 sll r2,r17,0x02 | ||
Line 135: | Line 138: | ||
001406e4: 00521021 addu r2,r2,r18 | 001406e4: 00521021 addu r2,r2,r18 | ||
001406e8: 340300FF ori r3,r0,0x00ff | 001406e8: 340300FF ori r3,r0,0x00ff | ||
− | 001406ec: A043FFFE sb r3,-0x0002(r2) | + | 001406ec: A043FFFE sb r3,-0x0002(r2) store end of list |
001406f0: 3C028017 lui r2,0x8017 | 001406f0: 3C028017 lui r2,0x8017 | ||
− | 001406f4: 8C423CB8 lw r2,0x3cb8(r2) | + | 001406f4: 8C423CB8 lw r2,0x3cb8(r2) menu data pointer |
001406f8: 2623FFFF addiu r3,r17,-0x0001 | 001406f8: 2623FFFF addiu r3,r17,-0x0001 | ||
− | 001406fc: A443010E sh r3,0x010e(r2) | + | 001406fc: A443010E sh r3,0x010e(r2) store text references and menu height based on number of skillsets. |
00140700: A4440106 sh r4,0x0106(r2) | 00140700: A4440106 sh r4,0x0106(r2) | ||
00140704: A44400FE sh r4,0x00fe(r2) | 00140704: A44400FE sh r4,0x00fe(r2) |
Latest revision as of 12:32, 26 April 2024
001404cc: 27BDFFD8 addiu r29,r29,-0x0028 001404d0: AFB10014 sw r17,0x0014(r29) 001404d4: 00008821 addu r17,r0,r0 setup menu index 001404d8: 3C058017 lui r5,0x8017 001404dc: 24A54060 addiu r5,r5,0x4060 Displayed skillset list 001404e0: AFB3001C sw r19,0x001c(r29) 001404e4: 3C138017 lui r19,0x8017 001404e8: 2673403C addiu r19,r19,0x403c skillset determination list 001404ec: 02603021 addu r6,r19,r0 001404f0: 3C048015 lui r4,0x8015 001404f4: 8484D08A lh r4,-0x2f76(r4) acting Unit ID 001404f8: 3C078017 lui r7,0x8017 001404fc: 24E7404C addiu r7,r7,0x404c action byte menu list 00140500: AFBF0020 sw r31,0x0020(r29) 00140504: AFB20018 sw r18,0x0018(r29) 00140508: AFB00010 sw r16,0x0010(r29) 0014050c: 3C018015 lui r1,0x8015 00140510: AC20D320 sw r0,-0x2ce0(r1) 00140514: 0C0604F0 jal 0x001813c0 Player Skill Set 00140518: A0A00000 sb r0,0x0000(r5) 0014051c: 3C018017 lui r1,0x8017 00140520: AC229840 sw r2,-0x67c0(r1) 1 if no legal skillsets 00140524: 0C04CA09 jal 0x00132824 00132824 - 00132868 BATTLE 00140528: 34045010 ori r4,r0,0x5010 Get location of text entry 0x5010 (Battle menus Act menu) 0014052c: 0C04B7D0 jal 0x0012df40 0012df40 - 0012df64 00140530: 00409021 addu r18,r2,r0 00140534: 0C0604C3 jal 0x0018130c Weapon Guard Usability 00140538: 00402021 addu r4,r2,r0 0014053c: 34030002 ori r3,r0,0x0002 00140540: 14430011 bne r2,r3,0x00140588 branch if not underwater 00140544: 340300FA ori r3,r0,0x00fa {None} (0 width space) 00140548: 00008021 addu r16,r0,r0 0014054c: 34040001 ori r4,r0,0x0001 00140550: 3403000D ori r3,r0,0x000d 00140554: 02603021 addu r6,r19,r0 skillset determination list 00140558: A0C40000 sb r4,0x0000(r6) set skillset as unusable 0014055c: 3C018017 lui r1,0x8017 00140560: 00300821 addu r1,r1,r16 00140564: 9022404C lbu r2,0x404c(r1) action byte menu list 00140568: 00000000 nop 0014056c: 14430002 bne r2,r3,0x00140578 branch if action menu is not Unknown 1 (...?) 00140570: 26100001 addiu r16,r16,0x0001 00140574: A0C00000 sb r0,0x0000(r6) set skillset as usable (?) 00140578: 2A020006 slti r2,r16,0x0006 0014057c: 1440FFF6 bne r2,r0,0x00140558 check all skillsets 00140580: 24C60001 addiu r6,r6,0x0001 00140584: 340300FA ori r3,r0,0x00fa {None}
00140588: 34100005 ori r16,r0,0x0005 0014058c: 26420019 addiu r2,r18,0x0019 Text ptr + 0x19 00140590: A0430003 sb r3,0x0003(r2) save {None} as buffer 00140594: 2610FFFF addiu r16,r16,-0x0001 00140598: 0601FFFD bgez r16,0x00140590 loop while not yet set all rows to have {None} 0014059c: 2442FFFB addiu r2,r2,-0x0005 001405a0: 00008021 addu r16,r0,r0 Setup index 2 001405a4: 340A00FA ori r10,r0,0x00fa {None} 001405a8: 340900FF ori r9,r0,0x00ff End List skillset 001405ac: 34080004 ori r8,r0,0x0004 {...: Gray} 001405b0: 3407B000 ori r7,r0,0xb000 ... not sure yet. unusability message related? 001405b4: 3C068017 lui r6,0x8017 001405b8: 24C64060 addiu r6,r6,0x4060 Displayed skillset list 001405bc: 3C058016 lui r5,0x8016 001405c0: 24A56A40 addiu r5,r5,0x6a40 act menu select function list 001405c4: 02402021 addu r4,r18,r0 001405c8: 3C038016 lui r3,0x8016 001405cc: 24635EF4 addiu r3,r3,0x5ef4 calculator type ability ID? 001405d0: 00111080 sll r2,r17,0x02 setup Index * 4 001405d4: 00431821 addu r3,r2,r3 001405d8: A08A0003 sb r10,0x0003(r4) Store {None} 001405dc: 90C20000 lbu r2,0x0000(r6) 001405e0: 00000000 nop 001405e4: 1049001F beq r2,r9,0x00140664 branch if end of list 001405e8: 00000000 nop 001405ec: 3C018017 lui r1,0x8017 001405f0: 00300821 addu r1,r1,r16 001405f4: 9022403C lbu r2,0x403c(r1) skillset determination 001405f8: 00000000 nop 001405fc: 10400003 beq r2,r0,0x0014060c branch if usable 00140600: 34021003 ori r2,r0,0x1003 select function 0x1003 (bring up error message) 00140604: 08050185 j 0x00140614 00140608: A0880001 sb r8,0x0001(r4) set text {Color: Gray}
0014060c: 34020003 ori r2,r0,0x0003 select function 0x0003 (bring up ability menu) 00140610: A0800001 sb r0,0x0001(r4) 00140614: A4A20000 sh r2,0x0000(r5) store select function 00140618: 3C028017 lui r2,0x8017 0014061c: 8C429840 lw r2,-0x67c0(r2) load if any legal skillsets 00140620: 00000000 nop 00140624: 10400003 beq r2,r0,0x00140634 branch if so 00140628: 00000000 nop 0014062c: 08050191 j 0x00140644 00140630: AC670000 sw r7,0x0000(r3) store 0xb000 to calculator type ability ID? 00140634: 90C20000 lbu r2,0x0000(r6) 00140638: 00000000 nop 0014063c: 00471021 addu r2,r2,r7 00140640: AC620000 sw r2,0x0000(r3) otherwise store 0xb0## (## skillset ID) 00140644: 24630004 addiu r3,r3,0x0004 00140648: 26310001 addiu r17,r17,0x0001 0014064c: 24C60001 addiu r6,r6,0x0001 00140650: 24A50002 addiu r5,r5,0x0002 00140654: 26100001 addiu r16,r16,0x0001 00140658: 2A020006 slti r2,r16,0x0006 0014065c: 1440FFDE bne r2,r0,0x001405d8 loop 6 skillsets 00140660: 24840005 addiu r4,r4,0x0005 00140664: 0C04ED64 jal 0x0013b590 Get Script Variable 00140668: 34040063 ori r4,r0,0x0063 get script variable 0x63 ("Anything" 0014066c: 10400019 beq r2,r0,0x001406d4 skip if 0 00140670: 2A020006 slti r2,r16,0x0006 00140674: 10400017 beq r2,r0,0x001406d4 branch if unit does not have all 6 skillsets 00140678: 00112080 sll r4,r17,0x02 0014067c: 26310001 addiu r17,r17,0x0001 if "Anything" is enabled, increase index properly for below. 00140680: 00101080 sll r2,r16,0x02 index * 4 00140684: 00501021 addu r2,r2,r16 index * 5 00140688: 00521021 addu r2,r2,r18 + text 0014068c: 00101840 sll r3,r16,0x01 index half 00140690: A0400001 sb r0,0x0001(r2) clear colour 00140694: 34020016 ori r2,r0,0x0016 00140698: 3C018016 lui r1,0x8016 0014069c: 00230821 addu r1,r1,r3 001406a0: A4226A40 sh r2,0x6a40(r1) set "anything" 001406a4: 340200BC ori r2,r0,0x00bc 001406a8: 3C018017 lui r1,0x8017 001406ac: 00300821 addu r1,r1,r16 001406b0: A0224060 sb r2,0x4060(r1) set skillset 0xbc display "anything" 001406b4: 340200FF ori r2,r0,0x00ff 001406b8: 3C018017 lui r1,0x8017 001406bc: 00300821 addu r1,r1,r16 001406c0: A0224061 sb r2,0x4061(r1) set skillset 0xff display 001406c4: 3402B0BC ori r2,r0,0xb0bc 001406c8: 3C018016 lui r1,0x8016 001406cc: 00240821 addu r1,r1,r4 001406d0: AC225EF4 sw r2,0x5ef4(r1) store selection function 0xb0bc "anything"
001406d4: 00112100 sll r4,r17,0x04 001406d8: 24840010 addiu r4,r4,0x0010 001406dc: 00111080 sll r2,r17,0x02 001406e0: 00511021 addu r2,r2,r17 001406e4: 00521021 addu r2,r2,r18 001406e8: 340300FF ori r3,r0,0x00ff 001406ec: A043FFFE sb r3,-0x0002(r2) store end of list 001406f0: 3C028017 lui r2,0x8017 001406f4: 8C423CB8 lw r2,0x3cb8(r2) menu data pointer 001406f8: 2623FFFF addiu r3,r17,-0x0001 001406fc: A443010E sh r3,0x010e(r2) store text references and menu height based on number of skillsets. 00140700: A4440106 sh r4,0x0106(r2) 00140704: A44400FE sh r4,0x00fe(r2) 00140708: A44400F6 sh r4,0x00f6(r2) 0014070c: 8FBF0020 lw r31,0x0020(r29) 00140710: 8FB3001C lw r19,0x001c(r29) 00140714: 8FB20018 lw r18,0x0018(r29) 00140718: 8FB10014 lw r17,0x0014(r29) 0014071c: 8FB00010 lw r16,0x0010(r29) 00140720: 27BD0028 addiu r29,r29,0x0028 00140724: 03E00008 jr r31 00140728: 00000000 nop