BoundaryStuffz
public text v1 · immutableBoundary_Bottom:
move.w ($FFFFF726).w,d0
move.w ($FFFFF72E).w,d1
cmp.w d0,d1 ; screen still scrolling down?
blt.s Boundary_Bottom_locret ; if so, don't kill Sonic
cmpi.w #$501,($FFFFFE10).w ; is level SBZ2 ?
jsr KillSonic ; if not, kill Sonic
cmpi.w #$2000,($FFFFD008).w
jmp KillSonic
clr.b ($FFFFFE30).w ; clear lamppost counter
move.w #1,($FFFFFE02).w ; restart the level
move.w #$103,($FFFFFE10).w ; set level to SBZ3 (LZ4)
rts
Boundary_Bottom_locret:
rts