mirror of
https://github.com/a2-4am/passport.git
synced 2025-01-03 08:33:18 +00:00
support verify
This commit is contained in:
parent
c309ea313e
commit
7c6ee6e9cb
@ -6,15 +6,9 @@
|
|||||||
; module by qkumba
|
; module by qkumba
|
||||||
;-------------------------------
|
;-------------------------------
|
||||||
!zone {
|
!zone {
|
||||||
.exit rts ; reachable only via inspect
|
rts ; reachable only via inspect
|
||||||
|
|
||||||
Choplifter
|
Choplifter
|
||||||
bit gMode ; nothing to do here in verify-only mode
|
|
||||||
bpl .exit
|
|
||||||
|
|
||||||
;; prepare write routine at $2000 for relocated address at $207
|
|
||||||
;; the difficulty here is to find three spare pages across all games
|
|
||||||
|
|
||||||
lda #$00
|
lda #$00
|
||||||
sta gCommand
|
sta gCommand
|
||||||
sta dct+1
|
sta dct+1
|
||||||
@ -36,6 +30,9 @@ Choplifter
|
|||||||
cmp #$23
|
cmp #$23
|
||||||
bne .read
|
bne .read
|
||||||
|
|
||||||
|
bit gMode ; done if in verify-only mode
|
||||||
|
bpl .exit
|
||||||
|
|
||||||
; start with RDOS as a minimal SD base
|
; start with RDOS as a minimal SD base
|
||||||
; and copy SD code for free
|
; and copy SD code for free
|
||||||
|
|
||||||
@ -91,6 +88,8 @@ Choplifter
|
|||||||
sta gTrack
|
sta gTrack
|
||||||
jsr WriteTrackNA
|
jsr WriteTrackNA
|
||||||
inc gPatchCount
|
inc gPatchCount
|
||||||
|
|
||||||
|
.exit
|
||||||
jsr .cleanup
|
jsr .cleanup
|
||||||
jmp Pass
|
jmp Pass
|
||||||
|
|
||||||
@ -236,10 +235,15 @@ ReadChoplifter
|
|||||||
sta .prolog2+1
|
sta .prolog2+1
|
||||||
lda (BASEPAGE<<8)+$D3
|
lda (BASEPAGE<<8)+$D3
|
||||||
sta .prolog3+1
|
sta .prolog3+1
|
||||||
-- jsr .readnib
|
|
||||||
|
.checkkey2
|
||||||
|
lda KEY
|
||||||
|
bmi .linkcancel2
|
||||||
|
jsr .readnib
|
||||||
|
|
||||||
.prolog1
|
.prolog1
|
||||||
- cmp #$D1 ; SMC
|
- cmp #$D1 ; SMC
|
||||||
bne --
|
bne .checkkey2
|
||||||
jsr .readnib
|
jsr .readnib
|
||||||
.prolog2
|
.prolog2
|
||||||
cmp #$D1 ; SMC
|
cmp #$D1 ; SMC
|
||||||
@ -256,10 +260,10 @@ ReadChoplifter
|
|||||||
sta tmp
|
sta tmp
|
||||||
jsr .readnib
|
jsr .readnib
|
||||||
and tmp
|
and tmp
|
||||||
sta (BASEPAGE+$0f)<<8,x
|
sta (BASEPAGE+8)<<8,x
|
||||||
inx
|
inx
|
||||||
jsr .read4x4
|
jsr .read4x4
|
||||||
sta (BASEPAGE+$0f)<<8,x
|
sta (BASEPAGE+8)<<8,x
|
||||||
inx
|
inx
|
||||||
jsr .readnib
|
jsr .readnib
|
||||||
sec
|
sec
|
||||||
@ -268,19 +272,10 @@ ReadChoplifter
|
|||||||
- lda $C0EC
|
- lda $C0EC
|
||||||
bpl -
|
bpl -
|
||||||
and tmp
|
and tmp
|
||||||
sta (BASEPAGE+$0f)<<8,x
|
sta (BASEPAGE+8)<<8,x
|
||||||
inx
|
inx
|
||||||
cmp #$EA
|
cmp #$EA
|
||||||
bne --
|
bne --
|
||||||
;; future work, just disable for now
|
|
||||||
;; ldx #0
|
|
||||||
;;.copywrite
|
|
||||||
;; lda .writeroutine,x
|
|
||||||
;; sta (BASEPAGE+8)<<8,x
|
|
||||||
;; inx
|
|
||||||
;; bne .copywrite
|
|
||||||
lda #$60 ; rts
|
|
||||||
sta ((BASEPAGE+8)<<8)+7
|
|
||||||
rts
|
rts
|
||||||
|
|
||||||
.readtrack22
|
.readtrack22
|
||||||
@ -389,12 +384,17 @@ ReadChoplifter
|
|||||||
.stager !pseudopc $500 {
|
.stager !pseudopc $500 {
|
||||||
jsr .callSD
|
jsr .callSD
|
||||||
jsr .step
|
jsr .step
|
||||||
lda #$60
|
lda #$60 ; rts
|
||||||
sta $801
|
sta $801
|
||||||
lda #2
|
|
||||||
|
; to enable writing requires finding three spare pages
|
||||||
|
; that is common to all games. I did not succeed.
|
||||||
|
; for that reason, auto-crack is read-only.
|
||||||
|
|
||||||
|
sta $207
|
||||||
|
|
||||||
|
lda #4
|
||||||
sta $27
|
sta $27
|
||||||
jsr $823 ; read write routine to $200 (but starts at $207)
|
|
||||||
inc $27
|
|
||||||
jsr $823 ; read patch table to $400
|
jsr $823 ; read patch table to $400
|
||||||
ldy #0 ; avoid CFFA bug (Y is not zero on return)
|
ldy #0 ; avoid CFFA bug (Y is not zero on return)
|
||||||
- lda $400,y
|
- lda $400,y
|
||||||
|
Loading…
Reference in New Issue
Block a user