Catch
Jump to navigation
Jump to search
No Parameters - Returns Nothing Check for Catch usability ( mime check ) Roll Reacting chances (Brave%) If Unit is Reacting, Attack misses (Hit flag = 0x00, Evade Type = 0x0d , Store Reaction ID and Item ID (in Action 0x26)) ------------------------------------------------------------------------------------------------------------------------- 001883ac: 3c048019 lui r4,0x8019 | 001883b0: 8c842d98 lw r4,0x2d98(r4) |r2 = Target data pointer 001883b4: 27bdffe8 addiu r29,r29,-0x0018 | 001883b8: afbf0010 sw r31,0x0010(r29) | 001883bc: 0c063248 jal 0x0018c920 |-->Check if unit can react 1 r2 = 0x00 if unit can react (check status, depth, action state etc..) 001883c0: 00000000 nop | 001883c4: 1440002c bne r2,r0,0x00188478 #If Unit can React /Else branch to END 001883c8: 00000000 nop | 001883cc: 3c028019 lui r2,0x8019 | 001883d0: 8c422d94 lw r2,0x2d94(r2) |r2 = Attacker data pointer 001883d4: 00000000 nop | 001883d8: 90430003 lbu r3,0x0003(r2) |r3 = Attacker's curent job 001883dc: 3402005d ori r2,r0,0x005d |r2 = 0x5d (mime job ID) 001883e0: 10620025 beq r3,r2,0x00188478 #If Attacker is not a mime /Else branch to END mime check 001883e4: 00000000 nop | 001883e8: 3c058019 lui r5,0x8019 | 001883ec: 8ca52d98 lw r5,0x2d98(r5) |r5 = Target data pointer 001883f0: 00000000 nop | 001883f4: 90a2008e lbu r2,0x008e(r5) |r2 = Target's Reaction abilities (4th set) 001883f8: 00000000 nop | 001883fc: 30420008 andi r2,r2,0x0008 |r2 = 0x08 if Target uses catch 00188400: 1040001d beq r2,r0,0x00188478 #If Target uses Catch /Else branch to END 00188404: 34020064 ori r2,r0,0x0064 |r2 = 100 00188408: 90a30024 lbu r3,0x0024(r5) |r3 = Target's Brave 0018840c: 3c048019 lui r4,0x8019 | 00188410: 8c842d90 lw r4,0x2d90(r4) |r4 = Target data pointer 00188414: 00431023 subu r2,r2,r3 |r2 = 100 - Brave 00188418: 1040000a beq r2,r0,0x00188444 #If Target Brave <> 100 (in fact < 100) /Else branch to END 0018841c: a482002a sh r2,0x002a(r4) |Store 100-Brave as TCA hit% 00188420: 0c0634e1 jal 0x0018d384 |-->Chance to React Returns r2 = 0x00 if Target is reacting ( Random (0 to 100) < Target Brave) 00188424: 00a02021 addu r4,r5,r0 |r4 = Target data pointer 00188428: 14400013 bne r2,r0,0x00188478 #If Target is Reacting /Else branch to END 0018842c: 00000000 nop | 00188430: 3c028019 lui r2,0x8019 | 00188434: 8c42f5fc lw r2,-0x0a04(r2) |r2 = Action state 00188438: 00000000 nop | 0018843c: 1440000e bne r2,r0,0x00188478 #If Action is being executed (not preview nor AI) 00188440: 00000000 nop | 00188444: 3c028019 lui r2,0x8019 #E | 00188448: 8c422d90 lw r2,0x2d90(r2) |r2 = Target Current Action (TCA) data pointer 0018844c: 00000000 nop | 00188450: a0400000 sb r0,0x0000(r2) |Set TCA hit flag to 0x00 00188454: 3c038019 lui r3,0x8019 | 00188458: 8c632d90 lw r3,0x2d90(r3) |r3 = TCA data pointer 0018845c: 340201c2 ori r2,r0,0x01c2 |r2 = 0x1c2 (Catch ability ID) 00188460: a462000e sh r2,0x000e(r3) |Store Catch as TCA reaction ID 00188464: 3c048019 lui r4,0x8019 | 00188468: 908438d8 lbu r4,0x38d8(r4) |r4 = Current Ability used Weapon ID 0018846c: 3402000d ori r2,r0,0x000d |r2 = 0x0d 00188470: a0620002 sb r2,0x0002(r3) |Set TCA evade type = 0x0d 00188474: a4640026 sh r4,0x0026(r3) |Store Used Weapon ID in TCA last attack recieved Seems to be reaction related data (for Absorb MP it's ability MP cost..etc) 00188478: 8fbf0010 lw r31,0x0010(r29) END 0018847c: 27bd0018 addiu r29,r29,0x0018 00188480: 03e00008 jr r31 00188484: 00000000 nop
Return locations
Battle.bin 0018aba8: 63_Dmg_(SP*WP)