Better GetKey but.....

This commit is contained in:
Pecusx
2023-10-26 15:45:37 +02:00
parent 803dfdf9a3
commit 1791ab9869
4 changed files with 15 additions and 5 deletions
+2
View File
@@ -401,7 +401,9 @@ ManualShooting
jsr WaitForKeyRelease
lda #%00000000
sta TestFlightFlag ; set "Test Fight" off
mva #$ff FastKeyRead
jsr BeforeFire
mva #$00 FastKeyRead
bit escFlag
spl:rts ; keys Esc or O
+9 -3
View File
@@ -54,8 +54,9 @@ AdditionalZPvariables = $20
.zpvar MeteorsRound .byte ; set 7th bit - block meteors in round
FirstZpageVariable = $50
FirstZpageVariable = $4f
.zpvar DliColorBack .byte = FirstZpageVariable
.zpvar FastKeyRead .byte ; 0 - GetKey wait for any key (and generates SFX), $ff - fast GetKey
.zpvar ClearSky .byte ; $ff - Crear sky during drawmountains, 0 - no clear sky
.zpvar PaddleState .byte ; old state 2nd button for 2 buttons joysticks
.zpvar GradientNr .byte
@@ -470,7 +471,10 @@ checkSelectKey
lda CONSOL
and #%00000100 ; Option
.ENDIF
bne getKeyAfterWait
bit FastKeyRead
bpl getKeyAfterWait
lda #@kbcode._none
bne getkeyend
OptionPressed
lda #@kbcode._atari ; Option key
bne getkeyend
@@ -483,8 +487,10 @@ JoyButton
getkeyend
ldy #0
sty ATRACT ; reset atract mode
bit FastKeyRead
bmi @+
mvy #sfx_keyclick sfx_effect
rts
@ rts
.IF TARGET = 800 ; Second joy button only on A800
Check2button
lda PADDL0
BIN
View File
Binary file not shown.
+4 -2
View File
@@ -1270,12 +1270,12 @@ NoSpyHard
mva #0 escFlag
jmp ReleaseAndLoop
@
cmp #$80|@kbcode._up
/* cmp #$80|@kbcode._up
jeq CTRLPressedUp
cmp #$80|@kbcode._down
jeq CTRLPressedDown
cmp #$80|@kbcode._tab
jeq CTRLPressedTAB
jeq CTRLPressedTAB */
jumpFromStick
.IF TARGET = 800
@@ -1321,6 +1321,7 @@ NoVdebugSwitch
jmp ReleaseAndLoop
.ENDIF
EndKeys
mva #$80 pressTimer
jmp notpressed
;
@@ -1515,6 +1516,7 @@ pressedS
eor:sta noSfx
ReleaseAndLoop
jsr WaitForKeyRelease
mva #$80 pressTimer
jmp BeforeFire
pressedSpace