Preventing double RTM calls - but still hangs

This commit is contained in:
Pecusx
2022-08-09 23:28:46 +02:00
parent 192b1b01dc
commit e45cc3e609
2 changed files with 8 additions and 2 deletions
+8 -2
View File
@@ -88,6 +88,7 @@
;.zpvar dliX .byte
;.zpvar dliY .byte
.zpvar sfx_effect .byte
.zpvar RMT_VBL_Runin .byte
;--------------
displayposition = modify
@@ -157,6 +158,7 @@ FirstSTART
sta sfx_effect
lda #0
sta RMT_VBL_Runin
jsr RmtSongSelect
VMAIN VBLinterrupt,7 ;jsr SetVBL
@@ -1152,8 +1154,10 @@ itsPAL
; pressTimer is trigger tick counter. always 50 ticks / s
bit:smi:inc pressTimer ; timer halted if >127. max time measured 2.5 s
lda RMT_VBL_Runin
bne SkipRMTVBL
; ------- RMT -------
inc RMT_VBL_Runin
lda sfx_effect
bmi lab2
asl @ ; * 2
@@ -1167,8 +1171,10 @@ itsPAL
sta sfx_effect ;reinit value
lab2
jsr RASTERMUSICTRACKER+3 ;1 play
lda #0
sta RMT_VBL_Runin
; ------- RMT -------
SkipRMTVBL
exitVBL
ply
plx