lemm: pressing escape at end of level takes you back to intro

This commit is contained in:
Vince Weaver 2022-04-04 14:43:07 -04:00
parent c01bf713ee
commit eff804db03
1 changed files with 27 additions and 10 deletions

View File

@ -14,18 +14,8 @@ lemm:
;=====================
lda #0
sta DRAW_PAGE
sta JOYSTICK_ENABLED
lda #1
sta WHICH_LEVEL
;====================
; show title message
;====================
jsr show_title
;====================
; detect model
;====================
@ -67,6 +57,27 @@ lemm:
not_a_iigs:
;===========================
; go here if escape pressed
;===========================
restart:
lda #1
sta WHICH_LEVEL
lda #0
sta DRAW_PAGE
;====================
; show title message
;====================
jsr show_title
;===================
; print config
;===================
@ -287,6 +298,12 @@ level_already_resident:
jsr outro_level
cmp #(27+$80) ; escape
bne not_restart
jmp restart
not_restart:
lda LEVEL_OVER
cmp #LEVEL_WIN
beq level_won