Yoshi's Island Hookbill Koopa

  1. Yoshi's Island Hookbill Koopa 2
  2. Yoshi's Island Hookbill Koopa Castle
  3. Yoshi's Island Hookbill Koopa 4
  4. Yoshi's Island Hookbill Koopa 1

Hookbill is the most technically complex boss in the game. He has a whopping 56 AI states, a skeleton for his body parts, one of which is drawn on a background layer, his body parts each have separate rotational values per animation frame, his graphics are mostly Super FX, and much of his processing is on the Super FX as well, despite even his 65816 code being over a quarter of a bank long. He touches on many, many aspects of the game's coding, lookup tables, etc.

Full disassembly of Yoshi's Island (SNES) version U 1.0 - Raidenthequick/yoshisisland-disassembly. In Super Mario World 2: Yoshi's Island; if a Koopa is jumped on then it will be forced out of its shell. Koopas without shells wear boxing shorts. If it gets back to its shell then it will enter it again. When Yoshi swallows a Koopa, he cannot turn it into an egg and he can only have it in his mouth to spit out. However, if a Koopa has been.

Yoshi's Island Hookbill Koopa 2

Upon Yoshi's final hit onto Hookbill, there is code that governs exactly how much to move Yoshi's Y coordinate by. The basic formula comes down to this:

The main two SRAM addresses here ($0058 and $0056) get computed/stored in Hookbill's Super FX code:

This code is necessary to be run each frame on Hookbill's final hit for proper placement of Yoshi. Blastoff occurs when this code is not run, and this happens because of a check:

That last bcs can branch PAST the above code, therefore NOT running it and NOT properly placing Yoshi's Y coordinate. Because of this, and because address $700058 is written to elsewhere for completely different purposes, most if not all of the time you will get something like these values (taken from an actual trace):

Yoshi's Island Hookbill Koopa Castle

Island

Yoshi's Island Hookbill Koopa 4

Because $700058 was not properly computed (because the code was was branched past), it gets this 'garbage' value of $0001 which it never would normally get. Because of this, our formula to move Yoshi goes like this:

Yoshi's Island Hookbill Koopa 1

This comes out to $FFE9, or -23! Now we are moving 23 pixels BACKWARDS, or in this case up, each frame. Which of course causes Yoshi to blast off to the moon.

So what causes this branch to go past the necessary code? That code simply checks to make sure Yoshi's X coordinate is within range of his shell. In brief, if Yoshi's X moves off the shell, he blasts off. Normally, this wouldn't happen, but it can if you ground pound him early because that would bypass AI states which zero out his X velocity (the process of him landing after falling, etc.), therefore he can retain his X velocity and keep moving left or right, while Yoshi stays stationary. This causes Yoshi to be outside the X bounds of his shell, which causes the check to branch past the necessary code.