Difference between revisions of "Fix DEZ Eggrobo boss collision glitch"
From Sonic Retro
m |
Scarred Sun (talk | contribs) m (Text replacement - "</asm>" to "</syntaxhighlight>") |
||
Line 24: | Line 24: | ||
move.w #SndID_BossHit,d0 | move.w #SndID_BossHit,d0 | ||
jsr (PlaySound).l | jsr (PlaySound).l | ||
− | </ | + | </syntaxhighlight> |
Line 36: | Line 36: | ||
move.w #SndID_BossHit,d0 | move.w #SndID_BossHit,d0 | ||
jsr (PlaySound).l | jsr (PlaySound).l | ||
− | </ | + | </syntaxhighlight> |
{{S2Howtos}} | {{S2Howtos}} | ||
[[Category:SCHG How-tos|{{PAGENAME}}]] | [[Category:SCHG How-tos|{{PAGENAME}}]] |
Revision as of 21:30, 20 December 2015
(Original guide by Flamewing)
In Death Egg Zone, the final boss you fight is the infamous Giant Mech. While cited for its difficulty, it is also known for a particularly annoying bug that makes the boss fight that much more difficult. When hitting the boss in a certain manner, (this is better described by flamewing) it can cause you to fall into the robot, being killed by its arms, instead of rebounding much in the manner that you would when fighting any other boss. In the Sonic 2 Heroes forum topic, flamewing discusses how exactly to fix it, and it is far simpler than many people believed.
Open up s2.asm and find label 'loc_3DFF8'; this function is responsible for checking if:
1. If Eggrobo has been defeated: causes him to break up if so;
2. Otherwise:
1. If Eggrobo is flashing from a previous hit: keep flashing until timer runs out;
2. Otherwise:
1. If Eggrobo was hit on the body: play hit sound, start flashing;
2. Otherwise, if Eggrobo was hit on the head, then subtract 1 hit from hit counter, remove collision from body and proceed as previous item.
If you paid attention, you will have noticed that hitting Eggrobo in the head removes collision from the body, but that hitting him on the body does not remove collision from the head; we will fix this now. The easiest fix is to go to this piece of code:
<asm> loc_3E01E:
move.b #$3C,objoff_2A(a0) move.w #SndID_BossHit,d0 jsr (PlaySound).l
</syntaxhighlight>
and change it to this:
<asm> loc_3E01E:
movea.w objoff_36(a0),a1 ; a1=Eggrobo's head clr.b collision_flags(a1) ; Remove collision from head move.b #$3C,objoff_2A(a0) move.w #SndID_BossHit,d0 jsr (PlaySound).l
</syntaxhighlight>