mirror of
https://github.com/a2-4am/passport.git
synced 2025-04-07 18:38:48 +00:00
refactor print-only checks into rwtslog, add support for DOS 3.3 BNE0
This commit is contained in:
parent
6742c4161c
commit
5304fbdaf0
@ -95,7 +95,7 @@ flag = $FF ; byte
|
||||
}
|
||||
|
||||
; Application constants (not zero addresses)
|
||||
RELBASE = $5B00 ; address to move Passport code
|
||||
RELBASE = $5A00 ; address to move Passport code
|
||||
; so that it's out of the way
|
||||
LOWPOINT = $4300 ; lowest available address for code
|
||||
BASEPAGE = $10 ; Special Delivery tracer assumes
|
||||
@ -670,6 +670,7 @@ _applyToT00
|
||||
!source "patchers/bademu.a"
|
||||
!source "patchers/bademu2.a"
|
||||
!source "patchers/rwts.a"
|
||||
!source "patchers/rwtslog.a"
|
||||
!source "patchers/mecc1.a"
|
||||
!source "patchers/mecc2.a"
|
||||
!source "patchers/mecc3.a"
|
||||
|
@ -622,85 +622,4 @@
|
||||
jsr modify ; then set T00,S02,$AD =
|
||||
!byte $FF
|
||||
.de4w
|
||||
|
||||
;-------------------------------
|
||||
; RWTS "LSR $6A" identification
|
||||
; disk allows either $D4 or $D5 for the
|
||||
; first address prologue nibble
|
||||
; (no patches required, but we want to
|
||||
; log it)
|
||||
;-------------------------------
|
||||
lda gIsRWTS ; if DOS 3.3 RWTS
|
||||
bne .lsr6a
|
||||
lda #$03
|
||||
sta gDisplayBytes
|
||||
ldx #$4F
|
||||
ldy #$0A
|
||||
jsr compare ; and T00,S03,$4F ==
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $10,$FB
|
||||
!byte $4A
|
||||
!byte WILDCARD,$6A
|
||||
!byte $D0,$EF
|
||||
bcs .lsr6a
|
||||
lda #s_lsr6a
|
||||
jsr PrintByID
|
||||
inc gPatchCount
|
||||
.lsr6a
|
||||
|
||||
;-------------------------------
|
||||
; RWTS "CMP #$08 / BCS" identification
|
||||
; disk allows either $DE or a timing bit
|
||||
; for the first address epilogue nibble
|
||||
; (no patches required, but we want to
|
||||
; log it)
|
||||
;-------------------------------
|
||||
lda gIsRWTS ; if DOS 3.3 RWTS
|
||||
bne .bcs08
|
||||
lda #$03
|
||||
sta gDisplayBytes
|
||||
ldx #$8B
|
||||
ldy #$15
|
||||
jsr compare ; and T00,S03,$8B ==
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $10,$FB
|
||||
!byte $C9,$DE
|
||||
!byte $F0,$0A
|
||||
!byte $48
|
||||
!byte $68
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $C9,$08
|
||||
!byte $B0,$A5
|
||||
!byte $EA
|
||||
!byte $18
|
||||
!byte $60
|
||||
bcs .bcs08
|
||||
lda #s_bcs08
|
||||
jsr PrintByID
|
||||
inc gPatchCount
|
||||
.bcs08
|
||||
|
||||
;-------------------------------
|
||||
; RWTS "CMP / BNE 0" identification
|
||||
; disk allows any value for
|
||||
; for the first address epilogue nibble
|
||||
; (no patches required, but we want to
|
||||
; log it)
|
||||
;-------------------------------
|
||||
lda gIsDavidDOS
|
||||
bne +
|
||||
lda #$05
|
||||
sta gDisplayBytes
|
||||
ldx #$8B
|
||||
ldy #$09
|
||||
jsr compare ; and T00,S05,$8B ==
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $10,$FB
|
||||
!byte $C9,WILDCARD
|
||||
!byte $D0,$00
|
||||
bcs +
|
||||
lda #s_cmpbne0
|
||||
jsr PrintByID
|
||||
inc gPatchCount
|
||||
+
|
||||
}
|
||||
|
105
src/patchers/rwtslog.a
Normal file
105
src/patchers/rwtslog.a
Normal file
@ -0,0 +1,105 @@
|
||||
;-------------------------------
|
||||
; #RWTSLOG
|
||||
; Print log messages for RWTS variants
|
||||
; that indicate structural copy protection
|
||||
; but don't require any patches
|
||||
;-------------------------------
|
||||
|
||||
!zone {
|
||||
;-------------------------------
|
||||
; RWTS "LSR $6A" identification
|
||||
; disk allows either $D4 or $D5 for the
|
||||
; first address prologue nibble
|
||||
;-------------------------------
|
||||
lda gIsRWTS ; if DOS 3.3 RWTS
|
||||
bne +
|
||||
lda #$03
|
||||
sta gDisplayBytes
|
||||
ldx #$4F
|
||||
ldy #$0A
|
||||
jsr compare ; and T00,S03,$4F ==
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $10,$FB
|
||||
!byte $4A
|
||||
!byte WILDCARD,$6A
|
||||
!byte $D0,$EF
|
||||
bcs +
|
||||
lda #s_lsr6a
|
||||
jsr PrintByID
|
||||
inc gPatchCount
|
||||
+
|
||||
|
||||
;-------------------------------
|
||||
; RWTS "CMP #$08 / BCS" identification
|
||||
; disk allows either $DE or a timing bit
|
||||
; for the first address epilogue nibble
|
||||
;-------------------------------
|
||||
lda gIsRWTS ; if DOS 3.3 RWTS
|
||||
bne +
|
||||
lda #$03
|
||||
sta gDisplayBytes
|
||||
ldx #$8B
|
||||
ldy #$15
|
||||
jsr compare ; and T00,S03,$8B ==
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $10,$FB
|
||||
!byte $C9,$DE
|
||||
!byte $F0,$0A
|
||||
!byte $48
|
||||
!byte $68
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $C9,$08
|
||||
!byte $B0,$A5
|
||||
!byte $EA
|
||||
!byte $18
|
||||
!byte $60
|
||||
bcs +
|
||||
lda #s_bcs08
|
||||
jsr PrintByID
|
||||
inc gPatchCount
|
||||
+
|
||||
|
||||
;-------------------------------
|
||||
; RWTS "CMP / BNE 0" identification
|
||||
; disk allows any value for
|
||||
; for the first address epilogue nibble
|
||||
;-------------------------------
|
||||
lda gIsRWTS ; if DOS 3.3 RWTS
|
||||
bne +
|
||||
lda #$03
|
||||
sta gDisplayBytes
|
||||
ldx #$8B
|
||||
ldy #$09
|
||||
jsr compare ; and T00,S03,$8B ==
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $10,$FB
|
||||
!byte $C9,WILDCARD
|
||||
!byte $D0,$00
|
||||
bcs +
|
||||
lda #s_cmpbne0
|
||||
jsr PrintByID
|
||||
inc gPatchCount
|
||||
+
|
||||
|
||||
;-------------------------------
|
||||
; RWTS "CMP / BNE 0" identification (David-DOS variant)
|
||||
; disk allows any value for
|
||||
; for the first address epilogue nibble
|
||||
;-------------------------------
|
||||
lda gIsDavidDOS ; if David-DOS bootloader
|
||||
bne +
|
||||
lda #$05
|
||||
sta gDisplayBytes
|
||||
ldx #$8B
|
||||
ldy #$09
|
||||
jsr compare ; and T00,S05,$8B ==
|
||||
!byte $BD,$8C,$C0
|
||||
!byte $10,$FB
|
||||
!byte $C9,WILDCARD
|
||||
!byte $D0,$00
|
||||
bcs +
|
||||
lda #s_cmpbne0
|
||||
jsr PrintByID
|
||||
inc gPatchCount
|
||||
+
|
||||
}
|
@ -222,7 +222,7 @@ StringTable
|
||||
; can be set directly before calling PrintByID.
|
||||
;
|
||||
.header
|
||||
!text "Passport by 4am 2017-08-07",$00
|
||||
!text "Passport by 4am 2017-08-08",$00
|
||||
.mainmenu
|
||||
!text "________________________________________",$8D,$8D,$8D,$8D,$8D,$8D,$8D
|
||||
!text " "
|
||||
|
Loading…
x
Reference in New Issue
Block a user