passport/src/patchers/t00_jmpbeca.a
2021-07-11 01:03:32 -04:00

50 lines
1.3 KiB
Plaintext
Executable File

;-------------------------------
; #JMPBECA
; RWTS calls $3ECA or $BECA after reading
; data prologue to burn cycles
;
; NOTE: must be run before RWTS patchers due to overlapping bytes
;
; see jmpbeb1.a for compatibility list
;-------------------------------
!zone {
; gTrack = 0
; Caller found DOS 3.3 RWTS
lda #$02
ldx #$F4
ldy #$0D
jsr compare ; and T00,S02,$F4 ==
!byte $EA
!byte $BD,$8C,$C0
!byte $10,$FB
!byte $C9,$AD
!byte $D0,$E8
!byte $4C,$CA,WILDCARD
bcc .yes ; passport-test-suite/Easy as ABC.woz [C=0] matches
;
; variant seen in Library Magic
;
jsr compare ; or T00,S02,$F4 ==
!byte $4C,$CA,WILDCARD
!byte $EA
!byte $BD,$8C,$C0
!byte $10,$FB
!byte $49
!byte $AD,$D0,$DD
bcs .exit ; passport-test-suite/Library Magic.woz [C=0] matches
.yes
sta gDisplayBytes ; passport-test-suite/Spelling Rules.woz [C=0] also reaches here
jsr PrintByID
!byte s_jmpbeca
jsr modify ; then set T00,S02,$F4 =
!byte $A0,$56
!byte $BD,$8C,$C0
!byte $10,$FB
!byte $C9,$AD
!byte $D0,$E7
!byte $A9,$00
.exit
}