Author Topic: Invincible Ultimate Weapon Glitch  (Read 4124 times)

Bosque

  • *
  • Posts: 58
    • View Profile
Invincible Ultimate Weapon Glitch
« on: 2010-07-22 01:12:12 »
http://www.youtube.com/watch?v=9oWYFKC9rq8

Some of you might remember I promised to take a video of a glitch. Here it is.

nfitc1

  • *
  • Posts: 3011
  • I just don't know what went wrong.
    • View Profile
    • WM/PrC Blog
Re: Invincible Ultimate Weapon Glitch
« Reply #1 on: 2010-07-22 02:24:48 »
While typing up a plausible explanation for this behavior, I believe I have an answer as to why he's doing this.

At the beginning of any Ultima Weapon battle his HP are set to whatever the appropriate Global Variables are (the battle AI refers to them as GlobalVars:005B, GlobalVars:005C, and GlobalVars:005D. Those are byte values and his HP is a three-byte value). When you start the first battle, he runs away immediately. This is because he has 0 HP. Only the Ultima Weapon above Cosmo Canyon can be "killed". When you start that battle, he starts out with 0 HP. Therefore, he is unkillable.

"Death" is a rather flaky thing in this game. A battle ends when all targets on either the allies' side or the enemies' side are flagged as dead. Targets only get flagged as dead when their HP change from non-zero to 0. Since his HP are already 0 then he never changed so he's never flagged as dead and the battle continues.

Two questions now appear:

1. But he's supposed to start out with at least 20000 HP. Why doesn't he have that?

Here's my theory (someone feel free to back me up on this). Initiating a battle with Ultima Weapon(s) runs a specific field script that looks at GlobalVar:007B. If that value ANDed with 4 is 4 then the GlobalVars listed above are set appropriately to give him 20000 HP. However, when run from the Debug room, this script isn't active. Therefore, it doesn't reset his HP from 0 and the battle will load his initial HP to 0 and continue ad infinitum.

2. Why is he (trying to) using Ultima Beam every round? He's only supposed to use that once every five rounds.

This....I can't answer.

SUGGESTION:
Try healing him first. THEN striking him. I'm willing to bet that that will kill him.

Bosque

  • *
  • Posts: 58
    • View Profile
Re: Invincible Ultimate Weapon Glitch
« Reply #2 on: 2010-07-22 02:42:11 »
You nailed it! Great job. I never would've thought of that.

Terence Fergusson

  • *
  • Posts: 262
    • View Profile
Re: Invincible Ultimate Weapon Glitch
« Reply #3 on: 2010-07-22 04:19:08 »
Here's my theory (someone feel free to back me up on this). Initiating a battle with Ultima Weapon(s) runs a specific field script that looks at GlobalVar:007B. If that value ANDed with 4 is 4 then the GlobalVars listed above are set appropriately to give him 20000 HP. However, when run from the Debug room, this script isn't active. Therefore, it doesn't reset his HP from 0 and the battle will load his initial HP to 0 and continue ad infinitum.
Not quite.  Check the Enemy AI for the Mideel version of Ultimate Weapon, which is the very first time you're *meant* to fight him.  That's the one that actually sets the Global Variable for Ultimate Weapon's HP correctly.  Later battles with Ultimate Weapon expect the Global Variable to have been set, and so just overwrite the current HP with that value.  So if you skip the Mideel battle, future battles with Ultimate Weapon are going to start him with 0 HP.  Since, as you state, Death requires a change in HP to 0, the Counter:Death script won't run (which is the requirement to set UW to have 20000 HP for the final battle).  Instead, the Counter:General script runs, and that doesn't care how low UW's HP is, so his HP will still be 0 for the final battle.

2. Why is he (trying to) using Ultima Beam every round? He's only supposed to use that once every five rounds.
Um, not in the final battle he isn't.  His AI is simply a 50% chance of Ultima Beam or Thunderball for that battle, with the requisite counter attack of Shadow Flare when he dies.

nfitc1

  • *
  • Posts: 3011
  • I just don't know what went wrong.
    • View Profile
    • WM/PrC Blog
Re: Invincible Ultimate Weapon Glitch
« Reply #4 on: 2010-07-22 12:27:29 »
Not quite.  Check the Enemy AI for the Mideel version of Ultimate Weapon, which is the very first time you're *meant* to fight him.  That's the one that actually sets the Global Variable for Ultimate Weapon's HP correctly.  Later battles with Ultimate Weapon expect the Global Variable to have been set, and so just overwrite the current HP with that value.

Oh, that's where it's set? I was ignoring that because I thought that battle didn't matter in the course of his "roaming phase" HP. I thought his global HP were set later.

Um, not in the final battle he isn't.  His AI is simply a 50% chance of Ultima Beam or Thunderball for that battle, with the requisite counter attack of Shadow Flare when he dies.

I was looking at a modified scene file (which doesn't look well written). D'oh! Yes, this is correct.
I knew of the Shadow Flare. I missed the one Thunderball that he cast as his second turn. Then he ran out of MP too quickly. :)