Fix Alternate Display Mode on ROM0 and ROM1 //gs (#530)

fixes attract hanging on ROM0 and ROM1 machines
This commit is contained in:
frankmilliron 2022-11-27 08:46:44 -08:00 committed by GitHub
parent 1b49c67062
commit 327d37bedd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -371,14 +371,19 @@
sec sec
jsr $FE1F ; check for IIgs jsr $FE1F ; check for IIgs
bcs ++ bcs ++
lda #$20 ; check if Alternate Display Mode is already on tya ; GS ID routine returns with ROM version in Y
sta $0800 cmp #0 ; ROM 0?
beq ++
cmp #1 ; ROM 1?
beq ++
lda #$20
sta $0800 ; check if Alternate Display Mode is already on
lda #$FF lda #$FF
jsr ROM_WAIT jsr ROM_WAIT ; skip a VBL cycle
!cpu 65816 !cpu 65816
lda $E00800 ; did we shadow copy data to shadow bank $E0? lda $E00800 ; did we shadow copy data to bank $E0?
cmp #$20 cmp #$20
beq + beq + ; only call TEXT2COPY if we know it's off
!cpu 6502 ; https://archive.org/details/develop-04_9010_October_1990/page/n51/mode/1up !cpu 6502 ; https://archive.org/details/develop-04_9010_October_1990/page/n51/mode/1up
jsr ROM_TEXT2COPY ; set alternate display mode on IIgs (required for some games) jsr ROM_TEXT2COPY ; set alternate display mode on IIgs (required for some games)
+ cli ; enable VBL interrupts + cli ; enable VBL interrupts