add support for JMP2012 protection (variant of JMPB412)

This commit is contained in:
4am 2019-07-25 12:51:24 -04:00
parent f1ccddc268
commit f0d36517ca
4 changed files with 42 additions and 2 deletions

View File

@ -779,6 +779,7 @@ _applyToAll
!source "patchers/optimum.a" ; gIsOptimum only
!source "patchers/bootcounter.a" ; T01 only
!source "patchers/jmpb412.a" ; T02 only
!source "patchers/jmp2012.a" ; T02 only
!source "patchers/jmpb400.a" ; T02 && gIsBoot0 only
!source "patchers/advint.a" ; gAdventureInternational only
!source "patchers/jsr8635.a" ; gIsRWTS only

38
src/patchers/jmp2012.a Normal file
View File

@ -0,0 +1,38 @@
;-------------------------------
; #JMP2012
; Boot1 jumps to $B3C3 to read
; and decrypt a nibble check at
; $2012, which exits via $9D84
; if successful
; seems to be a variant of JMPB412
; with tighter code
;
; tested on
; - BrainBank's Be Better Series - The Start Disk
;-------------------------------
!zone {
bit gMode ; nothing to do here in verify-only mode
bpl .exit
lda gTrack
cmp #$02
bne .exit
lda #$00
ldx #$E5
ldy #$06
jsr compare ; if T02,S00,$E8 ==
!byte $99,$12,$20; STA $2012,Y
!byte $C8 ; INY
!byte $D0,$F5 ; BNE -
bcs .exit ; passport-test-suite/Better Be.woz [C=0] matches
lda #$20
sta gDisplayBytes
lda #s_jmpb412
jsr PrintByID
lda #$00
ldx #$EC
ldy #$02
jsr modify ; then set T02,S00,$EC =
!byte $84,$9D
.exit
}

View File

@ -25,6 +25,7 @@
!byte $C8 ; INY
!byte $C0,$FF ; CPY #$FF
bcs .exit ; passport-test-suite/America Coast to Coast.woz [C=0] matches
lda #$B4
sta gDisplayBytes
lda #s_jmpb412
jsr PrintByID

View File

@ -280,7 +280,7 @@ StringTableHigh
; can be set directly before calling PrintByID.
;
.header
!text "Passport by 4am 2019-06-16",$00
!text "Passport by 4am 2019-07-25",$00
.mainmenu
!text "________________________________________",$8D,$8D,$8D,$8D,$8D,$8D,$8D,$8D
!text " "
@ -530,7 +530,7 @@ StringTableHigh
!text "T00,S00 Found Pronto-DOS bootloader",$8D,$00
.jmpb412
!text "T02,S00 Disk calls a protection check",$8D
!text "at $B412 before initializing DOS.",$8D,$00
!text "at $%012 before initializing DOS.",$8D,$00
.laureate
!text "T00,S00 Found Laureate bootloader",$8D,$00
.bbf9