cover fade on esc

This commit is contained in:
4am 2019-06-21 13:17:57 -04:00
parent ca18b488ea
commit 8979c6307f
2 changed files with 12 additions and 8 deletions

View File

@ -35,9 +35,7 @@ TMP = $FC ; 4 bytes
lda #74 lda #74
sta COUNTER sta COUNTER
- lda $C000 - ldx COUNTER
bmi @done
ldx COUNTER
ldy Order,x ldy Order,x
lda TransformHi,y lda TransformHi,y
sta @j+2 sta @j+2
@ -45,10 +43,16 @@ TMP = $FC ; 4 bytes
sta @j+1 sta @j+1
@j jsr $FDFD ; SMC @j jsr $FDFD ; SMC
lda #80 lda #80
jsr WaitForKeyWithTimeout sec
@wait1 pha
@wait2 sbc #1
bne @wait2
pla
sbc #1
bne @wait1
dec COUNTER dec COUNTER
bpl - bpl -
@done rts rts
InitPRNG InitPRNG
lda $4E lda $4E

View File

@ -48,10 +48,10 @@ _SearchModeInputLoop
bne - ; on every keypress (whether or not bne - ; on every keypress (whether or not
dec $52 ; the key leads to an action) dec $52 ; the key leads to an action)
bne - bne -
jsr _CoverFade
lda #kAttractMode ; no input for ~30 seconds lda #kAttractMode ; no input for ~30 seconds
sta Mode ; switch to attract mode sta Mode ; switch to attract mode
rts jmp _CoverFade
@gotKey @gotKey
jsr _ResetInputTimeout jsr _ResetInputTimeout
@ -115,7 +115,7 @@ InputDispatch
OnClear OnClear
ldx InputLength ldx InputLength
bne + bne +
jsr BlankHGR jsr _CoverFade
pla ; Esc with no input exits search mode pla ; Esc with no input exits search mode
pla ; and switches to attract mode pla ; and switches to attract mode
rts rts