Objects Not Freezing Upon Death - RetroKoH/S1Fixed GitHub Wiki
(Original guide by RetroKoH)
Source: Sonic Retro thread
Commit: 2cea14f
This mod can be toggled in S1Fixed by setting ObjectsFreeze to 0 or 1.
So, in every classic Sonic game except for Sonic CD, enemies and objects freeze in place when Sonic dies, but in Sonic CD, they don't! Frankly, I like that they don't. If you do too, let's make that change!
First, open sonic.asm and go to ExecuteObjects. There is a check for Sonic's routine to see if he is in his death state. If he is, then objects are not executed. We can simply remove those lines like so:
ExecuteObjects:
lea (v_objspace).w,a0 ; set address for object RAM
moveq #v_allobjcount,d7
moveq #0,d0
- cmpi.b #6,(v_player+obRoutine).w
- bhs.s loc_D362
But you might find that some objects are still not moving... What gives? The objects are still running their code, right? Right... but these objects move due to their positions being influenced by oscillatory functions, and those also get halted by Sonic's death routine. Let's fix that.
Open _inc/Oscillatory Routines.asm, go to OscillateNumDo, and delete the first two lines:
OscillateNumDo:
- cmpi.b #6,(v_player+obRoutine).w ; has Sonic just died?
- bhs.s .end ; if yes, branch
lea (v_oscillate).w,a1
lea (.settings).l,a2
move.w (a1)+,d3 ; get oscillation direction bitfield
moveq #$F,d1
Done! In my opinion, the lack of sudden freezing looks nicer. Enjoy!