Actions

SCHG How-to

Difference between revisions of "Correct CPZ boss attack behavior"

From Sonic Retro

m (BONUS: added a link to guide)
m (Header edit)
Line 1: Line 1:
''Guide by [[redhotsonic]]''
+
''(Guide by [[redhotsonic]] using the 2007 Xenowhirl disassembly)''
  
 
As many of you are aware, during the CPZ boss, when Eggman drops the blue slime on you, ducking will protect you, and the chemical cannot hurt you, making it too easy to defend against Eggman's attacks. To fix this so you will get hurt whilst ducking, follow this.
 
As many of you are aware, during the CPZ boss, when Eggman drops the blue slime on you, ducking will protect you, and the chemical cannot hurt you, making it too easy to defend against Eggman's attacks. To fix this so you will get hurt whilst ducking, follow this.

Revision as of 02:02, 19 June 2012

(Guide by redhotsonic using the 2007 Xenowhirl disassembly)

As many of you are aware, during the CPZ boss, when Eggman drops the blue slime on you, ducking will protect you, and the chemical cannot hurt you, making it too easy to defend against Eggman's attacks. To fix this so you will get hurt whilst ducking, follow this.

The Fix

Go to "loc_2E692:" and you'll see this: <asm> loc_2E692:

       addq.b  #2,routine_secondary(a0)
       move.b  #$20,y_radius(a0)
       move.b  #$19,anim(a0)
       move.w  #0,y_vel(a0)
       movea.l objoff_34(a0),a1 ; a1=object
       movea.l $34(a1),a1
       btst    #2,$2D(a1)
       beq.s   loc_2E6CA
       bclr    #2,$2D(a1)
       move.b  #6,routine_secondary(a0)
       move.w  #9,objoff_2A(a0)

</asm>

See that command? <asm>

       move.b  #$20,y_radius(a0)

</asm>

Change #$20 to #$16. So you have this in the end: <asm> loc_2E692:

       addq.b  #2,routine_secondary(a0)
       move.b  #$16,y_radius(a0)
       move.b  #$19,anim(a0)
       move.w  #0,y_vel(a0)
       movea.l objoff_34(a0),a1 ; a1=object
       movea.l $34(a1),a1
       btst    #2,$2D(a1)
       beq.s   loc_2E6CA
       bclr    #2,$2D(a1)
       move.b  #6,routine_secondary(a0)
       move.w  #9,objoff_2A(a0)

</asm>

DONE!

Explanation

The slime's y_radius is $20. This is fine normally. But when Sonic "ducks", Sonic's y_radius is "shortened". So, now, when the gunk is falling and hits the ground, it actually doesn't touch Sonic.

Because we have "lowered" the gunk's y_radius, its distance from the floor has grown just a little bit. Because of this, the chemical now falls down, just a little bit more, and because of this, it will now hit Sonic when he's "ducking", and it will still hurt Sonic in any other position as well.

BONUS

THIS IS JUST FOR LAUGHS, but try it anyway! Back at the label "loc_2E692:". See these two lines? <asm>

       btst    #2,$2D(a1)
       beq.s   loc_2E6CA

</asm> Comment them out! And see what happens for yourself! (SPOILER ALERT: Or, don't be a fun person, and check the OP to see the picture instead... [1] I hate you.)

FOR MORE FUN, CHECK OUT THIS GUIDE!

SCHG How-To Guide: Sonic the Hedgehog 2 (16-bit)
Fixing Bugs
Fix Demo Playback | Fix a Race Condition with Pattern Load Cues | Fix Super Sonic Bugs | Use Correct Height When Roll Jumping | Fix Jump Height Bug When Exiting Water | Fix Screen Boundary Spin Dash Bug | Correct Drowning Bugs | Fix Camera Y Position for Tails | Fix Tails Subanimation Error | Fix Tails' Respawn Speeds | Fix Accidental Deletion of Scattered Rings | Fix Ring Timers | Fix Rexon Crash | Fix Monitor Collision Bug | Fix EHZ Deformation Bug | Correct CPZ Boss Attack Behavior | Fix Bug in ARZ Boss Arrow's Platform Behavior | Fix ARZ Boss Walking on Air Glitch | Fix ARZ Boss Sprite Behavior | Fix Multiple CNZ Boss Bugs | Fix HTZ Background Scrolling Mountains | Fix OOZ Launcher Speed Up Glitch | Fix DEZ Giant Mech Collision Glitch | Fix Boss Deconstruction Behavior | Fix Speed Bugs | Fix 14 Continues Cheat | Fix Debug Mode Crash | Fix 99+ Lives | Fix Sonic 2's Sega Screen
Design Choices
Remove the Air Speed Cap | Disable Floor Collision While Dying | Modify Super Sonic Transformation Methods & Behavior | Enable/Disable Tails in Certain Levels | Collide with Water After Being Hurt | Retain Rings When Returning at a Star Post | Improve the Fade In\Fade Out Progression Routines | Fix Scattered Rings' Underwater Physics | Insert LZ Water Ripple Effect | Restore Lost CPZ Boss Feature | Prevent SCZ Tornado Spin Dash Death | Improve ObjectMove Subroutines | Port S3K Rings Manager | Port S3K Object Manager | Port S3K Priority Manager | Edit Level Order with ASM‎ | Alter Ring Requirements in Special Stages | Make Special Stage Characters Use Normal DPLCs | Speed Up Ring Loss Process | Change spike behaviour in Sonic 2
Adding Features
Create Insta-kill and High Jump Monitors | Create Clone and Special Stage Monitors | Port Knuckles
Sound Features
Expand Music Index to Start at $00 | Port Sonic 1 Sound Driver | Port Sonic 2 Clone Driver | Port Sonic 3 Sound Driver | Port Flamewing's Sonic 3 & Knuckles Sound Driver | Expand the Music Index to Start at $00 (Sonic 2 Clone Driver Version) | Play Different Songs Per Act
Extending the Game
Extend the Level Index Past $10 | Extend the Level Select | Extend Water Tables | Add Extra Characters | Free Up 2 Universal SSTs