• Welcome to Final Fantasy Hacktics. Please login or sign up.
 
April 28, 2024, 07:11:02 am

News:

Don't be hasty to start your own mod; all our FFT modding projects are greatly understaffed! Find out how you can help in the Recruitment section or our Discord!


ALMA 4: Excalibur grants Forever: Orlandu

Started by pokeytax, February 07, 2011, 06:01:18 pm

pokeytax

June 14, 2011, 06:07:28 pm #120 Last Edit: June 14, 2011, 06:15:58 pm by pokeytax
Okay, RAD is at a good stopping place now, so I'm moving back to this.

ALMA 3 in the original post now has limited previewability: for items only, constant HP/MP/PA/MA/SP/MOV/JMP bonuses and penalties will show up. Of course I'm going to work on the crazy multiplier stuff and R/S/M preview later, but at least you can put HP on a shield now without wincing.
  • Modding version: PSX

RavenOfRazgriz

June 15, 2011, 04:35:44 pm #121 Last Edit: June 15, 2011, 04:43:37 pm by RavenOfRazgriz
Nice, I'm assuming that figuring this out means figuring out the rest won't be impossible.

Also, could you make it possible for ALMA Attributes and related stuff to modify Brave and Faith as well?  I'm looking and don't see any options for it despite it being a far more obvious choice than some of the stuff there.  Not a huge deal, but it would open up more possibilities for equipment, which is always good.

E: Have you tested your Extra Slot skillsets with the AI having a Primary, Secondary, Extra 1, and Extra 2 skillset that each only had 1 skill in it?  I remember FDC finding that the AI can only "remember" 34 skills, including the Attack Command, so I'm wondering if your Extra Slot testings only counting the first skillset are due to them breaking the 34 skill limit.  If they only have 4 skills that are incredibly distinct (Say, Dash in Primary, Potion in Secondary, Fire in Extra Skillset 1, and Phoenix Down in Extra Skillset 2), you can easily test to see if it can use all of them.

pokeytax

June 15, 2011, 09:03:19 pm #122 Last Edit: June 15, 2011, 09:04:28 pm by pokeytax
Quote from: RavenOfRazgriz on June 15, 2011, 04:35:44 pm
Also, could you make it possible for ALMA Attributes and related stuff to modify Brave and Faith as well?  I'm looking and don't see any options for it despite it being a far more obvious choice than some of the stuff there.


It is an obvious choice, just somewhat tricky. HP/MP/SP/PA/MA are "constructed stats": they are rebuilt from raw stats, which are safely stored away. So changing HP in ALMA doesn't change the unit's "true" HP. R/S/M and statuses are likewise rebuilt from your current job and equipped abilities and items.

Brave and Faith, though, are persistent numbers, like your zodiac and level and name. Change them and they stay changed. If ALMA says "HP = HP + 5" then it works fine, but if ALMA says "Brave = Brave + 5" then you will quickly have 100 Brave after a few cycles. Disabling permanent Brave/Faith loss/gain in battle and manually rebuilding Brave/Faith every time still presents problems; anything else affecting Brave (e.g. Threaten) will wear off when ALMA triggers. So at the least, you need to consider disabling any other form of Brave/Faith modification, which is a bummer.

That said I'm trying to work around that somehow because it would be neat!

Quote
E: Have you tested your Extra Slot skillsets with the AI having a Primary, Secondary, Extra 1, and Extra 2 skillset that each only had 1 skill in it?


My hack isn't even trying to plug in Extra 2, my understanding of that section of the code isn't that good. It's just Xifanie's A9 hack with a coat of paint. I truly hate not supplying functionality someone actually wants for a real live patch, but I banged my head against this for a while and got nowhere. The cost-benefit analysis says move on and try to pick four low-hanging oranges instead of one apple. I know you want an apple, and I really hate leaving it there. But four oranges, man, that's a lot of orange!
  • Modding version: PSX

RavenOfRazgriz

I didn't know that about Br.  I figured the fact "permanent" modification was only 1/4th of the actual modding meant that there was both a "CurBr" and a "TrueBr" being stored somewhere.  It sounds like the masters of wasteful coding actually made it work with only one Br/Fa instance for once... the one time we'd have liked them to waste code.  Good to hear you thought of it, though.  I'd honestly thought you'd just not thought of it.

As for Extra 2, I see.  I didn't know it wasn't even trying, I just thought you were breaking the skill cap without realizing it during your tests.  I'm sure you've thought of this before, but have you tried dissecting Defend instead?  It honestly seems like a far better place to draw from than Xifanie's A9 Hack, because using GSF I can give the AI a fully working skillset through it (and Equip Change) in all my tests so far.  Considering that works, hunting there instead of Xifanie's already jerryrigged A9 Hack seems a bit smarter, personally.  Take your time though, I honestly feel fixed previews and a couple other cleanup bits are a tad more important.

Unrelated:  Oranges suck.  Fuck oranges.

Tea

any type of evasion is also not as easy as it sounds?

RavenOfRazgriz

I didn't even think of evasion, myself.

That's also a nice big "Why not?" if you can get it in, though with how evasion works I don't see how you wouldn't be able to.

pokeytax

Quote from: RavenOfRazgriz on June 16, 2011, 02:11:07 pm
though with how evasion works I don't see how you wouldn't be able to.


How does evasion work? I guess I can probably dig through FDC's thread for myself. I was under the impression that it directly accessed your equipment and job, but I don't think that's actually based on any facts. If it reads straight from unit data then yeah that's easy (maybe I could even make Abandon display your stats correctly on the equip screen?).

Now is a good time to bring up ideas so feel free to throw stuff against the wall and see what sticks.
  • Modding version: PSX

RavenOfRazgriz

Well, the Blind hacks by both FDC and FFMaster function via giving the target unit a temporary A-EV boost during battle.  FDC's Abandon Hack works by overwriting C-EV with a new value.  Etc.

I would imagine based on these facts that Squaresoft doesn't do super hoaky things with it and you can easily modify it.  You're best looking at the breakdowns to be safe but from my limited understanding and the precedents set, editing it shouldn't be a problem.

RandMuadDib

Quick question: if I took the patcher and turned all of the "throw" abilities into supports, and used alma to make them useful (half water, str fire, that sort of thing) would that work? Or would the coding in the original abilities make them yuck?
I will show you the power of SARDIIIIINES!!!!

pokeytax

June 18, 2011, 03:40:56 pm #129 Last Edit: June 18, 2011, 03:55:03 pm by pokeytax
Quote from: RandMuadDib on June 18, 2011, 03:07:57 pm
Quick question: if I took the patcher and turned all of the "throw" abilities into supports, and used alma to make them useful (half water, str fire, that sort of thing) would that work? Or would the coding in the original abilities make them yuck?


Not at the moment (can't equip, ALMA doesn't read support slot, just RSM bytes which can only see true supports).

I'm trying to find a good use for Item/Throw/Jump/Charge/Math right now. I've been focusing on using them as passives; but what you're suggesting might be able to piggyback on some of the same code so I'll keep it in mind.

You can use the recategorize hack from the Total Request ASM thread to convert movements to supports or merge the two categories if you just want more supports. Very few movement abilities are worth saving IMO.

(EDIT: booooo code working on stepthrough but not normally again)
  • Modding version: PSX

RavenOfRazgriz

Are you coding in MIPs IV?  If you are, switch to MIPs II.  MIPs IV has a cooldown on some advanced features on the actual PSX and certain emulators / emulator configurations that results in some code failing.  (FDC estimated it being around 60/40 for success/failure, with failure more likely on more complicated routines.)  Your code is probably working like that because the stepthrough is making the cooldown factor irrelevant on an emulator setup that requires cooldown on normal play.

FDC and I were going to make a thread we'd hopefully get stickied basically saying "CODE EVERYTHING IN MIPs II BECAUSE COMPATIBILITY" and explaining the differences between MIPs II and MIPs IV but we kinda ADHD'd on it.  I may make it in a little bit, though I need FDC for the latter part.

If you *are* coding in MIPs II... fuck if I know what your problem is then.

pokeytax

June 18, 2011, 05:38:07 pm #131 Last Edit: June 18, 2011, 05:41:58 pm by pokeytax
After the festival of pain debugging ALMA, I code as ploddingly and clearly as I can. The issue is similar to the one I got when modifying a register used by a branch delay slot but I was careful not to do that (and the native FFT code is doing that) so I dunno. I don't know anything about MIPS II and IV so that could easily be the issue.

The hack in question calls a different recategorize hack so you can keep movement/support separate on the Learn screen but still merge the slots on the Set screen. (I hate the doubling in the Learn screen that much, plus I need somewhere to put passives.)
  • Modding version: PSX

RavenOfRazgriz

June 20, 2011, 03:57:24 pm #132 Last Edit: June 20, 2011, 04:01:31 pm by RavenOfRazgriz
I haven't gotten to talk to FDC yet, but I'll bet your problem is a MIPs II vs. MIPs IV thing.  The main difference from what I remember of the last time he and I talked is that MIPs II just has less advanced features, MIPs IV just adds easier ways of doing the same things.  You may just be using one of the shortcuts added by MIPs IV, which some emulators and a proper PSX can't handle because they're coded for MIPs II.

Also, Celdia's having issues with giving weapons access to the various Equip X commands in CCP via ALMA.  She tried making a sword that has Equip Shield and Equip Armor innate, but she couldn't make use of the effects either in battle or on the equipment menu.  Could you mayhap look into this issue and get that squared away on your road to getting to ALMA 4?

Related:

Quote15:59  Celdia: ALMA is backwards.
15:59  Celdia: It lists MP Restore before HP Restore but they're the other way around I think.

formerdeathcorps

TO be clear, it's not that he's coding in MIPS IV, it's more likely that the emulator reads code as MIPS IV (or MIPS II without considering load delays) and thus allows combinations of opcodes that MIPS II (the real PSX) would not allow.

Quote(EDIT: booooo code working on stepthrough but not normally again)


This could be due to any number of problems.  Pokeytax, can you give a Pastebin link to a decompiler output to your code and/or your notes?  I'll see what I can do from there.
The destruction of the will is the rape of the mind.
The dogmas of every era are nothing but the fantasies of those in power; their dreams are our waking nightmares.

Glain

The MIPS II vs MIPS IV stuff seems a bit out of left field to me. Actually, according to this link, the PSX processor (R3000) is actually MIPS I and not MIPS II.

If we're worried about different versions of the same architecture, then there might be some commands in later versions of MIPS that don't exist on the PSX processor, but we tend to use a pretty specific subset of commands for most things anyhow. I'd be a bit surprised if we suddenly started using commands that don't exist on the processor. For example, if you can use my app (MassHexASM) to encode it, it should be supported by the R3000. I'm actually a bit surprised I haven't gotten any feedback on that app being unable to encode something or other (I'm not sure I got the whole R3000 command set).

The only thing that really comes to mind here that would be relevant with earlier vs. later versions of MIPS would be a load delay slot thing, but that seems too obvious...
  • Modding version: Other/Unknown

RavenOfRazgriz

Quote from: Glain on June 20, 2011, 06:44:49 pmThe only thing that really comes to mind here that would be relevant with earlier vs. later versions of MIPS would be a load delay slot thing, but that seems too obvious...


That's pretty much exactly what we're discussing, unless I've misinterpreted FDC entirely in my conversations with him.

pokeytax

June 20, 2011, 07:23:27 pm #136 Last Edit: June 20, 2011, 07:40:51 pm by pokeytax
That's a very handsome offer, fdc, but I managed to sort things out. I was trying to use one register to determine which screen the player had pulled up, but apparently the one I used did not have a stable value in runtime; I eventually found one that did.

I'll get on those bug reports, thanks! I should note that Equip X abilities on items are probably not useful at the moment anyway (there's no logic preventing equipping Merit Award, equipping armor, removing Merit Award) and I'm planning to overhaul that functionality in ALMA 4. But it sounds like the step where Equip abilities take effect is before ALMA and they aren't working at all, which is good to know.

Glain, I had issues coding mthi/mtlo once, but those are pretty low priority.
  • Modding version: PSX

RavenOfRazgriz

Quote from: pokeytax on June 20, 2011, 07:23:27 pm(there's no logic preventing equipping Merit Award, equipping armor, removing Merit Award) and I'm planning to overhaul that functionality in ALMA 4. But it sounds like the step where Equip abilities take effect is before ALMA and they aren't working at all, which is good to know.


That's what I figured.  I assume you could just hijack the game's existing logic for handling Equip X if you can figure out where to jump but I don't code.  Forcibly calling Best Fit is a good alternative but that seems meh since I know I personally always play with that off and Equip X has secondary logic for when it's off.

RandMuadDib

i didnt even know you could turn best fit off.
I will show you the power of SARDIIIIINES!!!!