From c7f6e02e2d66f2175390169e6740aaf87b28860d Mon Sep 17 00:00:00 2001 From: 4am Date: Tue, 16 Nov 2021 17:44:12 -0500 Subject: [PATCH] merge TOTAL.IDX into TOTAL.DATA and remove filename parameter from LoadIndexedFile --- Makefile | 56 ++++++++++++++++++------------------- src/constants.a | 4 +-- src/glue.launch.a | 3 -- src/glue.prorwts2.a | 28 +++++-------------- src/index/artwork.idx.a | 2 +- src/index/attract.idx.a | 2 +- src/index/cache00.idx.a | 2 +- src/index/cache01.idx.a | 2 +- src/index/cache10.idx.a | 2 +- src/index/cache11.idx.a | 2 +- src/index/dfx.idx.a | 2 +- src/index/dhgr.idx.a | 2 +- src/index/dtitle.idx.a | 2 +- src/index/fx.idx.a | 2 +- src/index/gamehelp.idx.a | 2 +- src/index/gr.idx.a | 2 +- src/index/hgr0.idx.a | 2 +- src/index/hgr1.idx.a | 2 +- src/index/hgr2.idx.a | 2 +- src/index/hgr3.idx.a | 2 +- src/index/hgr4.idx.a | 2 +- src/index/hgr5.idx.a | 2 +- src/index/hgr6.idx.a | 2 +- src/index/miniattract.idx.a | 2 +- src/index/prelaunch.idx.a | 2 +- src/index/search00.idx.a | 2 +- src/index/search01.idx.a | 2 +- src/index/search10.idx.a | 2 +- src/index/search11.idx.a | 2 +- src/index/slideshow.idx.a | 2 +- src/index/title.idx.a | 2 +- src/prodos.path.a | 4 --- src/textrank.a | 4 +-- src/ui.attract.dhgr.a | 5 ---- src/ui.attract.gr.a | 4 +-- src/ui.attract.hgr.a | 6 ---- src/ui.attract.mode.a | 5 ---- src/ui.attract.shr.a | 2 -- src/ui.credits.a | 2 -- src/ui.offscreen.a | 3 -- 40 files changed, 65 insertions(+), 115 deletions(-) diff --git a/Makefile b/Makefile index a4dee8cd9..481236636 100644 --- a/Makefile +++ b/Makefile @@ -44,7 +44,6 @@ dsk: index asmproboot asmlauncher # for f in \ build/TOTAL.DATA \ - build/TOTAL.IDX \ res/TITLE \ res/COVER \ res/HELP \ @@ -175,34 +174,33 @@ index: md asmfx asmprelaunch compress # add IDX files to the combined index file and generate # the index records that callers use to reference them # - rm -f build/TOTAL.IDX - bin/addfile.sh build/SEARCH00.IDX build/TOTAL.IDX > src/index/search00.idx.a - bin/addfile.sh res/CACHE00.IDX build/TOTAL.IDX > src/index/cache00.idx.a - bin/addfile.sh build/SEARCH01.IDX build/TOTAL.IDX > src/index/search01.idx.a - bin/addfile.sh res/CACHE01.IDX build/TOTAL.IDX > src/index/cache01.idx.a - bin/addfile.sh build/SEARCH10.IDX build/TOTAL.IDX > src/index/search10.idx.a - bin/addfile.sh res/CACHE10.IDX build/TOTAL.IDX > src/index/cache10.idx.a - bin/addfile.sh build/SEARCH11.IDX build/TOTAL.IDX > src/index/search11.idx.a - bin/addfile.sh res/CACHE11.IDX build/TOTAL.IDX > src/index/cache11.idx.a - bin/addfile.sh build/PRELAUNCH.IDX build/TOTAL.IDX > src/index/prelaunch.idx.a - bin/addfile.sh build/ATTRACT.IDX build/TOTAL.IDX > src/index/attract.idx.a - bin/addfile.sh build/FX.IDX build/TOTAL.IDX > src/index/fx.idx.a - bin/addfile.sh build/DFX.IDX build/TOTAL.IDX > src/index/dfx.idx.a - bin/addfile.sh build/GAMEHELP.IDX build/TOTAL.IDX > src/index/gamehelp.idx.a - bin/addfile.sh build/SLIDESHOW.IDX build/TOTAL.IDX > src/index/slideshow.idx.a - bin/addfile.sh build/MINIATTRACT.IDX build/TOTAL.IDX > src/index/miniattract.idx.a - bin/addfile.sh build/TITLE.IDX build/TOTAL.IDX > src/index/title.idx.a - bin/addfile.sh build/DTITLE.IDX build/TOTAL.IDX > src/index/dtitle.idx.a - bin/addfile.sh build/HGR0.IDX build/TOTAL.IDX > src/index/hgr0.idx.a - bin/addfile.sh build/HGR1.IDX build/TOTAL.IDX > src/index/hgr1.idx.a - bin/addfile.sh build/HGR2.IDX build/TOTAL.IDX > src/index/hgr2.idx.a - bin/addfile.sh build/HGR3.IDX build/TOTAL.IDX > src/index/hgr3.idx.a - bin/addfile.sh build/HGR4.IDX build/TOTAL.IDX > src/index/hgr4.idx.a - bin/addfile.sh build/HGR5.IDX build/TOTAL.IDX > src/index/hgr5.idx.a - bin/addfile.sh build/HGR6.IDX build/TOTAL.IDX > src/index/hgr6.idx.a - bin/addfile.sh build/DHGR.IDX build/TOTAL.IDX > src/index/dhgr.idx.a - bin/addfile.sh build/GR.IDX build/TOTAL.IDX > src/index/gr.idx.a - bin/addfile.sh build/ARTWORK.IDX build/TOTAL.IDX > src/index/artwork.idx.a + [ -f build/index ] || bin/addfile.sh build/SEARCH00.IDX build/TOTAL.DATA > src/index/search00.idx.a + [ -f build/index ] || bin/addfile.sh res/CACHE00.IDX build/TOTAL.DATA > src/index/cache00.idx.a + [ -f build/index ] || bin/addfile.sh build/SEARCH01.IDX build/TOTAL.DATA > src/index/search01.idx.a + [ -f build/index ] || bin/addfile.sh res/CACHE01.IDX build/TOTAL.DATA > src/index/cache01.idx.a + [ -f build/index ] || bin/addfile.sh build/SEARCH10.IDX build/TOTAL.DATA > src/index/search10.idx.a + [ -f build/index ] || bin/addfile.sh res/CACHE10.IDX build/TOTAL.DATA > src/index/cache10.idx.a + [ -f build/index ] || bin/addfile.sh build/SEARCH11.IDX build/TOTAL.DATA > src/index/search11.idx.a + [ -f build/index ] || bin/addfile.sh res/CACHE11.IDX build/TOTAL.DATA > src/index/cache11.idx.a + [ -f build/index ] || bin/addfile.sh build/PRELAUNCH.IDX build/TOTAL.DATA > src/index/prelaunch.idx.a + [ -f build/index ] || bin/addfile.sh build/ATTRACT.IDX build/TOTAL.DATA > src/index/attract.idx.a + [ -f build/index ] || bin/addfile.sh build/FX.IDX build/TOTAL.DATA > src/index/fx.idx.a + [ -f build/index ] || bin/addfile.sh build/DFX.IDX build/TOTAL.DATA > src/index/dfx.idx.a + [ -f build/index ] || bin/addfile.sh build/GAMEHELP.IDX build/TOTAL.DATA > src/index/gamehelp.idx.a + [ -f build/index ] || bin/addfile.sh build/SLIDESHOW.IDX build/TOTAL.DATA > src/index/slideshow.idx.a + [ -f build/index ] || bin/addfile.sh build/MINIATTRACT.IDX build/TOTAL.DATA > src/index/miniattract.idx.a + [ -f build/index ] || bin/addfile.sh build/TITLE.IDX build/TOTAL.DATA > src/index/title.idx.a + [ -f build/index ] || bin/addfile.sh build/DTITLE.IDX build/TOTAL.DATA > src/index/dtitle.idx.a + [ -f build/index ] || bin/addfile.sh build/HGR0.IDX build/TOTAL.DATA > src/index/hgr0.idx.a + [ -f build/index ] || bin/addfile.sh build/HGR1.IDX build/TOTAL.DATA > src/index/hgr1.idx.a + [ -f build/index ] || bin/addfile.sh build/HGR2.IDX build/TOTAL.DATA > src/index/hgr2.idx.a + [ -f build/index ] || bin/addfile.sh build/HGR3.IDX build/TOTAL.DATA > src/index/hgr3.idx.a + [ -f build/index ] || bin/addfile.sh build/HGR4.IDX build/TOTAL.DATA > src/index/hgr4.idx.a + [ -f build/index ] || bin/addfile.sh build/HGR5.IDX build/TOTAL.DATA > src/index/hgr5.idx.a + [ -f build/index ] || bin/addfile.sh build/HGR6.IDX build/TOTAL.DATA > src/index/hgr6.idx.a + [ -f build/index ] || bin/addfile.sh build/DHGR.IDX build/TOTAL.DATA > src/index/dhgr.idx.a + [ -f build/index ] || bin/addfile.sh build/GR.IDX build/TOTAL.DATA > src/index/gr.idx.a + [ -f build/index ] || bin/addfile.sh build/ARTWORK.IDX build/TOTAL.DATA > src/index/artwork.idx.a touch build/index asmlauncher: md diff --git a/src/constants.a b/src/constants.a index d2eeaa6f8..f6d8a7957 100644 --- a/src/constants.a +++ b/src/constants.a @@ -11,7 +11,7 @@ ; ...unused... ; E000..E3FF - HGR font data ; ...unused... -; E841..FFEE - main program code +; E893..FFEE - main program code ; FFEF..FFF9 - API functions and global constants available for main program ; code, prelaunchers, transition effects, &c. ; (LoadFileDirect, Wait/UnwaitForVBL, MockingboardStuff, MachineStatus) @@ -201,7 +201,7 @@ PRELAUNCH_STANDARD_SIZE = 61 ; LoadStandardPrelaunch, eventually to be d iCurBlockLo = $D601 ; constant iCurBlockHi = $D603 ; constant launchpatch = $D853 ; glue.launch.a -iAddToPath = $FEB0 ; Roger Rabbit, avoid, use Infiltrator 2 style instead +iAddToPath = $FEBA ; Roger Rabbit, avoid, use Infiltrator 2 style instead itraverse = $DB31 ; Roger Rabbit, avoid, use Infiltrator 2 style instead ldrlo = $55 ; constant ldrhi = $56 ; constant diff --git a/src/glue.launch.a b/src/glue.launch.a index ddabc4942..532cfc301 100644 --- a/src/glue.launch.a +++ b/src/glue.launch.a @@ -128,7 +128,6 @@ PlayGameInAY ; (clobbers $106, must do now before loading prelaunch code) jsr LoadIndexedFile ; load prelaunch index file - !word kTotalIndexFile - !word gSearchCache !word kPrelaunchIndexRecord @@ -138,7 +137,6 @@ PlayGameInAY +ST16 @indexRecordPtr jsr LoadIndexedFile - !word kTotalDataFile !word $0106 @indexRecordPtr !word $FDFD ; SMC @@ -213,7 +211,6 @@ Joystick LoadStandardPrelaunch jsr LoadIndexedFile ; load standard prelaunch code at $0106 - !word kTotalDataFile !word $0106 !word + rts diff --git a/src/glue.prorwts2.a b/src/glue.prorwts2.a index f143436a2..aea0b3484 100644 --- a/src/glue.prorwts2.a +++ b/src/glue.prorwts2.a @@ -100,10 +100,9 @@ LoadAuxFile ; record within the index. Most callers use okvs_find() for this, although some ; have hard-coded records generated at build time. ; -; in: stack contains 6 bytes of parameters: -; +1 [word] pointer to filename of merged data file -; +3 [word] address of load destination -; +5 [word] pointer to index record +; in: stack contains 4 bytes of parameters: +; +1 [word] address of load destination +; +3 [word] pointer to index record ; out: all flags clobbered ; all registers clobbered ;------------------------------------------------------------------------------ @@ -113,9 +112,9 @@ LoadAuxIndexedFile LoadIndexedFile lda #$8D ; STA sta @iauxreq - +PARAMS_ON_STACK 6 - jsr @set_nameaddr - +LDPARAMPTR 5, zpword + +PARAMS_ON_STACK 4 + +LDPARAMPTR 1, @address + +LDPARAMPTR 3, zpword inc $BF0E ; disable ROM mapping on return jsr SwitchToBank2 jsr resetRoot @@ -155,23 +154,10 @@ LoadIndexedFile dec $BF0E ; re-enable ROM mapping on return jmp SwitchToBank1 -@set_nameaddr - ldx #0 - ldy #1 - jsr + - iny - ldx #@address - @filename -+ lda (PARAM), y - sta @filename, x - iny - lda (PARAM), y - sta @filename + 1, x - rts - @c8_parms !byte 3 @filename - !word $DFDF ; SMC + !word kTotalDataFile !byte 0 @ce_parms !byte $d0 diff --git a/src/index/artwork.idx.a b/src/index/artwork.idx.a index 67fab0437..42de56a29 100644 --- a/src/index/artwork.idx.a +++ b/src/index/artwork.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 111209 + !be24 9882226 !le16 4186 diff --git a/src/index/attract.idx.a b/src/index/attract.idx.a index 4c9a16048..be6b76514 100644 --- a/src/index/attract.idx.a +++ b/src/index/attract.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 64624 + !be24 9835641 !le16 5174 diff --git a/src/index/cache00.idx.a b/src/index/cache00.idx.a index cea3cbdb6..115492067 100644 --- a/src/index/cache00.idx.a +++ b/src/index/cache00.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 8000 + !be24 9779017 !le16 3580 diff --git a/src/index/cache01.idx.a b/src/index/cache01.idx.a index 5eb8a98f4..090ff8eff 100644 --- a/src/index/cache01.idx.a +++ b/src/index/cache01.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 20332 + !be24 9791349 !le16 3940 diff --git a/src/index/cache10.idx.a b/src/index/cache10.idx.a index b82ddb0b2..860acc786 100644 --- a/src/index/cache10.idx.a +++ b/src/index/cache10.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 35693 + !be24 9806710 !le16 4615 diff --git a/src/index/cache11.idx.a b/src/index/cache11.idx.a index 0eb0184a0..6326d7f4a 100644 --- a/src/index/cache11.idx.a +++ b/src/index/cache11.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 52930 + !be24 9823947 !le16 5562 diff --git a/src/index/dfx.idx.a b/src/index/dfx.idx.a index 6ded463b1..7b3ec4f2e 100644 --- a/src/index/dfx.idx.a +++ b/src/index/dfx.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 71944 + !be24 9842961 !le16 1242 diff --git a/src/index/dhgr.idx.a b/src/index/dhgr.idx.a index 5bd4e998e..c3a9757e2 100644 --- a/src/index/dhgr.idx.a +++ b/src/index/dhgr.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 109867 + !be24 9880884 !le16 1249 diff --git a/src/index/dtitle.idx.a b/src/index/dtitle.idx.a index 7e0b9cba8..ae5bd8399 100644 --- a/src/index/dtitle.idx.a +++ b/src/index/dtitle.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 96015 + !be24 9867032 !le16 464 diff --git a/src/index/fx.idx.a b/src/index/fx.idx.a index a6a7bce53..349e39844 100644 --- a/src/index/fx.idx.a +++ b/src/index/fx.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 69798 + !be24 9840815 !le16 2146 diff --git a/src/index/gamehelp.idx.a b/src/index/gamehelp.idx.a index 5b4b536b7..7a3dc5224 100644 --- a/src/index/gamehelp.idx.a +++ b/src/index/gamehelp.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 73186 + !be24 9844203 !le16 6132 diff --git a/src/index/gr.idx.a b/src/index/gr.idx.a index 57dac9f4d..48ce96f5f 100644 --- a/src/index/gr.idx.a +++ b/src/index/gr.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 111116 + !be24 9882133 !le16 93 diff --git a/src/index/hgr0.idx.a b/src/index/hgr0.idx.a index bfdc4f67b..8312ecd5f 100644 --- a/src/index/hgr0.idx.a +++ b/src/index/hgr0.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 96479 + !be24 9867496 !le16 4364 diff --git a/src/index/hgr1.idx.a b/src/index/hgr1.idx.a index 4d2d5a71b..d97fab544 100644 --- a/src/index/hgr1.idx.a +++ b/src/index/hgr1.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 100843 + !be24 9871860 !le16 1516 diff --git a/src/index/hgr2.idx.a b/src/index/hgr2.idx.a index a8013330c..fdc144965 100644 --- a/src/index/hgr2.idx.a +++ b/src/index/hgr2.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 102359 + !be24 9873376 !le16 1031 diff --git a/src/index/hgr3.idx.a b/src/index/hgr3.idx.a index cf6bc0b83..316548654 100644 --- a/src/index/hgr3.idx.a +++ b/src/index/hgr3.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 103390 + !be24 9874407 !le16 3237 diff --git a/src/index/hgr4.idx.a b/src/index/hgr4.idx.a index ed8e3f73d..6e1d46bca 100644 --- a/src/index/hgr4.idx.a +++ b/src/index/hgr4.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 106627 + !be24 9877644 !le16 2694 diff --git a/src/index/hgr5.idx.a b/src/index/hgr5.idx.a index 01dc195f9..4c1835364 100644 --- a/src/index/hgr5.idx.a +++ b/src/index/hgr5.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 109321 + !be24 9880338 !le16 441 diff --git a/src/index/hgr6.idx.a b/src/index/hgr6.idx.a index 4a1260a16..2638d0852 100644 --- a/src/index/hgr6.idx.a +++ b/src/index/hgr6.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 109762 + !be24 9880779 !le16 105 diff --git a/src/index/miniattract.idx.a b/src/index/miniattract.idx.a index 17f4f6e55..231ecc3f8 100644 --- a/src/index/miniattract.idx.a +++ b/src/index/miniattract.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 84154 + !be24 9855171 !le16 6132 diff --git a/src/index/prelaunch.idx.a b/src/index/prelaunch.idx.a index 3d1260448..d16e79260 100644 --- a/src/index/prelaunch.idx.a +++ b/src/index/prelaunch.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 58492 + !be24 9829509 !le16 6132 diff --git a/src/index/search00.idx.a b/src/index/search00.idx.a index 03a53b0a5..aadf38f6e 100644 --- a/src/index/search00.idx.a +++ b/src/index/search00.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 0 + !be24 9771017 !le16 8000 diff --git a/src/index/search01.idx.a b/src/index/search01.idx.a index 26e7cf5f4..560581952 100644 --- a/src/index/search01.idx.a +++ b/src/index/search01.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 11580 + !be24 9782597 !le16 8752 diff --git a/src/index/search10.idx.a b/src/index/search10.idx.a index 779c0a320..0fd1b5c5e 100644 --- a/src/index/search10.idx.a +++ b/src/index/search10.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 24272 + !be24 9795289 !le16 11421 diff --git a/src/index/search11.idx.a b/src/index/search11.idx.a index 811f84931..49546a742 100644 --- a/src/index/search11.idx.a +++ b/src/index/search11.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 40308 + !be24 9811325 !le16 12622 diff --git a/src/index/slideshow.idx.a b/src/index/slideshow.idx.a index 40c2ffbd7..60d57c19c 100644 --- a/src/index/slideshow.idx.a +++ b/src/index/slideshow.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 79318 + !be24 9850335 !le16 4836 diff --git a/src/index/title.idx.a b/src/index/title.idx.a index 9f2bed0f5..e0341f772 100644 --- a/src/index/title.idx.a +++ b/src/index/title.idx.a @@ -4,5 +4,5 @@ ; This file is automatically generated ; !byte 0 - !be24 90286 + !be24 9861303 !le16 5729 diff --git a/src/prodos.path.a b/src/prodos.path.a index 6db216ef8..ec45dc2d0 100644 --- a/src/prodos.path.a +++ b/src/prodos.path.a @@ -134,10 +134,6 @@ kTotalDataFile !byte 10 !raw "TOTAL.DATA" -kTotalIndexFile - !byte 9 - !raw "TOTAL.IDX" - kAnimatedTitleDirectory !byte 15 !raw "TITLE.ANIMATED/" diff --git a/src/textrank.a b/src/textrank.a index 94df80595..f510bf3fc 100644 --- a/src/textrank.a +++ b/src/textrank.a @@ -28,18 +28,16 @@ InputBuffer ;------------------------------------------------------------------------------ ; ReloadSearchIndex ; -; Load index to support search UI +; Load indexes to support search UI ; ; in: none ; out: gSearchStore populated ;------------------------------------------------------------------------------ ReloadSearchIndex jsr LoadIndexedFile ; load appropriate search index into $8200 - !word kTotalIndexFile !word gSearchIndex !word kSearchIndexRecord jsr LoadIndexedFile ; load appropriate search cache into $B000 - !word kTotalIndexFile !word gSearchCache !word kSearchCacheRecord rts diff --git a/src/ui.attract.dhgr.a b/src/ui.attract.dhgr.a index 7b1baf42c..cd19de7b9 100644 --- a/src/ui.attract.dhgr.a +++ b/src/ui.attract.dhgr.a @@ -134,7 +134,6 @@ gMachineInDHGRMode=*+1 ;------------------------------------------------------------------------------ LoadDHGRTransition jsr LoadIndexedFile ; load DHGR transition effects list into $6000 - !word kTotalIndexFile - !word $6000 !word kDFXIndexRecord @@ -152,7 +151,6 @@ LoadDHGRTransition + !word $FDFD ; SMC jsr LoadIndexedFile - !word kTotalDataFile !word $6000 @indexRecordPtr !word $FDFD ; SMC @@ -187,7 +185,6 @@ DHGRTitleCallback +ST16 gGameToLaunch ; while it's visible (we'll launch it) jsr LoadIndexedFile ; load index file into $4000 - !word kTotalIndexFile - !word $4000 !word kDHGRTitleIndexRecord @@ -332,7 +329,6 @@ LoadIndexedDHGRFile ; in: caller has set IndexedDHGRFilename ; out: all flags & registers clobbered jsr LoadIndexedFile ; load index file into $4000 - !word kTotalIndexFile - !word $4000 !word kDHGRActionIndexRecord @@ -343,7 +339,6 @@ IndexedDHGRFilename +ST16 @indexRecordPtr jsr LoadAuxIndexedFile ; load compressed DHGR screenshot at aux $3FF8 - !word kTotalDataFile !word $3FF8 @indexRecordPtr !word $FDFD ; SMC diff --git a/src/ui.attract.gr.a b/src/ui.attract.gr.a index 507cb310d..f08ce7574 100644 --- a/src/ui.attract.gr.a +++ b/src/ui.attract.gr.a @@ -104,7 +104,6 @@ LoadIndexedGRFile ; in: caller has set IndexedGRFilename ; out: all flags & registers clobbered jsr LoadIndexedFile ; load index file into $4600 - !word kTotalIndexFile - !word $4600 !word kGRActionIndexRecord @@ -115,8 +114,7 @@ IndexedGRFilename +ST16 @indexRecordPtr jsr LoadIndexedFile ; load GR screenshot at $4000 - !word kTotalDataFile ; because that's where the transition code expects to find it - !word $4000 + !word $4000 ; because that's where the transition code expects to find it @indexRecordPtr !word $FDFD ; SMC rts diff --git a/src/ui.attract.hgr.a b/src/ui.attract.hgr.a index 74bacd997..32ac544c4 100644 --- a/src/ui.attract.hgr.a +++ b/src/ui.attract.hgr.a @@ -65,7 +65,6 @@ HGRSingle ;------------------------------------------------------------------------------ LoadHGRTransition jsr LoadIndexedFile ; load HGR transition effects list into $6000 - !word kTotalIndexFile - !word $6000 !word kFXIndexRecord @@ -83,7 +82,6 @@ LoadHGRTransition + !word $FDFD ; SMC jsr LoadIndexedFile - !word kTotalDataFile !word $6000 @indexRecordPtr !word $FDFD ; SMC @@ -117,7 +115,6 @@ HGRTitleCallback +ST16 gGameToLaunch ; while it's visible (we'll launch it) jsr LoadIndexedFile ; load index file into $4000 - !word kTotalIndexFile - !word $4000 !word kHGRTitleIndexRecord @@ -127,7 +124,6 @@ HGRTitleCallback +ST16 @indexRecordPtr jsr LoadIndexedFile ; load HGR graphic at $4000 - !word kTotalDataFile !word $4000 @indexRecordPtr !word $FDFD ; SMC @@ -180,7 +176,6 @@ LoadIndexedHGRFile sta HGRActionIndexRecord+1 jsr LoadIndexedFile ; load index file into $4000 - !word kTotalIndexFile HGRActionIndexPtr !word $4000 HGRActionIndexRecord @@ -193,7 +188,6 @@ IndexedHGRFilename +ST16 @indexRecordPtr jsr LoadIndexedFile ; load compressed HGR screenshot at $3FF8 - !word kTotalDataFile !word $3FF8 @indexRecordPtr !word $FDFD ; SMC diff --git a/src/ui.attract.mode.a b/src/ui.attract.mode.a index 93d3b57e2..f1649303a 100644 --- a/src/ui.attract.mode.a +++ b/src/ui.attract.mode.a @@ -25,7 +25,6 @@ MegaAttractMode jsr BlankHGR ; switch to HGR page 1 (once cleared) jsr LoadIndexedFile ; load pre-parsed attract mode configuration data into $6000 - !word kTotalIndexFile - !word $6000 !word kAttractModeIndexRecord @@ -71,7 +70,6 @@ MiniAttractMode jsr GetGameToLaunch +ST16 + jsr LoadIndexedFile - !word kTotalIndexFile - !word $0800 !word kMiniAttractIndexRecord jsr okvs_find @@ -92,7 +90,6 @@ MiniAttractMode stx @MiniAttractIndex+3 @loop jsr LoadIndexedFile - !word kTotalDataFile - !word $6000 !word OKVS_CACHE @@ -184,7 +181,6 @@ RunAttractModule ; it's a slideshow, so load slideshow configuration file pha ; save module type jsr LoadIndexedFile ; load slideshow configuration file into $4000 - !word kTotalIndexFile - !word $4000 !word kAttractModeSlideshowIndexRecord jsr okvs_find @@ -192,7 +188,6 @@ RunAttractModule @key2 !word $FDFD ; SMC +ST16 + jsr LoadIndexedFile - !word kTotalDataFile !word $800 + !word $FDFD ; SMC pla ; restore module type diff --git a/src/ui.attract.shr.a b/src/ui.attract.shr.a index 3944db3c5..d9a611b32 100644 --- a/src/ui.attract.shr.a +++ b/src/ui.attract.shr.a @@ -102,7 +102,6 @@ LoadIndexedSHRFile ; in: caller has populated IndexedSHRFilename ; out: all flags & registers clobbered jsr LoadIndexedFile ; load index file into $2000 - !word kTotalIndexFile - !word $2000 !word kSHRArtworkIndexRecord @@ -113,7 +112,6 @@ IndexedSHRFilename +ST16 @indexRecordPtr jsr LoadIndexedFile ; load compressed SHR artwork at $1FF8/main (not aux) - !word kTotalDataFile !word $1FF8 @indexRecordPtr !word $FDFD ; SMC diff --git a/src/ui.credits.a b/src/ui.credits.a index 9a4882a7f..c67ec6c57 100644 --- a/src/ui.credits.a +++ b/src/ui.credits.a @@ -21,7 +21,6 @@ Help +ST16 @game jsr LoadIndexedFile - !word kTotalIndexFile @okvsPtr !word gSearchCache !word kGameHelpIndexRecord @@ -31,7 +30,6 @@ Help +ST16 @indexRecordPtr jsr LoadIndexedFile - !word kTotalDataFile !word $800 @indexRecordPtr !word $FDFD ; SMC diff --git a/src/ui.offscreen.a b/src/ui.offscreen.a index 88f178f4f..d41ad3c02 100644 --- a/src/ui.offscreen.a +++ b/src/ui.offscreen.a @@ -111,7 +111,6 @@ LoadIndexedDHRFile sta @dhgr_addr_aux + 1 sta @dhgr_addr_main + 1 jsr LoadAuxIndexedFile - !word kTotalDataFile @dhgr_addr_aux !word $FD00 ; SMC high byte !word OKVS_CACHE @@ -123,7 +122,6 @@ LoadIndexedDHRFile bcc + inc OKVS_CACHE + 1 + jsr LoadIndexedFile ; load next $2000 bytes into main memory - !word kTotalDataFile @dhgr_addr_main !word $FD00 ; SMC high byte !word OKVS_CACHE @@ -140,7 +138,6 @@ LoadIndexedDHRFile +LD16 PTR +ST16 @hgrIndexRecordPtr jsr LoadIndexedFile - !word kTotalDataFile @hgr_addr !word $FD00 ; SMC high byte @hgrIndexRecordPtr