Wednesday, October 25, 2017

Non-standard Eggheads, part 1

I've unwittingly shown this before, but in each act 2 boss, Eggman's head has four frames of animation: the first two are played in a loop while the boss is idle, whereas the third and fourth frames are shown when it takes damage, and when it's defeated, respectively. Unlike in Sonic 1 and 2, Eggman doesn't giggle when the player takes damage.


Flying Battery Zone's boss has a different set of art, and the way it works is also a bit different. The first frame is shown while the player's position is being tracked, and flips horizontally to show Eggman actively searching for the player. The third and fourth frames work the same as before. Due to an oversight, however, the second frame is never used.


To fix this, go over to the Obj_FBZRobotnikHead object and replace the code at loc_67BFC with this:
loc_67BFC:
    clr.b   $22(a0)
    movea.w $44(a0),a1
    btst    #2,$38(a1)
    beq.s   loc_67C12
    move.b  #1,$22(a0)
Rebuild the ROM, wait for the boss to begin swinging around the platform and...


Hey, it's our old pal from the Data Select screen!


Additionally, you can also go over to the Obj_FBZEndBoss object and replace the code at loc_706C2 with this:
loc_706C2:
    move.w  d0,$14(a0)
    move.b  #4,5(a0)
    move.b  #$84,$38(a0)
    move.w  #$5F,$2E(a0)
    move.l  #loc_707EC,$34(a0)
    rts
This will make the boss also use the missing frame during its initial swing.

4 comments:

  1. Was this the intended use for that frame?

    ReplyDelete
  2. Was the triggering code for the Eggman laughing animations erased as well?
    Or did they just run out of time for creating new frames?
    What about other unused objects, like Eggman flying away towards the horizon?

    ReplyDelete
    Replies
    1. My guess is that they ditched the laughing animation because they were looking to save VRAM space.

      The code for the "fleeing Eggman" object is only present in standalone Sonic 3. I will cover it eventually.

      Delete