Author Topic: FF2 Battle Script That's Different Than FF4  (Read 9690 times)

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #15 on: June 03, 2008, 01:33:15 PM »
Edit: I don't think my interpretation of "F2" in the attack sequences is correct. It displays the dialogue, but doesn't do it while performing the next attack. Not sure what the difference is between "F1" and "F2". If anyone knows or figures it out, please share.

Post an example of those in action, then maybe I can figure something out.
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #16 on: June 03, 2008, 02:54:48 PM »
Odin's lightning-death trigger seems to occur after you take two "Odin" attacks up the ass first. That section of code won't ever execute... though I think you can kinda trigger that out of order at random, but I could be wrong.
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #17 on: June 03, 2008, 03:53:20 PM »
If I hadn't mentioned this before.. but the battle engine suffers a from a bug when changing elemental weaknesses during the elemental battle. When changing from lightning to holy weakness (Kainazzo/Cagnazzo to Valvalis/Barbariccia), lightning weakness is retained for whatever the reason.
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Dragonsbrethren

  • Forum Overlord
  • *
  • Posts: 1,820
    • View Profile
    • Dragonsbrethren Industries
Re: FF2 Battle Script That's Different Than FF4
« Reply #18 on: June 03, 2008, 03:54:36 PM »
Does that apply to all elements or just those two? If it applies to all, that might explain why lightning works so good on Cagnazzo regardless of his form.

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #19 on: June 03, 2008, 03:58:42 PM »
Does that apply to all elements or just those two? If it applies to all, that might explain why lightning works so good on Cagnazzo regardless of his form.

Just those two.. someone needs to dig into the code to see why that occurs. It's a nice bug/bonus since you are queuing Rydia or FuSoYa to cast that spell.

The original Cagnazzo battle isn't affected by this bug.
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Phoenix

  • FF4 Hacker
  • *
  • Posts: 456
    • View Profile
    • Phoenix Hacks
Re: FF2 Battle Script That's Different Than FF4
« Reply #20 on: June 03, 2008, 09:29:59 PM »
I finally got around to looking at Odin's script. His attack sequence per turn is:

1. Attack
2. Attack
3. Attack
4. Change graphic
5. Do nothing
6. Use enemy spell "Odin"
7. Attack
8. Attack
9. Change grahic
10. Do nothing
11. Use enemy spell "Odin"
12. Attack
13. Chain: Change graphic, set condition flag to 01
14. Set condition flag to 00 and use enemy spell "Odin"
[repeat from beginning]

His reflex sequence is: if condition flag is 01 and hit by lightning-elemental spell, display message 0x68 ("Thunder struck Odin!") and cast Vanish (instant kill) on self.

So, his script really is funky. You can only hit him with lightning to end the battle on every third time he raises his sword. And, for that one time, there's no pause in between the graphic change and the attack. You have to have pretty good timing (although you should be able to use any lighting spell, even Lit1, which would cast quickly). The weirdness of the script seems like a mistake to me, but perhaps that's how the programmers meant to write it. Anyway, mystery solved.

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #21 on: June 03, 2008, 09:35:45 PM »
Yes, I've seen it and finally understood it after your explanation of the flag system (read earlier posts).

That's a friggen rarely seen message, given that it would be extremely difficult to survive...
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Dragonsbrethren

  • Forum Overlord
  • *
  • Posts: 1,820
    • View Profile
    • Dragonsbrethren Industries
Re: FF2 Battle Script That's Different Than FF4
« Reply #22 on: June 03, 2008, 09:43:55 PM »
Yeah, it would make sense if it worked every time he raised his sword, but having to survive two Zantetsukens in a row? I doubt that's possible at any reasonable level you'd fight Odin at.

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #23 on: June 03, 2008, 09:46:20 PM »
Well, assuming you aren't already damage efficent, you could try using Kain and time his Jump to avoid the attack. One of the others would be revived and take the fall for the damage. Rydia is probably the best candidate for this since she has to deal the lightning attack (you could just make Kain use an item instead).
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Phoenix

  • FF4 Hacker
  • *
  • Posts: 456
    • View Profile
    • Phoenix Hacks
Re: FF2 Battle Script That's Different Than FF4
« Reply #24 on: June 03, 2008, 11:07:28 PM »
Quote from: Phoenix
Edit: I don't think my interpretation of "F2" in the attack sequences is correct. It displays the dialogue, but doesn't do it while performing the next attack. Not sure what the difference is between "F1" and "F2". If anyone knows or figures it out, please share.
Quote from: Deathlike2
Post an example of those in action, then maybe I can figure something out.

Besides the Dark Elf example I posted, Yang's script and the Officer's script (where he says "Attack!") use F2. The Mist Dragon and Kainazzo's scripts use F1.

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #25 on: June 03, 2008, 11:13:00 PM »
Maybe it's just me.. but I don't quite see it.. perhaps laying out parts of the battle script and highlighting its use may be more helpful.

I think F2 is used for offensive attacks, while F1 is used by defensive counters.
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #26 on: June 04, 2008, 12:03:26 AM »
Hmm.. some of the battles need some audio changing/spicing up..
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Phoenix

  • FF4 Hacker
  • *
  • Posts: 456
    • View Profile
    • Phoenix Hacks
Re: FF2 Battle Script That's Different Than FF4
« Reply #27 on: June 04, 2008, 01:06:12 AM »
Quote
Maybe it's just me.. but I don't quite see it.. perhaps laying out parts of the battle script and highlighting its use may be more helpful.

Yeah, I can't quite figure it out either.

Quote
I think F2 is used for offensive attacks, while F1 is used by defensive counters.

This could be. I'll check out the patterns when I have the time.

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #28 on: June 04, 2008, 01:10:24 AM »
Quote
I think F2 is used for offensive attacks, while F1 is used by defensive counters.

This could be. I'll check out the patterns when I have the time.

Well, here's why I say that.

The Mist Dragon uses it as a counter to any attack in its invincible mist form.

I'm not sure when it is used in Kainazzo, but it has a reaction to Lightning to revert to its original form... and it also has an HP dependant form.

Yang uses it as part of his battle script...

The Officer uses it as part of his battle script...

The Dark Elf uses it in its battle script sequence...

That's a fair conclusion I'm drawing here, hence my response.
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3

Deathlike2

  • Moderator
  • *
  • Posts: 3,538
  • I'm looking at you, bitch!
    • View Profile
Re: FF2 Battle Script That's Different Than FF4
« Reply #29 on: January 19, 2009, 11:26:11 AM »
 :bump:

This is worth a bump since I'm totally lost.

The attack sequences I get.. they are linked to a condition index (if charmed, execute script bleh) and whatnot.

I don't quite get the enemy condition index.. the list is understandable, but the stuff before that doesn't quite make sense to me.

Quote
Enemy Condition Indices (76900-76AFF)

[first byte of attack group sets]


00xxyyzz = if xx's status byte yy is status zz
01xx00yy = if xx's HP is less than [index yy of HP table at 76200]
020000xx = if condition flag is xx
020001xx = if reflex flag is xx
03xx0100 = if character xx is dead
040001xx = if enemy xx is dead
050000xx = if current enemy set is Overworld xx
050001xx = if current enemy set is Underground/Moon xx
06000000 = if only enemy type alive
07xxyyzz = if xx does command yy with element zz (00 = any)
08xxyyzz = ?? duplicated 07?
09000000 = ??
0A000000 = if HP damage
0B000000 = if only enemy alive
   Note: for character/enemy xx, values above 16 are xx-1

I kinda get that, but then again, I really don't. There seems to be something I'm totally missing.
Working on the next Yet To Be Named FF4 "Hardtype" Hack Download Latest: v1.48

Video Demos: #1 #2 #3