• Welcome to Final Fantasy Hacktics. Please login or sign up.
 
June 05, 2020, 03:21:36 pm

News:

Use of ePSXe before 2.0 is highly discouraged. Mednafen/RetroArch is recommended for playing/testing, pSX is recommended for debugging.


Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Pride

1
The Lion War / Re: FFT - The Lion War
November 07, 2018, 02:37:30 am
There is already a little bit of free space in SCUS, but I think only Xiffy has posted any hacks that use it
2
Tutorials and Learning / Re: Tutorial Requests
October 13, 2018, 03:53:46 pm
Well building new formulas isn't terrible difficult, and yes we can replace those blank formulas with new custom formulas. In terms of making what programs we use, I use Xifanie's Spreadsheet but we can just use a text editor like Notepad or Notepad++, FFTorgASM, and MassHexASM if you're not super familiar with excel or you don't have it. So first we need to a spot to place a this new hack. Allocated Space has sections of BATTLE.bin that are being used or planned on being used by ASMers. If you don't plan on using a hack from one of these hackers we can take spot from there or take a spot in the kanji space that isn't being used. We'll borrow the start of Sentinal Blade's section (0xEA0E4) for this example. We'll add 0x67000 to this offset so we can get its proper place in RAM or 0x801510E4 (see Offset Conversion).

Now that we have where the hack will go, we'll change the pointer found on the Formula Table. We'll change the pointer for Formula 18 at 0x0018F670 to E4101580. Remember we have to flip these bytes or you'll end up somewhere you don't want to be and just crash the game when you try to use an ability with this formula. As a note, we can move these pointers for formulas that we aren't going to use anyways and write new code; I'm just using formula 18 since you mentioned the blank ones but I could move the pointer to any of the others. Now, we might as well set up our new xml at this time too.


<?xml version="1.0" encoding="utf-8" ?>
<Patches>
  <Patch name="Formula 18 Edit">
    <Location file="BATTLE_BIN" offset="128670">      #Offset to table location; remember this is saving to the file and not RAM so we -0x67000 from the offset
      E4101580      #new pointer
    </Location>
    <Location file="BATTLE_BIN" offset="EA0E4">         #Offset to new formula routine
 
  </Location>
  </Patch>

</Patches>


Now that we have all our set up done, let's take a look at how formulas are set up. We can look at vanilla formulas to see how they normally go through the modifier routines and all that. Formula 31 or Formula 08 are good examples to see how the game normally processes these. Typically they'll go Evasion Routines -> Set Base XA & YA -> XA Modifiers -> XA */+ YA -> Elemental Half, Resist, and Immunity -> Faith -> Elemental Absorb -> Status. You can also do stuff like putting the dragon check or steals equipment at the start of the routine. Here's a list of some commonly used routines or if you want to look at most of the routines in BATTLE.BIN check here.



01 80188510   Physical Evasion
02 801885b8 Magical Evasion   
03 80185a9c Base Weapon XA & YA   
04 80185c94 Store MA and Y
05 80185cc0 Base XA and YA for MA + Y / 2
06 80185d00 Store PA and PA + Y / 2
07 80185d40 Store MA and PA + Y / 2
08 80185d80 Store MA and X
09 80185dac Store PA and X
10 80185dd8 Store PA and WP
11 80185e04 Store PA and Y
12 80185e30 Store Speed and X
13 80185e5c Store PA and WP + Y
14 80185e94 Formula 64 or Jump Base XA / YA   
15 80186568 XA * YA
16 8018659c XA + YA
17 80187510 Store Accuracy from XA + YA
18 80185f80 Charge Calculation
19 80185fa4 Weapon Elemental Boost
20 80185ffc Ability Elemental Boost
21 80184964 Compat
22 80186054 Attack Up/Two Hands/Martial Arts
23 8018614c Attack Up/Martial Arts
24 80186204 Magic Attack Up
25 80186254 Attacker Berserk/Frog Check
26 801862cc Defense Up
27 8018631c Magic Defense Up
28 8018636c   Protect/Frog/Chicken/Sleeping/Charging
29 80186460   Shell/Frog/Chicken
30 801864f8   Critical Hit
31 80186ed0   Weather Effects
32 80186ff8   Elemental Effects (Oil, Float, Weak, etc)
33 801870fc   Absorb Element
34 80187eb4 Status Roll
35 80187150   Faith Calculation
36 80187f24   Status Ability Inflict
37 8018acdc   Cancel: Dead for Raise skills
38 80186624   Deal % (Y/100) HP Damage
39 80187350   Undead Reversal



Now lets make a simple PA * Y formula that uses Physical Evasion, Faith (?), and inflicts Status. Let's put in the basic frame work. You'll need this for most formulas and you shouldn't change it unless you know what you're doing.



addiu r29,r29,-0x0018
sw r31,0x0010(r29)


lw r31,0x0010(r29)
addiu r29,r29,0x0018
jr r31
nop



Now let's add in physical evasion and a check to make sure the attack hit



addiu r29,r29,-0x0018
sw r31,0x0010(r29)
jal 0x80188510            #Physical Evasion
nop                     
bne r2,r0,END            #Jump to end if attack was evaded
nop

END: lw r31,0x0010(r29)
addiu r29,r29,0x0018
jr r31
nop



The END is a tag to let FFTorgASM and MassHexASM know where you want this branch to go. Alright, now we can follow the little outline and add in the rest of the functions I wanted to put in.



addiu r29,r29,-0x0018
sw r31,0x0010(r29)
jal 0x80188510            #Physical Evasion
nop                     
bne r2,r0,END            #Jump to end if attack was evaded
nop
jal 0x80185e04            #Get PA & Y
nop
jal 0x80186568            #XA * YA or in this case PA * Y
nop
jal 0x80187150            #Calculate Faith
nop
jal 0x80187eb4            #Status Roll
nop
END: lw r31,0x0010(r29)
addiu r29,r29,0x0018
jr r31
nop



Hopefully you can follow exactly where I got these values off the list and why they are in the places that they are. We can compile this code in MassHexASM, take the hex values it outputs and add them to our xml but let's add in some other modifiers as well.



addiu r29,r29,-0x0018
sw r31,0x0010(r29)
jal 0x80188510            #Physical Evasion
nop                     
bne r2,r0,END            #Jump to end if attack was evaded
nop
jal 0x80185e04            #Get PA & Y
nop
jal 0x80185ffc            #Ability Elemental Strengthen Routine (XA Modifier)
nop
jal 0x80186204            #Magic Attack Up (XA Modifier)
nop
jal 0x801862cc            #Defense Up (XA Modifier)
nop
jal 0x80186568            #XA * YA or in this case PA * Y
nop
jal 0x80187150            #Calculate Faith
nop
jal 0x80187eb4            #Status Roll
nop
END: lw r31,0x0010(r29)
addiu r29,r29,0x0018
jr r31
nop



Well it takes Magic Attack Up and Defense Up but that's fine, it'll just be some wacky physical/magical hybrid attack. But we added elemental strengthen but not half/resist/immunity/absorb, and that's cause we cant just link to the absorb routine, we need to set up a check specifically for the immunity part.



addiu r29,r29,-0x0018
sw r31,0x0010(r29)
jal 0x80188510            #Physical Evasion
nop                     
bne r2,r0,END            #Jump to end if attack was evaded
nop
jal 0x80185e04            #Get PA & Y
nop
jal 0x80185ffc            #Ability Elemental Strenghten Routine
nop
jal 0x80186204            #Magic Attack Up
nop
jal 0x801862cc            #Defense Up
nop
jal 0x80186568            #XA * YA or in this case PA * Y
nop
jal 0x80186ff8            #Elemental Half/Resist/Immunity
nop
lui r2,0x8019
lw r2,0x2d90(r2)         #Load Defender's Data
nop                     
lbu r2,0x0000(r2)         #Load byte that stores if the attack will hit
nop
beq r2,r0,END            #Jump to end if attack was affected by Immunity
nop                     
jal 0x80187150            #Calculate Faith
nop
jal 0x801870fc            #Elemental Absorb
nop
jal 0x80187eb4            #Status Roll
nop
END: lw r31,0x0010(r29)
addiu r29,r29,0x0018
jr r31
nop



Okay now I'm happy with this code and we can put it into MassHexASM and get the output and place that into our xml and save that.



<?xml version="1.0" encoding="utf-8" ?>
<Patches>
  <Patch name="Formula 18 Edit">
    <Location file="BATTLE_BIN" offset="128670">
      E4101580      #new pointer
    </Location>
    <Location file="BATTLE_BIN" offset="EA0E4">
      E8FFBD27
      1000BFAF
      4421060C
      00000000
      1A004014
      00000000
      8117060C
      00000000
      FF17060C
      00000000
      8118060C
      00000000
      B318060C
      00000000
      5A19060C
      00000000
      FE1B060C
      00000000
      1980023C
      902D428C
      00000000
      00004290
      00000000
      07004010
      00000000
      541C060C
      00000000
      3F1C060C
      00000000
      AD1F060C
      00000000
      1000BF8F
      1800BD27
      0800E003
      00000000
  </Location>
  </Patch>
</Patches>



This would be good enough to change the formula entirely. For some of the stuff you want you would need to write new XA & YA storage routines, like in this example instead of jal 0x80185e04 you would do jal 0x80?????? to the new section where you write your code to store these values. Or you could write it inline with the rest of the code. Regardless I hope this information helps.
3
Help! / Re: Unaligned offset at address xxxx
October 12, 2018, 10:56:44 pm
This one should be correct
4
Help! / Re: Help coding new stealing/breaking routine
August 27, 2018, 03:18:46 am
What does the rest of the routine look like?
5
Sir that's awesome and a vierra has been requested for some time
6
Im really excited for fran, excellent work sir
7
@xifanie i know the world conditionals you put up but i dont remember seeing the attack.out
8
Oh! New stuff! That routine you documented is battle.bin? Just wanted to double check
9
PSX FFT Hacking / Re: Pride's ASM Thread
May 04, 2018, 01:55:17 am
Its been a while since I've posted anything and I thought that wasn't cool since I've been working on a bunch of stuff and I haven't been sharing so just dropping off a few.

[13] Move +1/2/3 & Jump +1/2/3 edits

  • Turns Move +1 into Move +?

  • Turns Move +2 into Jump +?

  • Turns Move + 3 into PA +?

  • Turns Jump +1 into MA +?

  • Turns Jump +2 into Speed +?

  • Turns Jump +3 into Class Evade +?

  • Keep the variables the same for the pairs otherwise you'll throw off the preview when you equip the movements.



[14] Transparent not lost on action or taking damage

  • Transparent status is no longer removed after taking an action or taking damage.

  • This is intended to be used with CT Magic. Unless you want permanent Transparent.



[15] Defend not removed on act

  • Defend status is no longer removed after taking an action.

  • This is intended to be used with CT Magic. Unless you want permanent Defending.



[16] New Support: Inflict Status (ID) to Weapon Attacks

  • Inflict Status: ID to weapon attacks (except Fists) that do not have a proc already.

  • Check your FFTPatcher to make sure you are adding (or cancelling) the status you want to be. Defaulted to 09 (Poison).

  • This is defaulted over Secret Hunt. Edit unit data to choose which data is checked. See http://ffhacktics.com/wiki/Data/Table_Locations for more information.



[17] Disable Secret Hunt

  • Removes the vanilla function of Secret Hunt; poaching monsters.

10
PSX FFT Hacking / Re: ASM Requests
March 16, 2018, 12:01:49 pm
I thought this already existed but i can only find the 0 growths hack which affects all the other stats. Poke around some more and it might be available
11
PSX FFT Hacking / Re: Possible to change raw stats?
February 26, 2018, 04:08:23 pm
http://ffhacktics.com/wiki/Data/Table_Locations

The raw stats can be found in scus but you would have to edit them yourself

Edit: Xifanie has the way
12
PSX FFT Hacking / Re: Pokemon Tactics?
February 26, 2018, 02:35:05 pm
Love you too <3
13
PSX FFT Hacking / Re: Pokemon Tactics?
February 26, 2018, 11:11:23 am
Oh man I always get called out on it :(
14
PSX FFT Hacking / Re: Pride's ASM Thread
January 29, 2018, 12:53:45 pm
Not tested cause I didn't think of it but it should be prevented
15
PSX FFT Hacking / Re: Rebalanced Knight Swords
January 25, 2018, 07:25:56 pm
Yeah its the Weapon Strike flag that causes that behavior, so it still functions as intended (using ability element) but it causes the AI to think its the weapon element.
16
PSX FFT Hacking / Re: Rebalanced Knight Swords
January 25, 2018, 12:35:49 pm
The correct element will still work just fine but you'll get a derpy ai with weapon strike flagged, ie the Wiegraf 1v1 fight
17
PSX FFT Hacking / Re: ASM Requests
January 25, 2018, 12:28:09 pm
You'd have code new stuff in asm if you can't find what you need already created in FFTorgASM
18
Have you tried using a different iso?
19
Help! / Re: Unused spritesheets on Shishi
January 18, 2018, 08:15:17 pm
Replace away!
20
Help! / Re: Having trouble starting up FFTorgASM
December 26, 2017, 07:01:02 pm
That error looks like your windows doesn't like it but I'm not computer savvy enough to know any sort of fix to this.

But you can still apply patches without FFTorgASM, if you have excel you can use Xifanie's Spreadsheet template to upload the .xml and it can apply the patches to the iso or savestate. Or the old fashion way with a hex editor and cdmage.