Difference between revisions of "Remove Status"
Jump to navigation
Jump to search
m |
m (Added a note about repurposing the Inflict Status byte in formula hacks.) |
||
Line 1: | Line 1: | ||
+ | Note: If you have a formula hack that repurposes the Inflict Status byte, you'll want to zero out at least the first four bytes at 0x80193860 (Canceled Statuses) in the formula itself. These are what get checked to see if abilities can do something to affect Dead, Petrified, or Walled units, and they are set up regardless of whether or not the formula actually inflicts status. | ||
+ | |||
0018b9f8: 3c028019 lui r2,0x8019 | 0018b9f8: 3c028019 lui r2,0x8019 | ||
0018b9fc: 90423906 lbu r2,0x3906(r2) r2 =Current ability Status Infliction Type | 0018b9fc: 90423906 lbu r2,0x3906(r2) r2 =Current ability Status Infliction Type |
Latest revision as of 14:17, 8 November 2024
Note: If you have a formula hack that repurposes the Inflict Status byte, you'll want to zero out at least the first four bytes at 0x80193860 (Canceled Statuses) in the formula itself. These are what get checked to see if abilities can do something to affect Dead, Petrified, or Walled units, and they are set up regardless of whether or not the formula actually inflicts status.
0018b9f8: 3c028019 lui r2,0x8019 0018b9fc: 90423906 lbu r2,0x3906(r2) r2 =Current ability Status Infliction Type 0018ba00: 00000000 nop 0018ba04: 30420010 andi r2,r2,0x0010 r2 = 0x10 if cancel / Else 0x00 0018ba08: 1040000c beq r2,r0,0x0018ba3c #If Infliction type is cancel / Else return 0018ba0c: 00000000 nop | 0018ba10: 00001821 addu r3,r0,r0 |r3 = 0x00 (loop counter) 0018ba14: 3c018019 lui r1,0x8019 @ Loop start 0018ba18: 00230821 addu r1,r1,r3 |r1 = 0x80190000 + Counter 0018ba1c: 90223907 lbu r2,0x3907(r1) |Load Status Set X (1 to 5 while looping) 0018ba20: 3c018019 lui r1,0x8019 | 0018ba24: 00230821 addu r1,r1,r3 |r1 = 0x80190000 + Counter 0018ba28: a0223860 sb r2,0x3860(r1) |Store cured status in current ability section 0x80193860 - 0x80193864 0018ba2c: 24630001 addiu r3,r3,0x0001 |r3 = r3 +1 - Counter + 1 0018ba30: 28620005 slti r2,r3,0x0005 |r2 = 0x01 while r3 < 5 (Counter limit) 0018ba34: 1440fff7 bne r2,r0,0x0018ba14 ^Loop while r2 = 0x01 0018ba38: 00000000 nop 0018ba3c: 03e00008 jr r31 Return 0018ba40: 00000000 nop
Return locations
0018b930: Pre_Formula_Setup_(FDC)