Knockback?

From Final Fantasy Hacktics Wiki
Revision as of 15:34, 8 February 2015 by Choto (talk | contribs) (Created page with "<font face='Courier New'> 0018ae3c: 27bdffe8 addiu r29,r29,0xffe8 0018ae40: afbf0010 sw r31,0x0010(r29) 0018ae44: 0c062b7d jal 0x0018adf4 action data nulling 0018ae48:...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

0018ae3c: 27bdffe8 addiu r29,r29,0xffe8
0018ae40: afbf0010 sw r31,0x0010(r29)
0018ae44: 0c062b7d jal 0x0018adf4			action data nulling
0018ae48: 00000000 nop
0018ae4c: 3c068019 lui r6,0x8019
0018ae50: 24c638ed addiu r6,r6,0x38ed		
0018ae54: 90c20000 lbu r2,0x0000(r6)		load knockback/poach byte?
0018ae58: 00000000 nop
0018ae5c: 3042007f andi r2,r2,0x007f		
0018ae60: a0c20000 sb r2,0x0000(r6)			store with 0x80 removed?
0018ae64: 3c038019 lui r3,0x8019
0018ae68: 8c632d90 lw r3,0x2d90(r3)
0018ae6c: 34020001 ori r2,r0,0x0001
0018ae70: a0620025 sb r2,0x0025(r3)			store attack type psuedo status
0018ae74: 3c058019 lui r5,0x8019
0018ae78: 8ca52d98 lw r5,0x2d98(r5)			
0018ae7c: 00000000 nop
0018ae80: 94a20058 lhu r2,0x0058(r5)		load target status 
0018ae84: 00000000 nop
0018ae88: 30428060 andi r2,r2,0x8060
0018ae8c: 14400023 bne r2,r0,0x0018af1c		branch if target dead, crystal, petrify?
0018ae90: 00002021 addu r4,r0,r0
0018ae94: 90c30000 lbu r3,0x0000(r6)
0018ae98: 34020001 ori r2,r0,0x0001
0018ae9c: 14620017 bne r3,r2,0x0018aefc		branch if poach byte isn't 1
0018aea0: 00000000 nop
0018aea4: 3c028019 lui r2,0x8019
0018aea8: 904238ee lbu r2,0x38ee(r2)		load fallen height*2?
0018aeac: 90a3003b lbu r3,0x003b(r5)		load jump
0018aeb0: 00021042 srl r2,r2,0x01			fallen height 
0018aeb4: 00431823 subu r3,r2,r3			
0018aeb8: 18600010 blez r3,0x0018aefc		branch if (fallen height /2) - jump < 0
0018aebc: 00000000 nop
0018aec0: 94a2002a lhu r2,0x002a(r5)		load target max HP
0018aec4: 00000000 nop
0018aec8: 00620018 mult r3,r2
0018aecc: 00001812 mflo r3
0018aed0: 3c026666 lui r2,0x6666
0018aed4: 34426667 ori r2,r2,0x6667
0018aed8: 00620018 mult r3,r2
0018aedc: 00031fc3 sra r3,r3,0x1f
0018aee0: 00001010 mfhi r2
0018aee4: 00021083 sra r2,r2,0x02			
0018aee8: 00432023 subu r4,r2,r3			(fall distance - jump)*maxHP/10
0018aeec: 288203e8 slti r2,r4,0x03e8		set if less than 1000
0018aef0: 14400002 bne r2,r0,0x0018aefc		branch if so
0018aef4: 00000000 nop
0018aef8: 340403e7 ori r4,r0,0x03e7			damage = 999
0018aefc: 3c038019 lui r3,0x8019
0018af00: 8c632d90 lw r3,0x2d90(r3)
0018af04: 10800005 beq r4,r0,0x0018af1c		branch if no damage taken
0018af08: a4640004 sh r4,0x0004(r3)			store HP damage
0018af0c: 90620025 lbu r2,0x0025(r3)		Load attack type
0018af10: 00000000 nop
0018af14: 34420080 ori r2,r2,0x0080
0018af18: a0620025 sb r2,0x0025(r3)			store attack type = hp damage
0018af1c: 8fbf0010 lw r31,0x0010(r29)
0018af20: 27bd0018 addiu r29,r29,0x0018
0018af24: 03e00008 jr r31
0018af28: 00000000 nop