passport/src/patchers/aacount.a
2021-06-21 10:33:16 -04:00

32 lines
930 B
Plaintext

;-------------------------------
; #AACount
; self-decrypting and re-encrypting nibble count
;
; tested on
; Battle Group (SSI)
; Moebius (Origin)
;-------------------------------
!zone {
lda #$0F
sta .sector+1
.sector lda #$FD ; SMC
ldx #$04
ldy #$0E
jsr compare
!byte $CE,$07,$02 ; DEC $0207
!byte $EF,$07,$02 ; ??? $0207 (becomes INC)
!byte $A0,$27 ; LDY #$27
!byte $D0,$02 ; BNE *+4
!byte $00 ; BRK
!byte $6C,$B9,$00 ; JMP ($00B9)
bcs + ; passport-test-suite/Moebius.woz [C=0] matches
jsr PrintByID
!byte s_aacount
jsr modify1
!byte $60 ; RTS
+
dec .sector+1
bpl .sector
.exit
}