diff --git a/src/4cade.branding.a b/src/4cade.branding.a new file mode 100644 index 0000000..49ef7bb --- /dev/null +++ b/src/4cade.branding.a @@ -0,0 +1,43 @@ +;license:MIT +;(c) 2018-2023 by 4am +; + +PrintBranding + ldy #14 +- lda II,y + ora #$80 + +FORCE_UPPERCASE_IF_REQUIRED + sta $070C,y + dey + bpl - + ldy #12 +- lda INSTANT,y + ora #$80 + sta $04B5,y + dey + bpl - + ldy #10 +- lda REPLAY,y + ora #$80 + sta $0536,y + dey + bpl - + rts + +II + !text "Total Replay II" +INSTANT + !text "I N S T A N T" +REPLAY + !text "R E P L A Y" +!ifndef RELEASE { +LoadingVersion + !byte 9 + !text " build 0" +LoadingBuild + !word BUILDNUMBER +} else { +LoadingVersion + !byte 12 + !text "v1.0-alpha.1" +} diff --git a/src/4cade.init.a b/src/4cade.init.a index 5c12fc6..0f6543f 100644 --- a/src/4cade.init.a +++ b/src/4cade.init.a @@ -1,5 +1,5 @@ ;license:MIT -;(c) 2018-2020 by 4am +;(c) 2018-2023 by 4am ; ; first-run initialization code ; @@ -19,7 +19,7 @@ jsr ROM_IN0 jsr ROM_PR0 - ; accommodate uppercase-only machines (64K ][+ is supported) + ; accommodate uppercase-only machines (64K ][ and ][+ are supported) lda ROM_MACHINEID cmp #$A0 beq + ; Spectrum ED @@ -31,25 +31,7 @@ sta zpCharMask ; print text title in same place as graphical title will appear - ldy #14 -- lda II,y - ora #$80 - +FORCE_UPPERCASE_IF_REQUIRED - sta $070C,y - dey - bpl - - ldy #12 -- lda INSTANT,y - ora #$80 - sta $04B5,y - dey - bpl - - ldy #10 -- lda REPLAY,y - ora #$80 - sta $0536,y - dey - bpl - + jsr PrintBranding ; proboothd duplicates the above code and jumps here, ; so if you make any changes before this comment, you @@ -165,7 +147,6 @@ lda zpMachineStatus and #HAS_JOYSTICK beq + - jsr LoadingCR +LDADDR LoadingJoystick jsr LoadingPrint + @@ -173,7 +154,6 @@ lda zpMachineStatus and #HAS_VIDHD beq + - jsr LoadingCR +LDADDR LoadingVidHD jsr LoadingPrint + @@ -243,11 +223,21 @@ stx MockingboardStuff ; save mockingboard slot and type in LC RAM +READ_ROM_NO_WRITE + txa + beq + + and #HAS_STEREO + beq @mb_mono + +LDADDR LoadingMockingboardStereo + bne @mb_print +@mb_mono + +LDADDR LoadingMockingboardStereo +@mb_print + jsr LoadingPrint + ; if Mockingboard AND HAS_SPEECH then print CR & '...and it talks!' txa and #HAS_SPEECH beq + - jsr LoadingCR +LDADDR LoadingMockingboardSpeech jsr LoadingPrint @@ -288,13 +278,8 @@ LoadingPrint bne - rts -LoadingCR - lda #$8D - jmp ROM_COUT - FoundMockingboardCallback ; in: zp$81 contains slot number in form $Cx - jsr LoadingCR +LDADDR LoadingMockingboard jsr LoadingPrint lda $81 @@ -302,23 +287,8 @@ FoundMockingboardCallback ora #$B0 jmp ROM_COUT -II - !text "Total Replay II" -INSTANT - !text "I N S T A N T" -REPLAY - !text "R E P L A Y" -!ifndef RELEASE { -LoadingVersion - !byte 9 - !text " build 0" -LoadingBuild - !word BUILDNUMBER -} else { -LoadingVersion - !byte 12 - !text "v1.0-alpha.1" -} + !src "src/4cade.branding.a" + Loading64K !byte 3 !text "64K" @@ -329,14 +299,20 @@ LoadingIIgs !byte 4 !text "IIgs" LoadingJoystick - !byte 8 - !text "joystick" + !byte 9 + !text $8D,"joystick" LoadingVidHD - !byte 5 - !text "VidHD" + !byte 6 + !text $8D,"VidHD" LoadingMockingboard - !byte 21 - !text "Mockingboard in slot " + !byte 22 + !text $8D,"Mockingboard in slot " +LoadingMockingboardStereo + !byte 7 + !text $8D,"Stereo" +LoadingMockingboardMono + !byte 5 + !text $8D,"Mono" LoadingMockingboardSpeech !byte 16 !text "...and it talks!" diff --git a/src/constants.a b/src/constants.a index d13615c..02346d0 100644 --- a/src/constants.a +++ b/src/constants.a @@ -1,5 +1,5 @@ ;license:MIT -;(c) 2018-2022 by 4am +;(c) 2018-2023 by 4am ; ;------------------------------------------------------------------------------ @@ -11,7 +11,7 @@ ; ...unused... ; E000..E3FF - HGR font data ; ...unused... -; E730..FFEB - main program code +; E6C9..FFEB - main program code ; FFEC..FFF9 - API functions and global constants available for main program ; code, prelaunchers, transition effects, &c. ; (LoadFileDirect, Wait/UnwaitForVBL, MockingboardStuff, MachineStatus) @@ -110,6 +110,7 @@ ROM_MACHINEID =$FBB3 ROM_MACHINE2C =$FBC0 ROM_HOME = $FC58 ROM_WAIT = $FCA8 +ROM_CROUT= $FD8E ROM_COUT = $FDED ROM_NORMAL = $FE84 ; NORMAL text (instead of INVERSE or FLASH) ROM_IN0 = $FE89 ; SETKBD @@ -188,8 +189,8 @@ EnableAccelerator = DisableAccelerator+3 ; AND masks for MockingboardStuff MOCKINGBOARD_SLOT = %00001111 +HAS_STEREO = %00100000 HAS_SPEECH = %11000000 -MOCKINGBOARD_NEW = %00100000 ; AND masks for game info bitfield (after game display name in gSearchStore) HAS_DHGR_TITLE = %10000000 ; this one is hard-coded via BMI instead of AND/BNE diff --git a/src/hw.mockingboard.a b/src/hw.mockingboard.a index 0db8b99..642ee46 100644 --- a/src/hw.mockingboard.a +++ b/src/hw.mockingboard.a @@ -1,5 +1,5 @@ ;license:MIT -;(c) 2019-2020 by Andrew Roughan, qkumba, 4am, Tom Charlesworth, Rob Justice +;(c) 2019-2022 by Andrew Roughan, qkumba, 4am, Tom Charlesworth, Rob Justice ; ; Mockingboard support functions ; diff --git a/src/prelaunch/black.belt.mb.a b/src/prelaunch/black.belt.mb.a index 4998b81..f907674 100644 --- a/src/prelaunch/black.belt.mb.a +++ b/src/prelaunch/black.belt.mb.a @@ -30,7 +30,7 @@ lda #0 ; SMC pla pha - and #MOCKINGBOARD_NEW + and #HAS_STEREO bne .newmock jsr $BC07 ; decompress old Mockingboard support .newmock diff --git a/src/proboothd/proboothd.a b/src/proboothd/proboothd.a index af47dc3..6dd2c48 100644 --- a/src/proboothd/proboothd.a +++ b/src/proboothd/proboothd.a @@ -164,7 +164,7 @@ blockind ldy $ff txa bne readfile -readdone jmp $2060 +readdone jmp $2036 seekread stx bloklo sty blokhi