From da10566591539d02a22e11fd2f29c3a336f53d57 Mon Sep 17 00:00:00 2001 From: 4am Date: Sat, 4 Dec 2021 21:23:11 -0500 Subject: [PATCH] shave some bytes --- src/fx/fx.shr.2pass.lr.a | 2 ++ src/fx/fx.shr.80boxes.common.a | 24 +++++++++++------------- src/fx/fx.shr.common.a | 25 +++++++++++++++++-------- src/fx/fx.shr.diagonal.a | 2 ++ src/fx/fx.shr.fizzle.a | 3 ++- src/fx/fx.shr.lr.a | 4 +++- src/fx/fx.shr.lr2.a | 2 ++ src/fx/fx.shr.ud.a | 4 +++- 8 files changed, 42 insertions(+), 24 deletions(-) diff --git a/src/fx/fx.shr.2pass.lr.a b/src/fx/fx.shr.2pass.lr.a index b1fe95e3c..54c8a94cf 100644 --- a/src/fx/fx.shr.2pass.lr.a +++ b/src/fx/fx.shr.2pass.lr.a @@ -17,7 +17,9 @@ shrhi = $38 ; $C8 bytes bpl - +BUILD_SHR_LOOKUP_TABLES shrlo, shrhi + ;X=0 +COPY_SCB_AND_PALETTES + ;WRITEAUXMEM active jmp loop1 diff --git a/src/fx/fx.shr.80boxes.common.a b/src/fx/fx.shr.80boxes.common.a index 2d384618f..e596fc183 100644 --- a/src/fx/fx.shr.80boxes.common.a +++ b/src/fx/fx.shr.80boxes.common.a @@ -101,6 +101,10 @@ BoxesY = $BEB0 ; [$50 bytes][accessed via BoxesY-1][should -- ldy #10 lda #$90 - sta BoxesY-1, x + pha + lda BoxInitialStages-1, x + sta BoxStages-1, x + pla sec sbc #$10 dex @@ -116,24 +120,18 @@ BoxesY = $BEB0 ; [$50 bytes][accessed via BoxesY-1][should sta StageIndexes, x inx bne - - ldx #80 ; can't do full $100 here because we'd clobber the stack -- lda BoxInitialStages-1, x - sta BoxStages-1, x - dex - bne - +BUILD_SHR_LOOKUP_TABLES shrlo, shrhi + ;X=0 +COPY_SCB_AND_PALETTES ;WRITEAUXMEM active jmp MainLoop start !pseudopc 0 { -copy1 - ldx