Difference between revisions of "Player Skill Set"

From Final Fantasy Hacktics Wiki
Jump to navigation Jump to search
Line 91: Line 91:
 
  00181520: 00000000 nop r6 = 08 or 0f
 
  00181520: 00000000 nop r6 = 08 or 0f
 
  00181524: 30c6000f andi r6,r6,0x000f
 
  00181524: 30c6000f andi r6,r6,0x000f
  00181528: 0c060561 jal 0x00181584
+
  00181528: 0c060561 jal 0x00181584 skill set loading
 
  0018152c: a2460000 sb r6,0x0000(r18) store r6 into 17404c
 
  0018152c: a2460000 sb r6,0x0000(r18) store r6 into 17404c
 
  00181530: 14400003 bne r2,r0,0x00181540
 
  00181530: 14400003 bne r2,r0,0x00181540

Revision as of 17:02, 27 November 2012

Player Skill Set:
001813c0: 27bdffd0 addiu r29,r29,0xffd0		
001813c4: afb40020 sw r20,0x0020(r29)		
001813c8: 0080a021 addu r20,r4,r0		
001813cc: afb00010 sw r16,0x0010(r29)		
001813d0: 00a08021 addu r16,r5,r0		
001813d4: afb10014 sw r17,0x0014(r29)		
001813d8: 00c08821 addu r17,r6,r0		
001813dc: afb20018 sw r18,0x0018(r29)		
001813e0: 00e09021 addu r18,r7,r0		
001813e4: afbf0028 sw r31,0x0028(r29)		
001813e8: afb50024 sw r21,0x0024(r29)		
001813ec: 0c060435 jal 0x001810d4		Get unit data pointer
001813f0: afb3001c sw r19,0x001c(r29)		
001813f4: 00401821 addu r3,r2,r0		
001813f8: 10600058 beq r3,r0,0x0018155c		Skip routine if unit != exist
001813fc: 2402ffff addiu r2,r0,0xffff		
00181400: 90670012 lbu r7,0x0012(r3)		Load Primary Skill Set?
00181404: 90650013 lbu r5,0x0013(r3)		Load Secondary Skill Set?
00181408: 30e400ff andi r4,r7,0x00ff		
0018140c: 2c8200b0 sltiu r2,r4,0x00b0		
00181410: 10400004 beq r2,r0,0x00181424		Branch if using a Monster Skill Set?
00181414: 02004021 addu r8,r16,r0		
00181418: 2ca200b0 sltiu r2,r5,0x00b0		
0018141c: 1440000b bne r2,r0,0x0018144c		Branch if using a Monster Skill  Set?(secondary)
00181420: 00000000 nop				
00181424: a2070000 sb r7,0x0000(r16)		store skillset
00181428: a2200000 sb r0,0x0000(r17)		store skillset
0018142c: 3c018006 lui r1,0x8006		
00181430: 00240821 addu r1,r1,r4		r1 = 8006+skillset
00181434: 90235cb4 lbu r3,0x5cb4(r1)		Load Action Menu
00181438: 34020001 ori r2,r0,0x0001		r2 = 1
0018143c: a2430000 sb r3,0x0000(r18)		
00181440: 340300ff ori r3,r0,0x00ff		
00181444: 08060557 j 0x0018155c			(jump to end if monster)
00181448: a2030001 sb r3,0x0001(r16)	 	
0018144c: 9062005a lbu r2,0x005a(r3)(jump here if not monster)	Load 3rd set of  Current Status
00181450: 90660092 lbu r6,0x0092(r3)		Load 4th set of Support
00181454: 30420002 andi r2,r2,0x0002		
00181458: 10400002 beq r2,r0,0x00181464		Branch if Unit is not Frog
0018145c: 00000000 nop				
00181460: 00003021 addu r6,r0,r0		if frog, clear r6
00181464: 9062005c lbu r2,0x005c(r3)		Load 5th set of Current Status
00181468: 00000000 nop
0018146c: 30420004 andi r2,r2,0x0004		
00181470: 14400006 bne r2,r0,0x0018148c		Branch if the unit is not under  Don't Act
00181474: 340200ff ori r2,r0,0x00ff		R2 = F F
00181478: 90620182 lbu r2,0x0182(r3)		Load Usability Pointers(mounted  flags)
0018147c: 00000000 nop				
00181480: 30420040 andi r2,r2,0x0040		set if being ridden
00181484: 10400003 beq r2,r0,0x00181494		Branch if unit is in "Deep Water"
00181488: 340200ff ori r2,r0,0x00ff		R2 = FF
0018148c: 08060556 j 0x00181558			Jump to end
00181490: a2020000 sb r2,0x0000(r16)		store ff into 174060
00181494: 34020001 ori r2,r0,0x0001		R2 = 1
00181498: a2020000 sb r2,0x0000(r16)		store 01 into 174060
0018149c: 10800006 beq r4,r0,0x001814b8		jump if primary skillset = 00
001814a0: 26100001 addiu r16,r16,0x0001		r16 = 174061
001814a4: 34020018 ori r2,r0,0x0018		r2 = 18
001814a8: 10820003 beq r4,r2,0x001814b8		jump if primary skillset = mimic****
001814ac: 00000000 nop				
001814b0: a2070000 sb r7,0x0000(r16)		store primary skillset into 174061
001814b4: 26100001 addiu r16,r16,0x0001		r16=174062
001814b8: 10a00003 beq r5,r0,0x001814c8		jump if secondary skillset = 00
001814bc: 30c20040 andi r2,r6,0x0040		r2= 01 if has defend
001814c0: a2050000 sb r5,0x0000(r16)		store secondary skillset into 174062
001814c4: 26100001 addiu r16,r16,0x0001		r16= 174063
001814c8: 10400003 beq r2,r0,0x001814d8		jump if unit doesn't have defend
001814cc: 34020002 ori r2,r0,0x0002		r2= 02
001814d0: a2020000 sb r2,0x0000(r16)		store r2 into 174063
001814d4: 26100001 addiu r16,r16,0x0001		r16= 174064
001814d8: 30c20020 andi r2,r6,0x0020		r2= 01 if has equip change
001814dc: 10400004 beq r2,r0,0x001814f0		if not, jump
001814e0: 341500ff ori r21,r0,0x00ff		r21 = ff
001814e4: 34020003 ori r2,r0,0x0003		f2 = 03
001814e8: a2020000 sb r2,0x0000(r16)		store equip change into 174064
001814ec: 26100001 addiu r16,r16,0x0001		r16 = 174065
001814f0: 340200ff ori r2,r0,0x00ff		r2 = ff
001814f4: a2020000 sb r2,0x0000(r16)		store ff into 174065
If equip change and defend are not equipped, 174063 = ff, 174064 and 174065 = 00
001814f8: 02208021 addu r16,r17,r0		r16 = 17403c
001814fc: 01008821 addu r17,r8,r0		r17 = 174060
00181500: 26130006 addiu r19,r16,0x0006		r19 = 174042
00181504: 92250000 lbu r5,0x0000(r17)		load value at 174060 into r5
00181508: 00000000 nop				
0018150c: 10b50012 beq r5,r21,0x00181558	if r5= ff, jump to end	
00181510: 02802021 addu r4,r20,r0		r4 = r20 (10?)
00181514: 3c018006 lui r1,0x8006		
00181518: 00250821 addu r1,r1,r5		r1= 80060000 + value of 174060
0018151c: 90265cb4 lbu r6,0x5cb4(r1)		Load Action Menus (act?)
00181520: 00000000 nop				r6 = 08 or 0f
00181524: 30c6000f andi r6,r6,0x000f		
00181528: 0c060561 jal 0x00181584		skill set loading
0018152c: a2460000 sb r6,0x0000(r18)		store r6 into 17404c
00181530: 14400003 bne r2,r0,0x00181540		
00181534: 34020001 ori r2,r0,0x0001		
00181538: 08060551 j 0x00181544			
0018153c: a2020000 sb r2,0x0000(r16)		
00181540: a2000000 sb r0,0x0000(r16)		
00181544: 26100001 addiu r16,r16,0x0001		
00181548: 26520001 addiu r18,r18,0x0001		
0018154c: 0213102a slt r2,r16,r19		
00181550: 1440ffec bne r2,r0,0x00181504		
00181554: 26310001 addiu r17,r17,0x0001		
00181558: 00001021 addu r2,r0,r0		
0018155c: 8fbf0028 lw r31,0x0028(r29)		
00181560: 8fb50024 lw r21,0x0024(r29)		
00181564: 8fb40020 lw r20,0x0020(r29)		
00181568: 8fb3001c lw r19,0x001c(r29)		
0018156c: 8fb20018 lw r18,0x0018(r29)		
00181570: 8fb10014 lw r17,0x0014(r29)		
00181574: 8fb00010 lw r16,0x0010(r29)		
00181578: 27bd0030 addiu r29,r29,0x0030		
0018157c: 03e00008 jr r31			
00181580: 00000000 nop


Return Locations

00140514: - Routine at 1404cc