combine and simplify bademu patchers

This commit is contained in:
4am 2021-06-20 17:36:10 -04:00
parent f1ad04d2dc
commit cee6753852
2 changed files with 15 additions and 54 deletions

View File

@ -7,33 +7,29 @@
; (AppleWin, older versions of MAME)
; so we patch it for compatibility
;
; tested on
; variant 1:
; - Dino Dig (Troll Associates)
; - Make A Face (Troll Associates)
; - Let's Go There: Beginning Map and Geography Skills (Troll Associates)
;
; variant 2:
; - Dinosaur Days (Pelican Software)
;-------------------------------
!zone {
T00_BADEMU
; gTrack = 0
; Caller found DOS 3.3 RWTS
lda #$03
ldx #$4F
ldy #$11
jsr compare ; and T00,S03,$4F ==
!byte $BD,$8C,$C0; LDA $C08C,X
!byte $10,$FB ; BPL -$FB
!byte $C9,$D5 ; CMP #$D5
!byte $D0,$F0 ; BNE -$F0
!byte $EA ; NOP
ldy #$05
jsr SearchTrack
!byte $BD,$8C,$C0; LDA $C08C,X
!byte $C9,$D5 ; CMP #$D5
!byte $F0,$12 ; BEQ +$12
bcs .exit ; passport-test-suite/Beginning Map and Geography Skills.woz [C=0] matches
bcs + ; passport-test-suite/Beginning Map and Geography Skills.woz [C=0] matches
; passport-test-suite/Dinosaur Days.woz [C=0] matches at a different offset
jsr PrintByID
!byte s_d5timing
ldx #$58
ldy #$02
jsr modify ; then set T00,S03,$58 =
!byte $F0,06 ; BEQ +$06
.exit
}
inx
inx
ldy #$01
jsr modify ; then change $C0 to $BF to avoid hitting softswitch
!byte $BF
+

View File

@ -1,35 +0,0 @@
;-------------------------------
; #BADEMU2
; RWTS checks for timing bit by
; checking if data latch is still
; $D5 after waiting "too long"
; but this confuses legacy emulators
; (AppleWin, older versions of MAME)
; so we patch it for compatibility
;
; tested on
; - Dinosaur Days
;-------------------------------
!zone {
; gTrack = 0
; Caller found DOS 3.3 RWTS
lda #$03
ldx #$4F
ldy #$11
jsr compare ; and T00,S03,$4F ==
!byte $BD,$8C,$C0; LDA $C08C,X
!byte $10,$FB ; BPL -$FB
!byte $4A ; LSR
!byte $C9,$6A ; CMP #$6A
!byte $D0,$EF ; BNE -$EF
!byte $BD,$8C,$C0; LDA $C08C,X
!byte $C9,$D5 ; CMP #$D5
!byte $F0,$12 ; BEQ +$12
bcs .exit ; passport-test-suite/Dinosaur Days.woz [C=0] matches
ldx #$59
ldy #$02
jsr modify ; then set T00,S03,$59 =
!byte $F0,$05 ; BEQ +$05
.exit
}