From 154aea3cd9cc66e18fe78bd4b26de52b22399bbe Mon Sep 17 00:00:00 2001 From: 4am Date: Sat, 12 Jun 2021 00:50:09 -0400 Subject: [PATCH] shave some bytes --- src/compare.a | 6 ++++-- src/modify.a | 6 ++++-- src/patchers/bademu2.a | 1 - src/patchers/bb03.a | 3 +-- src/patchers/c9ff.a | 1 - src/patchers/corrupter.a | 1 - src/patchers/diskvol.a | 6 ++---- src/patchers/dos32dlm.a | 1 - src/patchers/dos32muse.a | 2 +- src/patchers/earthware.a | 2 +- src/patchers/hoffman.a | 1 - src/patchers/holle.a | 4 ---- src/patchers/jmpae8e.a | 2 +- src/patchers/jmpb400.a | 2 +- src/patchers/jmpb4bb.a | 1 - src/patchers/jmpb720.a | 2 -- src/patchers/jmpbbfe.a | 2 +- src/patchers/jmpbcf0.a | 1 - src/patchers/jmpbeb1.a | 1 - src/patchers/jmpbeca.a | 1 - src/patchers/laureate.a | 2 -- src/patchers/mecc.a | 1 - src/patchers/meccdqc.a | 1 - src/patchers/methods.a | 5 ++--- src/patchers/microfun2.a | 2 -- src/patchers/milliken.a | 1 - src/patchers/muserwts.a | 4 +--- src/patchers/pascalrwts.a | 2 -- src/patchers/prodosmecc.a | 1 - src/patchers/prodosrwts.a | 1 - src/patchers/protecteddos.a | 6 ++---- src/patchers/rdos13.a | 2 -- src/patchers/rps.a | 4 +--- src/patchers/rwtslog.a | 2 -- src/patchers/rwtsswap.a | 3 --- src/patchers/rwtsswap2.a | 2 -- src/patchers/ssprot.a | 8 +++----- src/patchers/sunburst.a | 10 +++------- src/patchers/sve.a | 5 +---- src/patchers/swordthrust.a | 3 +-- src/patchers/t02volumename.a | 1 - src/patchers/trillium2.a | 1 - src/patchers/tsr.a | 1 - 43 files changed, 30 insertions(+), 84 deletions(-) diff --git a/src/compare.a b/src/compare.a index 7331561..bf63c95 100755 --- a/src/compare.a +++ b/src/compare.a @@ -182,8 +182,7 @@ all_done_set ; (like "." character in regular expressions) ; out: C clear if string matches ; or set if not matched -; A,X unchanged -; Y clobbered +; A,X,Y preserved ; $tmp zero page clobbered ; $cmp1 zero page clobbered ; $cmp2 zero page clobbered @@ -195,6 +194,7 @@ compare CompareMemory sta cmp1+1 stx cmp1 + sty compare_tmp_y pla sta cmp2 pla @@ -226,5 +226,7 @@ CompareMemory sec sbc #BASEPAGE ldx cmp1 +compare_tmp_y=*+1 + ldy #$FD ; SMC plp rts diff --git a/src/modify.a b/src/modify.a index c955d43..40c4b72 100755 --- a/src/modify.a +++ b/src/modify.a @@ -10,12 +10,12 @@ ; $moddest zero page clobbered ; stack set to return to ; code after string -; A,X preserved -; Y clobbered +; A,X,Y preserved ; oVerflow bit clear ; all other flags clobbered ;------------------------------- modify + sty mod_tmp_y sta gDisplayBytes clc adc #BASEPAGE @@ -68,5 +68,7 @@ modify @exitnomod lda gDisplayBytes ldx moddest +mod_tmp_y=*+1 + ldy #$FD ; SMC clv rts diff --git a/src/patchers/bademu2.a b/src/patchers/bademu2.a index 5c2bca6..2bff901 100755 --- a/src/patchers/bademu2.a +++ b/src/patchers/bademu2.a @@ -26,7 +26,6 @@ !byte $C9,$D5 ; CMP #$D5 !byte $F0,$12 ; BEQ +$12 bcs .exit ; passport-test-suite/Dinosaur Days.woz [C=0] matches - lda #$03 ldx #$59 ldy #$02 jsr modify ; then set T00,S03,$59 = diff --git a/src/patchers/bb03.a b/src/patchers/bb03.a index e2662f9..8bd2148 100755 --- a/src/patchers/bb03.a +++ b/src/patchers/bb03.a @@ -46,7 +46,6 @@ jsr compare ; if T00,S01,$38 == !byte $20,$03,$BB; JSR $BB03 bcc .variant1 - ldy #$03 jsr compare ; if T00,S01,$38 == !byte $4C,$03,$BB; JMP $BB03 bcs .no @@ -63,7 +62,7 @@ !byte $6B,$F6 ; encrypted, decrypts to 'BNE +$5C' which will unconditionally branch to success path at $BBC9 lda #$06 ldx #$0F - ldy #$01 + dey jsr modify ; and set T00,S06,$0F = !byte $89 ; encrypted, decrypts to $10 which is the expected nibble count value ; unconditional branch (V is always 0 coming out of modify) diff --git a/src/patchers/c9ff.a b/src/patchers/c9ff.a index 2cc67e5..353f9bb 100644 --- a/src/patchers/c9ff.a +++ b/src/patchers/c9ff.a @@ -37,7 +37,6 @@ jsr modify !byte $DE jsr inx0A - ldy #$01 jsr modify !byte $AA .exit diff --git a/src/patchers/corrupter.a b/src/patchers/corrupter.a index 8478037..4d58176 100644 --- a/src/patchers/corrupter.a +++ b/src/patchers/corrupter.a @@ -33,7 +33,6 @@ !byte $D0,$F1 ; BNE -$F1 bcs .exit ldx #$A4 - ldy #$0F jsr compare !byte $A9,$23 ; LDA #$23 !byte $85,$02 ; STA $02 diff --git a/src/patchers/diskvol.a b/src/patchers/diskvol.a index a77de67..876ec70 100755 --- a/src/patchers/diskvol.a +++ b/src/patchers/diskvol.a @@ -36,8 +36,6 @@ jsr compare ; and T00,S01,$EB != !byte $FE bcc .exit - - ldy #$01 jsr compare ; and T00,S01,$EB != !byte $00 bcc .exit @@ -52,8 +50,8 @@ bcc .veryyes ; passport-test-suite/The Incredible Laboratory.woz [C=0] matches ldx #$16 ; or T00,S08,$16 == the same thing - ldy #$05 ; (variation used by PanglosDOS) - jsr compare ; preserves A/X + ; (variation used by PanglosDOS) + jsr compare ; preserves A/X/Y !byte $A0,$03 !byte $B1,$48 !byte $48 diff --git a/src/patchers/dos32dlm.a b/src/patchers/dos32dlm.a index 1ad065e..09f4de3 100644 --- a/src/patchers/dos32dlm.a +++ b/src/patchers/dos32dlm.a @@ -18,7 +18,6 @@ jsr compare ; if T00,S0B,$84 == !byte $4C,$F0,$BC bcs .exit ; passport-test-suite/Demolition Division.woz [C=0] matches - ldy #$03 jsr modify ; then set T00,S0B,$84 = !byte $AD,$E9,$B7 .exit diff --git a/src/patchers/dos32muse.a b/src/patchers/dos32muse.a index b98c221..1a068ad 100644 --- a/src/patchers/dos32muse.a +++ b/src/patchers/dos32muse.a @@ -17,7 +17,7 @@ jsr compare ; if T01,S08,$D6 == !byte $4C,$D5 bcs .exit ; passport-test-suite/Castle Wolfenstein.woz [C=0] matches - ldy #$03 + iny jsr modify ; then set T01,S08,$D6 = !byte $E8,$D0,$32 .exit diff --git a/src/patchers/earthware.a b/src/patchers/earthware.a index 8abc85f..730f3ab 100644 --- a/src/patchers/earthware.a +++ b/src/patchers/earthware.a @@ -18,7 +18,7 @@ EARTHWARE ldy #$03 jsr compare !byte $4C,$89,$B6 - bcs @exit + bcs @exit ; passport-test-suite/Zoo Master.woz [C=0] here sta gDisplayBytes pha lda #s_bytrack diff --git a/src/patchers/hoffman.a b/src/patchers/hoffman.a index 54c1614..edd2841 100644 --- a/src/patchers/hoffman.a +++ b/src/patchers/hoffman.a @@ -35,7 +35,6 @@ lda #s_hoffman jsr PrintByID lda #$0C - ldx #$00 ldy #$01 jsr modify ; then set T00,S0C,$00 = ; diff --git a/src/patchers/holle.a b/src/patchers/holle.a index 868f5ac..1e098a3 100644 --- a/src/patchers/holle.a +++ b/src/patchers/holle.a @@ -36,7 +36,6 @@ jsr compare !byte $DE bcc + - ldy #$01 jsr modify !byte $DE + @@ -52,7 +51,6 @@ jsr compare !byte $DE bcc + - ldy #$01 jsr modify !byte $DE + @@ -67,8 +65,6 @@ jsr compare ; first data epilogue nibble (write) !byte $DE bcc + - ldx #$9E - ldy #$01 jsr modify !byte $DE + diff --git a/src/patchers/jmpae8e.a b/src/patchers/jmpae8e.a index 785ba54..035e0e9 100755 --- a/src/patchers/jmpae8e.a +++ b/src/patchers/jmpae8e.a @@ -17,7 +17,7 @@ lda #s_jmpae8e jsr PrintByID lda #$0D - ldx #$4E + inx ldy #$02 jsr modify ; then set T00,S0D,$4E = !byte $80,$A1 diff --git a/src/patchers/jmpb400.a b/src/patchers/jmpb400.a index 09ea95f..a982181 100644 --- a/src/patchers/jmpb400.a +++ b/src/patchers/jmpb400.a @@ -50,10 +50,10 @@ sta gDisplayBytes ; address (hi) lda #$00 sta gDisplayBytes+1 ; address (lo) + tax lda #s_beforedos jsr PrintByID lda #$03 - ldx #$00 tay jsr modify ; then set T02,S03,$00 = !byte $4C,$84,$9D diff --git a/src/patchers/jmpb4bb.a b/src/patchers/jmpb4bb.a index 2831582..fa640bf 100755 --- a/src/patchers/jmpb4bb.a +++ b/src/patchers/jmpb4bb.a @@ -54,7 +54,6 @@ !byte $AD,$FF,$CF; LDA $CFFF bcc .found ; passport-test-suite/Kamikaze.woz [C=0] matches ldx #$DD - ldy #$04 jsr compare ; or T02,S0x,$DD == !byte $D8 ; CLD !byte $AD,$FF,$CF; LDA $CFFF diff --git a/src/patchers/jmpb720.a b/src/patchers/jmpb720.a index 1c7423e..04d24c6 100755 --- a/src/patchers/jmpb720.a +++ b/src/patchers/jmpb720.a @@ -24,8 +24,6 @@ _jmpb720 !byte $10,$F1 !byte $60 bcs .exit ; passport-test-suite/Analogies Tutorial.woz [C=0] matches - lda #$0B - ldx #$08 ldy #$06 jsr modify ; then set T00,S0B,$08 = !byte $BD,$8C,$C0 diff --git a/src/patchers/jmpbbfe.a b/src/patchers/jmpbbfe.a index e44d676..ea0b6a7 100755 --- a/src/patchers/jmpbbfe.a +++ b/src/patchers/jmpbbfe.a @@ -136,7 +136,7 @@ _jmpbbfe + !byte $FD ; SMC (byte offset of new entry point) ldx #$5E - ldy #$02 + iny ; Y=#$02 jsr compare ; check for code that branches over serial number !byte $D0,$05 bcs .exit diff --git a/src/patchers/jmpbcf0.a b/src/patchers/jmpbcf0.a index 7e926ff..919eb40 100755 --- a/src/patchers/jmpbcf0.a +++ b/src/patchers/jmpbcf0.a @@ -22,7 +22,6 @@ _jmpbcf0 lda #s_jmpbcf0 jsr PrintByID lda #$03 - ldx #$94 ldy #$08 jsr modify ; then set T00,S03,$94 = !byte $EA diff --git a/src/patchers/jmpbeb1.a b/src/patchers/jmpbeb1.a index 269bccb..2853e92 100755 --- a/src/patchers/jmpbeb1.a +++ b/src/patchers/jmpbeb1.a @@ -71,7 +71,6 @@ _jmpbeb1 jsr modify ; and set T00,S02,$52 = !byte $A9,$D5 _jsr !byte $20,$B8,$d1; final byte set at runtime - lda #$02 ldx #$5F ldy #$01 jsr modify ; and set T00,S02,$5F = diff --git a/src/patchers/jmpbeca.a b/src/patchers/jmpbeca.a index 245f24f..94d3c28 100755 --- a/src/patchers/jmpbeca.a +++ b/src/patchers/jmpbeca.a @@ -24,7 +24,6 @@ ; ; variant seen in Library Magic ; - ldy #$0D jsr compare ; or T00,S02,$F4 == !byte $4C,$CA,WILDCARD !byte $EA diff --git a/src/patchers/laureate.a b/src/patchers/laureate.a index a1b169a..ae215d8 100644 --- a/src/patchers/laureate.a +++ b/src/patchers/laureate.a @@ -28,7 +28,6 @@ jsr compare .valuea !byte $d1 bcc + - ldy #$01 jsr modify .valueb !byte $d1 + dec .loop+1 @@ -40,7 +39,6 @@ jsr compare !byte $B1,$48 bcs .exit - ldy #$02 jsr modify !byte $A9,$00 .exit diff --git a/src/patchers/mecc.a b/src/patchers/mecc.a index 41894f6..930ce65 100644 --- a/src/patchers/mecc.a +++ b/src/patchers/mecc.a @@ -35,7 +35,6 @@ !byte $D1 ; SMC bcc + - ldy #$01 jsr modify .modbyte !byte $D1 ; SMC diff --git a/src/patchers/meccdqc.a b/src/patchers/meccdqc.a index 87fbceb..7f32d95 100644 --- a/src/patchers/meccdqc.a +++ b/src/patchers/meccdqc.a @@ -43,7 +43,6 @@ !byte $D1 ; SMC bcc + - ldy #$01 jsr modify .modbyte !byte $D1 ; SMC diff --git a/src/patchers/methods.a b/src/patchers/methods.a index 229f892..f7c7dee 100644 --- a/src/patchers/methods.a +++ b/src/patchers/methods.a @@ -40,14 +40,13 @@ ldy #$01 jsr modify ; then set T00,S00,$BD = !byte $24 ; BIT - lda #$01 + tya ldx #$47 ldy #$03 jsr compare ; if T00,S01,$47 == !byte $4C,$CE,$36; JMP $36CE bcs .exit - lda #$01 - ldx #$48 + inx ldy #$01 jsr modify ; then set T00,S01,$48 = !byte $D8 diff --git a/src/patchers/microfun2.a b/src/patchers/microfun2.a index e7f484b..dcd465f 100644 --- a/src/patchers/microfun2.a +++ b/src/patchers/microfun2.a @@ -14,8 +14,6 @@ jsr compare !byte $4C,$B8,$B6 bcs .exit ; passort-test-suite/Crown Of Arthain.woz [C=0] matches - sta gDisplayBytes - ldy #$03 jsr modify !byte $20,$B8,$B8 .exit diff --git a/src/patchers/milliken.a b/src/patchers/milliken.a index 080a0aa..cb502cd 100644 --- a/src/patchers/milliken.a +++ b/src/patchers/milliken.a @@ -15,7 +15,6 @@ jsr compare ; and T00,S01,$48 == !byte $03,$9B bcs .exit ; passport-test-suite/Tangrams Puzzler.woz [C=0] matches - ldy #$02 jsr modify ; then set T00,S01,$48 = !byte $84,$9D .exit diff --git a/src/patchers/muserwts.a b/src/patchers/muserwts.a index 87a4efc..5318dca 100644 --- a/src/patchers/muserwts.a +++ b/src/patchers/muserwts.a @@ -15,12 +15,10 @@ jsr compare ; if T00,S06,$F2 == !byte $20,$B6,$B6 bcs .exit ; passport-test-suite/The Function Game.woz [C=0] matches - pha - lda #6 sta gDisplayBytes lda #s_bytrack jsr PrintByID - pla + lda #$06 ldy #$01 jsr modify ; then set T00,S06,$F2 = !byte $2C diff --git a/src/patchers/pascalrwts.a b/src/patchers/pascalrwts.a index 33007e7..c9dacfb 100644 --- a/src/patchers/pascalrwts.a +++ b/src/patchers/pascalrwts.a @@ -30,7 +30,6 @@ jsr compare ; and T00,S0D,$51 != !byte $AA bcc + - ldy #$01 jsr modify !byte $AA @@ -52,7 +51,6 @@ jsr compare ; and T00,S0F,$7B != !byte $AA bcc + - ldy #$01 jsr modify !byte $AA + diff --git a/src/patchers/prodosmecc.a b/src/patchers/prodosmecc.a index 4babab4..0dec2ec 100755 --- a/src/patchers/prodosmecc.a +++ b/src/patchers/prodosmecc.a @@ -20,7 +20,6 @@ jsr compare !byte $DE bcc + - ldy #$01 jsr modify !byte $DE + diff --git a/src/patchers/prodosrwts.a b/src/patchers/prodosrwts.a index 454287e..95b58ac 100755 --- a/src/patchers/prodosrwts.a +++ b/src/patchers/prodosrwts.a @@ -26,7 +26,6 @@ _prodosrwts jsr compare !byte $DE bcc .exit - ldy #$01 jsr modify !byte $DE .exit diff --git a/src/patchers/protecteddos.a b/src/patchers/protecteddos.a index 8313cc1..70653bb 100755 --- a/src/patchers/protecteddos.a +++ b/src/patchers/protecteddos.a @@ -39,7 +39,7 @@ tax .swapper2 lda #$FF ; modified at runtime - ldy #$01 + ;Y=#$01 jsr modify ; offset $08. $D5 -> 9B !byte $9B @@ -111,7 +111,7 @@ !byte $AD lda #$02 ldx #$B7 - ldy #$01 + ;Y=#$01 jsr modify ; and set T01,S02,$B7 = !byte $9B @@ -163,7 +163,6 @@ jsr compare ; if T00,S01,$93 == !byte $4C,$00,$B8 bcs .skipcheck ; passport-test-suite/Ultima IV.woz [C=0] matches - ldy #$03 jsr modify ; then set T00,S01,$93 = !byte $AC,$E5,$B7 .skipcheck @@ -179,7 +178,6 @@ jsr compare ; if T00,S05,$15 == !byte $A5,$2F bcs .exit ; passport-test-suite/Math Blaster v080584.woz [C=0] matches - ldy #$02 jsr modify ; then set T00,S05,$15 = !byte $A9,$00 diff --git a/src/patchers/rdos13.a b/src/patchers/rdos13.a index ae7cf97..c531128 100644 --- a/src/patchers/rdos13.a +++ b/src/patchers/rdos13.a @@ -22,7 +22,6 @@ lda #$9 ldx #$89 - ldy #3 jsr modify !byte $04 ;sync delay !byte $48 ;PHA @@ -50,7 +49,6 @@ jsr compare !byte $C9,$D5 ;CMP #$D5 bcc + - ldy #2 jsr modify !byte $C9,$D5 ;CMP #$D5 diff --git a/src/patchers/rps.a b/src/patchers/rps.a index b4e3d21..abf3a07 100755 --- a/src/patchers/rps.a +++ b/src/patchers/rps.a @@ -60,7 +60,7 @@ ; /!\ execution falls through here .variant1 - lda #$01 + ;A=#$01 here regardless of how we got here ldx #$87 ldy #$03 jsr compare ; if T00,S01,$87 == @@ -71,7 +71,6 @@ jsr modify ; then set T00,S01,$8E = !byte $F8 ; change branch to unconditionally jump to success path ldx #$92 - ldy #$01 jsr modify ; and set T00,S01,$92 = !byte $F1 ; change branch to unconditionally jump to success path bvc .exit ; always branches @@ -88,7 +87,6 @@ jsr modify ; then set T00,S01,$8E = !byte $F9 ; change branch to unconditionally jump to success path ldx #$92 - ldy #$01 jsr modify ; and set T00,S01,$92 = !byte $F2 ; change branch to unconditionally jump to success path .exit diff --git a/src/patchers/rwtslog.a b/src/patchers/rwtslog.a index 7b6adb0..15bcd46 100644 --- a/src/patchers/rwtslog.a +++ b/src/patchers/rwtslog.a @@ -109,8 +109,6 @@ ; David-DOS variant lda #$05 sta gDisplayBytes - ldx #$8B - ldy #$09 jsr compare ; or T00,S05,$8B == !byte $BD,$8C,$C0 !byte $10,$FB diff --git a/src/patchers/rwtsswap.a b/src/patchers/rwtsswap.a index ce8a3cb..19d8006 100755 --- a/src/patchers/rwtsswap.a +++ b/src/patchers/rwtsswap.a @@ -21,7 +21,6 @@ !byte $10,$F7 bcs .exit ldx #$7F - ldy #$0B jsr compare ; and T00,S04,$7F == !byte $A0,$07 !byte $B9,$E7,$BC @@ -33,9 +32,7 @@ ldy #$01 jsr modify ; then set T00,S04,$69 = !byte $60 - lda #$04 ldx #$7F - ldy #$01 jsr modify ; and set T00,S04,$7F = !byte $60 .exit diff --git a/src/patchers/rwtsswap2.a b/src/patchers/rwtsswap2.a index 8f93dc2..a9bcaea 100755 --- a/src/patchers/rwtsswap2.a +++ b/src/patchers/rwtsswap2.a @@ -40,9 +40,7 @@ _rwtsswap2 ldy #$01 jsr modify ; then set T00,S04,$69 = !byte $60 - lda #$04 ldx #$7D - ldy #$01 jsr modify ; and set T00,S04,$7D = !byte $60 .exit diff --git a/src/patchers/ssprot.a b/src/patchers/ssprot.a index 093978b..3b0bdba 100644 --- a/src/patchers/ssprot.a +++ b/src/patchers/ssprot.a @@ -46,12 +46,10 @@ !byte $23,$2A,$28 bcc .variant1 ; passport-test-suite/Creative Contraptions.woz [C=0] matches - ldy #$03 jsr compare !byte $70,$79,$77 bcc .variant2 ; passport-test-suite/Wortgefecht.woz [C=0] matches - ldy #$03 jsr compare !byte $23,$2A,$24 ; passport-test-suite/Metric System Tutor.woz [C=0] matches bcc .variant3 @@ -67,7 +65,7 @@ !byte $EA ; NOP !byte $A9,$35 ; LDA #$35 ldx #$76 - ldy #$02 + dey jsr modify !byte $AA,$A2 ; new JMP entry point ($0900 when decrypted) bvc .nextsector ; always branches @@ -79,7 +77,7 @@ !byte $EA ; NOP !byte $A9,$27 ; LDA #$27 ldx #$76 - ldy #$02 + dey jsr modify ; new JMP entry point ($0903 when decrypted) !byte $FA,$F2 bvc .nextsector ; always branches @@ -91,7 +89,7 @@ !byte $EA ; NOP !byte $A9,$27 ; LDA #$27 ldx #$76 - ldy #$02 + dey jsr modify ; new JMP entry point ($0903 when decrypted) !byte $A9,$A1 diff --git a/src/patchers/sunburst.a b/src/patchers/sunburst.a index 965c80d..7ebb4ef 100755 --- a/src/patchers/sunburst.a +++ b/src/patchers/sunburst.a @@ -67,21 +67,19 @@ !byte $D0 bcs .exit ldx #$9C - ldy #$01 jsr compare ; and T00,S03,$9C == !byte $F0 bcs .exit lda #$04 ldx #$69 - ldy #$04 + tay jsr compare ; and T00,S04,$69 == !byte $48 !byte $A5,$2A !byte $4A bcs .exit lda #$06 - ldx #$69 - ldy #$06 + tay jsr compare ; and T00,S06,$69 == !byte $4C,$B8,$B6 !byte $EA @@ -102,14 +100,12 @@ ldy #$01 jsr modify ; then set T00,S03,$40 = !byte $F0 - lda #$03 ldx #$9C - ldy #$01 jsr modify ; and set T00,S03,$9C = !byte $D0 lda #$06 ldx #$69 - ldy #$06 + tay jsr modify ; and set T00,S06,$69 = !byte $20,$C3,$BC !byte $20,$C3,$BC diff --git a/src/patchers/sve.a b/src/patchers/sve.a index 9b8b083..e55f3b0 100644 --- a/src/patchers/sve.a +++ b/src/patchers/sve.a @@ -15,9 +15,6 @@ jsr compare !byte $4C,$71,$A9 ; JMP $A971 bcs .exit - lda #$08 - ldx #$5A - ldy #$03 jsr modify !byte $48,$A0,$01 lda #$06 @@ -33,7 +30,7 @@ and #$7f sta .config lda #$06 - ldx #$55 + dex ldy #$01 jsr modify .config diff --git a/src/patchers/swordthrust.a b/src/patchers/swordthrust.a index 0d27801..3d6cc60 100644 --- a/src/patchers/swordthrust.a +++ b/src/patchers/swordthrust.a @@ -28,11 +28,10 @@ jsr PrintByID lda #$01 ldx #$81 - ldy #$01 + tay jsr modify !byte $2C ldx #$84 - ldy #$01 jsr modify !byte $2C .exit diff --git a/src/patchers/t02volumename.a b/src/patchers/t02volumename.a index a6796f6..c2fa787 100644 --- a/src/patchers/t02volumename.a +++ b/src/patchers/t02volumename.a @@ -73,7 +73,6 @@ !byte $D4,$C9,$C1,$C2,$D3,$D2,$C1,$C2 rts - .exitwithCR lda #$8D jsr PrintA diff --git a/src/patchers/trillium2.a b/src/patchers/trillium2.a index 61d727a..5bcc34a 100644 --- a/src/patchers/trillium2.a +++ b/src/patchers/trillium2.a @@ -33,7 +33,6 @@ inx inx inx - ldy #$01 jsr modify !byte $A9 ; LDA .exit diff --git a/src/patchers/tsr.a b/src/patchers/tsr.a index 47bb2f5..76c8e21 100644 --- a/src/patchers/tsr.a +++ b/src/patchers/tsr.a @@ -35,7 +35,6 @@ jsr modify ; then set T04,S0B,$A2 = !byte $2C ldx #$A7 - ldy #$01 jsr modify ; and set T04,S0B,$A7 = !byte $2C .exit