mirror of
https://github.com/a2-4am/4cade.git
synced 2024-12-28 03:29:59 +00:00
ensure reload of search index after exiting mini attract mode
fixes https://github.com/a2-4am/4cade/issues/430
This commit is contained in:
parent
ff3b536e1c
commit
535b5b39ce
@ -65,7 +65,7 @@ MegaAttractMode
|
||||
; in: gGameToLaunch = index in gSearchStore (word)
|
||||
; gSearchStore populated
|
||||
; out: all flags and registers clobbered
|
||||
; assume all of main memory has been clobbered
|
||||
; assume all of main memory has been clobbered (including gSearchStore)
|
||||
;------------------------------------------------------------------------------
|
||||
MiniAttractMode
|
||||
jsr GetGameToLaunch
|
||||
|
@ -96,6 +96,9 @@ OnBrowseCheat
|
||||
|
||||
OnBrowseTab
|
||||
jsr MiniAttractMode
|
||||
pha ; must reload search index before calling either
|
||||
jsr ReloadSearchIndex ; PlayGame or LoadGameTitleOffscreen, because
|
||||
pla ; mini attract mode may have clobbered all of main memory
|
||||
cmp #$8D
|
||||
beq OnBrowseLaunch
|
||||
; execution falls through here
|
||||
@ -104,6 +107,7 @@ ForceBrowseChanged
|
||||
; execution falls through here
|
||||
OnBrowseChanged
|
||||
; in: gGameToLaunch = game index (word)
|
||||
; gSearchStore populated
|
||||
jsr SwitchToBank2
|
||||
jsr EnableAcceleratorAndSwitchToBank1
|
||||
jsr LoadGameTitleOffscreen
|
||||
|
@ -162,7 +162,8 @@ OnTab
|
||||
jsr MiniAttractMode
|
||||
cmp #$8D ; if we exited mini attract mode
|
||||
bne .req_redraw ; by pressing Enter, launch the game
|
||||
|
||||
jsr ReloadSearchIndex ; must reload search index before calling PlayGame
|
||||
; /!\ execution falls through here
|
||||
OnLaunch
|
||||
ldx gGameToLaunch+1
|
||||
inx
|
||||
@ -170,7 +171,7 @@ OnLaunch
|
||||
jsr PlayGame
|
||||
|
||||
.req_redraw
|
||||
sec ; tell caller to redraw UI
|
||||
sec ; tell caller to reload search index and redraw UI from scratch
|
||||
rts
|
||||
|
||||
OnCheat
|
||||
|
Loading…
Reference in New Issue
Block a user