Difference between revisions of "WORLD.BIN Check For Two Swords"

From Final Fantasy Hacktics Wiki
Jump to navigation Jump to search
(Created page with "<font face='Courier New'> Loads and checks for 2 swords support ability from formation data 00122884: 00042400 sll r4,r4,0x10 00122888: 00042383 sra r4,r4,0x0e 0012288...")
 
m (RetroTypes moved page Check For Two Swords to WORLD.BIN Check For Two Swords: Renaming routines to have file name in them for clarity)
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
<font face='Courier New'>
 
 
Loads and checks for 2 swords support ability from formation data
 
 
   
 
   
 
  00122884: 00042400 sll r4,r4,0x10
 
  00122884: 00042400 sll r4,r4,0x10
Line 7: Line 4:
 
  0012288c: 3c01801d lui r1,0x801d
 
  0012288c: 3c01801d lui r1,0x801d
 
  00122890: 00240821 addu r1,r1,r4
 
  00122890: 00240821 addu r1,r1,r4
  00122894: 8c22d5ec lw r2,-0x2a14(r1)
+
  00122894: 8c22d5ec lw r2,-0x2a14(r1)                   #r2 = Unit Data pointer?
 
  00122898: 00000000 nop
 
  00122898: 00000000 nop
  0012289c: 90420126 lbu r2,0x0126(r2) #loads formation supports 3?
+
  0012289c: 90420126 lbu r2,0x0126(r2)                   #Equipped Supports 3?
 
  001228a0: 03e00008 jr r31
 
  001228a0: 03e00008 jr r31
  001228a4: 30420001 andi r2,r2,0x0001 #filters out just 2 swords
+
  001228a4: 30420001 andi r2,r2,0x0001                   #Check for Two Swords Support equipped
</font>
 

Latest revision as of 08:04, 23 April 2025

00122884: 00042400 sll r4,r4,0x10
00122888: 00042383 sra r4,r4,0x0e
0012288c: 3c01801d lui r1,0x801d
00122890: 00240821 addu r1,r1,r4
00122894: 8c22d5ec lw r2,-0x2a14(r1)                   #r2 = Unit Data pointer?
00122898: 00000000 nop
0012289c: 90420126 lbu r2,0x0126(r2)                   #Equipped Supports 3?
001228a0: 03e00008 jr r31
001228a4: 30420001 andi r2,r2,0x0001                   #Check for Two Swords Support equipped