Difference between revisions of "00124c54 - 00124f10"

From Final Fantasy Hacktics Wiki
Jump to navigation Jump to search
(Created page with "<font face='Courier New'> 00124c54: 27bdffb0 addiu r29,r29,0xffb0 00124c58: afb70044 sw r23,0x0044(r29) 00124c5c: 00e0b821 addu r23,r7,r0 00124c60: 93a70060 lbu r7,0x006...")
 
m (not what I'm after)
 
Line 4: Line 4:
 
  00124c58: afb70044 sw r23,0x0044(r29)
 
  00124c58: afb70044 sw r23,0x0044(r29)
 
  00124c5c: 00e0b821 addu r23,r7,r0
 
  00124c5c: 00e0b821 addu r23,r7,r0
  00124c60: 93a70060 lbu r7,0x0060(r29)
+
  00124c60: 93a70060 lbu r7,0x0060(r29) 0x60 stack
 
  00124c64: 34020001 ori r2,r0,0x0001
 
  00124c64: 34020001 ori r2,r0,0x0001
 
  00124c68: afbf004c sw r31,0x004c(r29)
 
  00124c68: afbf004c sw r31,0x004c(r29)
Line 26: Line 26:
 
  00124cb0: 10400003 beq r2,r0,0x00124cc0
 
  00124cb0: 10400003 beq r2,r0,0x00124cc0
 
  00124cb4: 34140001 ori r20,r0,0x0001
 
  00124cb4: 34140001 ori r20,r0,0x0001
  00124cb8: 34070002 ori r7,r0,0x0002
+
  00124cb8: 34070002 ori r7,r0,0x0002
  00124cbc: 34140001 ori r20,r0,0x0001
+
  00124cbc: 34140001 ori r20,r0,0x0001 set Item ID = 1
 
  00124cc0: 0000a821 addu r21,r0,r0
 
  00124cc0: 0000a821 addu r21,r0,r0
  00124cc4: 30f300ff andi r19,r7,0x00ff
+
  00124cc4: 30f300ff andi r19,r7,0x00ff r19 = 2
 
  00124cc8: 93a80020 lbu r8,0x0020(r29)
 
  00124cc8: 93a80020 lbu r8,0x0020(r29)
 
  00124ccc: 341e0005 ori r30,r0,0x0005
 
  00124ccc: 341e0005 ori r30,r0,0x0005
Line 37: Line 37:
 
  00124cdc: 00028603 sra r16,r2,0x18
 
  00124cdc: 00028603 sra r16,r2,0x18
 
  00124ce0: 34080003 ori r8,r0,0x0003
 
  00124ce0: 34080003 ori r8,r0,0x0003
  00124ce4: 16680006 bne r19,r8,0x00124d00
+
  00124ce4: 16680006 bne r19,r8,0x00124d00 branch if r19 != 0x3
  00124ce8: 02808821 addu r17,r20,r0
+
  00124ce8: 02808821 addu r17,r20,r0 Item ID
 
  00124cec: 00122403 sra r4,r18,0x10
 
  00124cec: 00122403 sra r4,r18,0x10
 
  00124cf0: 0c04822e jal 0x001208b8
 
  00124cf0: 0c04822e jal 0x001208b8
Line 99: Line 99:
 
  00124dd4: 12600013 beq r19,r0,0x00124e24
 
  00124dd4: 12600013 beq r19,r0,0x00124e24
 
  00124dd8: 00112c00 sll r5,r17,0x10
 
  00124dd8: 00112c00 sll r5,r17,0x10
  00124ddc: 97a80010 lhu r8,0x0010(r29)
+
  00124ddc: 97a80010 lhu r8,0x0010(r29) load unit formation ID
  00124de0: 00052c03 sra r5,r5,0x10
+
  00124de0: 00052c03 sra r5,r5,0x10 Item ID
 
  00124de4: 00082400 sll r4,r8,0x10
 
  00124de4: 00082400 sll r4,r8,0x10
  00124de8: 0c04915f jal 0x0012457c
+
  00124de8: 0c04915f jal 0x0012457c [[Can Unit equip Item ID]]
  00124dec: 00042403 sra r4,r4,0x10
+
  00124dec: 00042403 sra r4,r4,0x10 unit formation ID
 
  00124df0: 00402021 addu r4,r2,r0
 
  00124df0: 00402021 addu r4,r2,r0
  00124df4: 2e620002 sltiu r2,r19,0x0002
+
  00124df4: 2e620002 sltiu r2,r19,0x0002
 
  00124df8: 14400005 bne r2,r0,0x00124e10
 
  00124df8: 14400005 bne r2,r0,0x00124e10
 
  00124dfc: 34020001 ori r2,r0,0x0001
 
  00124dfc: 34020001 ori r2,r0,0x0001
 
  00124e00: 2402ffff addiu r2,r0,0xffff
 
  00124e00: 2402ffff addiu r2,r0,0xffff
  00124e04: 1082000b beq r4,r2,0x00124e34
+
  00124e04: 1082000b beq r4,r2,0x00124e34 branch if unit can't equip item
 
  00124e08: 3c020001 lui r2,0x0001
 
  00124e08: 3c020001 lui r2,0x0001
 
  00124e0c: 34020001 ori r2,r0,0x0001
 
  00124e0c: 34020001 ori r2,r0,0x0001
 
  00124e10: 16620004 bne r19,r2,0x00124e24
 
  00124e10: 16620004 bne r19,r2,0x00124e24
 
  00124e14: 2402ffff addiu r2,r0,0xffff
 
  00124e14: 2402ffff addiu r2,r0,0xffff
  00124e18: 14820002 bne r4,r2,0x00124e24
+
  00124e18: 14820002 bne r4,r2,0x00124e24 branch if unit can equip item
 
  00124e1c: 00000000 nop
 
  00124e1c: 00000000 nop
  00124e20: 36314000 ori r17,r17,0x4000
+
  00124e20: 36314000 ori r17,r17,0x4000 if can equip, enable 0x4000 flag on item
  00124e24: a6d10000 sh r17,0x0000(r22)
+
  00124e24: a6d10000 sh r17,0x0000(r22) store in list
  00124e28: 26d60002 addiu r22,r22,0x0002
+
  00124e28: 26d60002 addiu r22,r22,0x0002 next item in the item list pointer
  00124e2c: 26b50001 addiu r21,r21,0x0001
+
  00124e2c: 26b50001 addiu r21,r21,0x0001
 
  00124e30: 3c020001 lui r2,0x0001
 
  00124e30: 3c020001 lui r2,0x0001
  00124e34: 02429021 addu r18,r18,r2
+
  00124e34: 02429021 addu r18,r18,r2 r18 + 0x00010000 (shitty counter)
 
  00124e38: 26940001 addiu r20,r20,0x0001
 
  00124e38: 26940001 addiu r20,r20,0x0001
  00124e3c: 2a8200fe slti r2,r20,0x00fe
+
  00124e3c: 2a8200fe slti r2,r20,0x00fe do for every item
  00124e40: 1440ffa8 bne r2,r0,0x00124ce4
+
  00124e40: 1440ffa8 bne r2,r0,0x00124ce4 loope
 
  00124e44: 34080003 ori r8,r0,0x0003
 
  00124e44: 34080003 ori r8,r0,0x0003
 
  00124e48: 00151040 sll r2,r21,0x01
 
  00124e48: 00151040 sll r2,r21,0x01

Latest revision as of 05:42, 4 December 2022

00124c54: 27bdffb0 addiu r29,r29,0xffb0
00124c58: afb70044 sw r23,0x0044(r29)
00124c5c: 00e0b821 addu r23,r7,r0
00124c60: 93a70060 lbu r7,0x0060(r29)			0x60 stack
00124c64: 34020001 ori r2,r0,0x0001
00124c68: afbf004c sw r31,0x004c(r29)
00124c6c: afbe0048 sw r30,0x0048(r29)
00124c70: afb60040 sw r22,0x0040(r29)
00124c74: afb5003c sw r21,0x003c(r29)
00124c78: afb40038 sw r20,0x0038(r29)
00124c7c: afb30034 sw r19,0x0034(r29)
00124c80: afb20030 sw r18,0x0030(r29)
00124c84: afb1002c sw r17,0x002c(r29)
00124c88: afb00028 sw r16,0x0028(r29)
00124c8c: a7a40010 sh r4,0x0010(r29)
00124c90: a7a50018 sh r5,0x0018(r29)
00124c94: 30e300ff andi r3,r7,0x00ff
00124c98: 14620008 bne r3,r2,0x00124cbc
00124c9c: a3a60020 sb r6,0x0020(r29)
00124ca0: 3c028004 lui r2,0x8004
00124ca4: 8c4273ac lw r2,0x73ac(r2)
00124ca8: 3c030180 lui r3,0x0180
00124cac: 00431024 and r2,r2,r3
00124cb0: 10400003 beq r2,r0,0x00124cc0
00124cb4: 34140001 ori r20,r0,0x0001
00124cb8: 34070002 ori r7,r0,0x0002			
00124cbc: 34140001 ori r20,r0,0x0001			set Item ID = 1
00124cc0: 0000a821 addu r21,r0,r0
00124cc4: 30f300ff andi r19,r7,0x00ff			r19 = 2
00124cc8: 93a80020 lbu r8,0x0020(r29)
00124ccc: 341e0005 ori r30,r0,0x0005
00124cd0: 3c120001 lui r18,0x0001
00124cd4: 02e0b021 addu r22,r23,r0
00124cd8: 00081600 sll r2,r8,0x18
00124cdc: 00028603 sra r16,r2,0x18
00124ce0: 34080003 ori r8,r0,0x0003
00124ce4: 16680006 bne r19,r8,0x00124d00		branch if r19 != 0x3
00124ce8: 02808821 addu r17,r20,r0			Item ID
00124cec: 00122403 sra r4,r18,0x10
00124cf0: 0c04822e jal 0x001208b8
00124cf4: 00002821 addu r5,r0,r0
00124cf8: 08049343 j 0x00124d0c
00124cfc: 00402021 addu r4,r2,r0
00124d00: 0c048df9 jal 0x001237e4
00124d04: 00122403 sra r4,r18,0x10
00124d08: 00402021 addu r4,r2,r0
00124d0c: 10800049 beq r4,r0,0x00124e34
00124d10: 3c020001 lui r2,0x0001
00124d14: 00112400 sll r4,r17,0x10
00124d18: 0c0494dd jal 0x00125374
00124d1c: 00042403 sra r4,r4,0x10
00124d20: 00401821 addu r3,r2,r0
00124d24: 2a020002 slti r2,r16,0x0002
00124d28: 10400003 beq r2,r0,0x00124d38
00124d2c: 00002021 addu r4,r0,r0
00124d30: 08049373 j 0x00124dcc
00124d34: 28640002 slti r4,r3,0x0002
00124d38: 34020002 ori r2,r0,0x0002
00124d3c: 16020005 bne r16,r2,0x00124d54
00124d40: 34080003 ori r8,r0,0x0003
00124d44: 14700021 bne r3,r16,0x00124dcc
00124d48: 00000000 nop
00124d4c: 08049373 j 0x00124dcc
00124d50: 34040001 ori r4,r0,0x0001
00124d54: 16080005 bne r16,r8,0x00124d6c
00124d58: 34020004 ori r2,r0,0x0004
00124d5c: 1470001b bne r3,r16,0x00124dcc
00124d60: 00000000 nop
00124d64: 08049373 j 0x00124dcc
00124d68: 34040001 ori r4,r0,0x0001
00124d6c: 16020005 bne r16,r2,0x00124d84
00124d70: 00000000 nop
00124d74: 14700015 bne r3,r16,0x00124dcc
00124d78: 00000000 nop
00124d7c: 08049373 j 0x00124dcc
00124d80: 34040001 ori r4,r0,0x0001
00124d84: 161e0005 bne r16,r30,0x00124d9c
00124d88: 34020006 ori r2,r0,0x0006
00124d8c: 1460000f bne r3,r0,0x00124dcc
00124d90: 00000000 nop
00124d94: 08049373 j 0x00124dcc
00124d98: 34040001 ori r4,r0,0x0001
00124d9c: 16020006 bne r16,r2,0x00124db8
00124da0: 34020007 ori r2,r0,0x0007
00124da4: 34020001 ori r2,r0,0x0001
00124da8: 14620008 bne r3,r2,0x00124dcc
00124dac: 00000000 nop
00124db0: 08049373 j 0x00124dcc
00124db4: 34040001 ori r4,r0,0x0001
00124db8: 16020004 bne r16,r2,0x00124dcc
00124dbc: 00000000 nop
00124dc0: 147e0002 bne r3,r30,0x00124dcc
00124dc4: 00000000 nop
00124dc8: 34040001 ori r4,r0,0x0001
00124dcc: 10800019 beq r4,r0,0x00124e34
00124dd0: 3c020001 lui r2,0x0001
00124dd4: 12600013 beq r19,r0,0x00124e24
00124dd8: 00112c00 sll r5,r17,0x10
00124ddc: 97a80010 lhu r8,0x0010(r29)			load unit formation ID
00124de0: 00052c03 sra r5,r5,0x10			Item ID
00124de4: 00082400 sll r4,r8,0x10
00124de8: 0c04915f jal 0x0012457c			Can Unit equip Item ID
00124dec: 00042403 sra r4,r4,0x10			unit formation ID
00124df0: 00402021 addu r4,r2,r0
00124df4: 2e620002 sltiu r2,r19,0x0002			
00124df8: 14400005 bne r2,r0,0x00124e10
00124dfc: 34020001 ori r2,r0,0x0001
00124e00: 2402ffff addiu r2,r0,0xffff
00124e04: 1082000b beq r4,r2,0x00124e34		branch if unit can't equip item
00124e08: 3c020001 lui r2,0x0001
00124e0c: 34020001 ori r2,r0,0x0001
00124e10: 16620004 bne r19,r2,0x00124e24
00124e14: 2402ffff addiu r2,r0,0xffff
00124e18: 14820002 bne r4,r2,0x00124e24		branch if unit can equip item
00124e1c: 00000000 nop
00124e20: 36314000 ori r17,r17,0x4000			if can equip, enable 0x4000 flag on item
00124e24: a6d10000 sh r17,0x0000(r22)			store in list
00124e28: 26d60002 addiu r22,r22,0x0002		next item in the item list pointer
00124e2c: 26b50001 addiu r21,r21,0x0001		
00124e30: 3c020001 lui r2,0x0001
00124e34: 02429021 addu r18,r18,r2			r18 + 0x00010000 (shitty counter)
00124e38: 26940001 addiu r20,r20,0x0001
00124e3c: 2a8200fe slti r2,r20,0x00fe			do for every item
00124e40: 1440ffa8 bne r2,r0,0x00124ce4		loope
00124e44: 34080003 ori r8,r0,0x0003
00124e48: 00151040 sll r2,r21,0x01
00124e4c: 00571021 addu r2,r2,r23
00124e50: 2403ffff addiu r3,r0,0xffff
00124e54: a4430000 sh r3,0x0000(r2)
00124e58: 93a80020 lbu r8,0x0020(r29)
00124e5c: 00000000 nop
00124e60: 00081600 sll r2,r8,0x18
00124e64: 00021e03 sra r3,r2,0x18
00124e68: 14600003 bne r3,r0,0x00124e78
00124e6c: 34040064 ori r4,r0,0x0064
00124e70: 080493a6 j 0x00124e98
00124e74: 00002021 addu r4,r0,r0
00124e78: 28620005 slti r2,r3,0x0005
00124e7c: 10400003 beq r2,r0,0x00124e8c
00124e80: 34020007 ori r2,r0,0x0007
00124e84: 080493a6 j 0x00124e98
00124e88: 2464ffff addiu r4,r3,0xffff
00124e8c: 14620003 bne r3,r2,0x00124e9c
00124e90: 28820005 slti r2,r4,0x0005
00124e94: 34040004 ori r4,r0,0x0004
00124e98: 28820005 slti r2,r4,0x0005
00124e9c: 1040000c beq r2,r0,0x00124ed0
00124ea0: 02e02821 addu r5,r23,r0
00124ea4: 97a80018 lhu r8,0x0018(r29)
00124ea8: 00000000 nop
00124eac: 2502ffff addiu r2,r8,0xffff
00124eb0: 3042ffff andi r2,r2,0xffff
00124eb4: 2c420005 sltiu r2,r2,0x0005
00124eb8: 10400006 beq r2,r0,0x00124ed4
00124ebc: 00000000 nop
00124ec0: 0c048836 jal 0x001220d8
00124ec4: 02e02821 addu r5,r23,r0
00124ec8: 080493b7 j 0x00124edc
00124ecc: 0040a821 addu r21,r2,r0
00124ed0: 97a80018 lhu r8,0x0018(r29)
00124ed4: 0c048595 jal 0x00121654
00124ed8: 3104000f andi r4,r8,0x000f
00124edc: 02a01021 addu r2,r21,r0
00124ee0: 8fbf004c lw r31,0x004c(r29)
00124ee4: 8fbe0048 lw r30,0x0048(r29)
00124ee8: 8fb70044 lw r23,0x0044(r29)
00124eec: 8fb60040 lw r22,0x0040(r29)
00124ef0: 8fb5003c lw r21,0x003c(r29)
00124ef4: 8fb40038 lw r20,0x0038(r29)
00124ef8: 8fb30034 lw r19,0x0034(r29)
00124efc: 8fb20030 lw r18,0x0030(r29)
00124f00: 8fb1002c lw r17,0x002c(r29)
00124f04: 8fb00028 lw r16,0x0028(r29)
00124f08: 27bd0050 addiu r29,r29,0x0050
00124f0c: 03e00008 jr r31
00124f10: 00000000 nop