Move target coordinates after knockback

From Final Fantasy Hacktics Wiki
(Redirected from 0006a20c - 0006a37c)
Jump to navigation Jump to search
Move target coordinates after knockback Knockback related
0006a20c: 27bdffd8 addiu r29,r29,0xffd8
0006a210: afb00010 sw r16,0x0010(r29)
0006a214: 00808021 addu r16,r4,r0			misc data
0006a218: afb3001c sw r19,0x001c(r29)
0006a21c: 00a09821 addu r19,r5,r0			tile data
0006a220: afb10014 sw r17,0x0014(r29)
0006a224: afbf0020 sw r31,0x0020(r29)
0006a228: afb20018 sw r18,0x0018(r29)
0006a22c: 9202011c lbu r2,0x011c(r16)		load knockback direction
0006a230: 92120097 lbu r18,0x0097(r16)
0006a234: 00021982 srl r3,r2,0x06
0006a238: 34020001 ori r2,r0,0x0001
0006a23c: 10620018 beq r3,r2,0x0006a2a0
0006a240: 2611011c addiu r17,r16,0x011c

0006a244: 28620002 slti r2,r3,0x0002
0006a248: 10400005 beq r2,r0,0x0006a260
0006a24c: 00000000 nop

0006a250: 1060000a beq r3,r0,0x0006a27c
0006a254: 34020003 ori r2,r0,0x0003

0006a258: 0801a8c3 j 0x0006a30c			skip
0006a25c: 00000000 nop

0006a260: 34020002 ori r2,r0,0x0002
0006a264: 10620018 beq r3,r2,0x0006a2c8
0006a268: 34020003 ori r2,r0,0x0003

0006a26c: 1062001f beq r3,r2,0x0006a2ec
0006a270: 34020005 ori r2,r0,0x0005

0006a274: 0801a8c3 j 0x0006a30c			skip
0006a278: 00000000 nop

+X
0006a27c: 34060c00 ori r6,r0,0x0c00
0006a280: 9203007c lbu r3,0x007c(r16)   load X
0006a284: a202007f sb r2,0x007f(r16)	store new ctrl
0006a288: 9202011c lbu r2,0x011c(r16)	load kb direction
0006a28c: 24630001 addiu r3,r3,0x0001   increment X
0006a290: 30420003 andi r2,r2,0x0003    
0006a294: 00621821 addu r3,r3,r2        add ??
0006a298: 0801a8c3 j 0x0006a30c
0006a29c: a2030080 sb r3,0x0080(r16)
-X
0006a2a0: 34060400 ori r6,r0,0x0400
0006a2a4: 9203007c lbu r3,0x007c(r16)
0006a2a8: 34020007 ori r2,r0,0x0007
0006a2ac: a202007f sb r2,0x007f(r16)
0006a2b0: 9202011c lbu r2,0x011c(r16)
0006a2b4: 246300ff addiu r3,r3,0x00ff
0006a2b8: 30420003 andi r2,r2,0x0003
0006a2bc: 00621823 subu r3,r3,r2
0006a2c0: 0801a8c3 j 0x0006a30c
0006a2c4: a2030080 sb r3,0x0080(r16)		store new X

-Y
0006a2c8: 00003021 addu r6,r0,r0
0006a2cc: 9203007d lbu r3,0x007d(r16)
0006a2d0: 34020001 ori r2,r0,0x0001
0006a2d4: a202007f sb r2,0x007f(r16)
0006a2d8: 9202011c lbu r2,0x011c(r16)
0006a2dc: 246300ff addiu r3,r3,0x00ff
0006a2e0: 30420003 andi r2,r2,0x0003
0006a2e4: 0801a8c2 j 0x0006a308
0006a2e8: 00621823 subu r3,r3,r2
+Y
0006a2ec: 34060800 ori r6,r0,0x0800
0006a2f0: 9203007d lbu r3,0x007d(r16)
0006a2f4: a202007f sb r2,0x007f(r16)
0006a2f8: 9202011c lbu r2,0x011c(r16)
0006a2fc: 24630001 addiu r3,r3,0x0001
0006a300: 30420003 andi r2,r2,0x0003
0006a304: 00621821 addu r3,r3,r2
0006a308: a2030081 sb r3,0x0081(r16)		store new Y coordinate

0006a30c: 3c038009 lui r3,0x8009
0006a310: 8c6360e4 lw r3,0x60e4(r3)
0006a314: 3402002d ori r2,r0,0x002d
0006a318: 10620004 beq r3,r2,0x0006a32c		branch if control variable == 2d
0006a31c: 00000000 nop

0006a320: a6060070 sh r6,0x0070(r16)		store facing
0006a324: 0c020b7e jal 0x00082df8			00082bcc_-_00082e10 - set jump animations?
0006a328: 02002021 addu r4,r16,r0

0006a32c: 02002021 addu r4,r16,r0
0006a330: 02202821 addu r5,r17,r0
0006a334: 02603021 addu r6,r19,r0			tile data
0006a338: 0c01a67d jal 0x000699f4			000699f4 - 00069af4
0006a33c: 02403821 addu r7,r18,r0

0006a340: 8e050038 lw r5,0x0038(r16)
0006a344: 0c01a77f jal 0x00069dfc			00069dfc - 00069e64
0006a348: 02002021 addu r4,r16,r0

0006a34c: 92220000 lbu r2,0x0000(r17)
0006a350: 00000000 nop
0006a354: 00021142 srl r2,r2,0x05
0006a358: 30420001 andi r2,r2,0x0001
0006a35c: a2020082 sb r2,0x0082(r16)		store map level/flags?
0006a360: 8fbf0020 lw r31,0x0020(r29)
0006a364: 8fb3001c lw r19,0x001c(r29)
0006a368: 8fb20018 lw r18,0x0018(r29)
0006a36c: 8fb10014 lw r17,0x0014(r29)
0006a370: 8fb00010 lw r16,0x0010(r29)
0006a374: 27bd0028 addiu r29,r29,0x0028
0006a378: 03e00008 jr r31
0006a37c: 00000000 nop

Return locations

Battle.bin
0006c378: 0006c320 - 0006c3d4
0006c5fc: 0006c4f8 - 0006c78c
0006cf90: 0006cc94 - 0006d05c	Some Knockback Handling
0006dac4: 0006d818 - 0006db0c	Process Single Unit Movement
0006dc60: 0006db10 - 0006dc88	Attack animation handling?

< BATTLE.BIN Routines

< 0006a080 - 0006a208
0006a380 - 0006a534 >