mirror of
https://github.com/Pecusx/scorch_src.git
synced 2026-05-20 22:33:43 +02:00
WIP: 5200 runs on a800 (fire to skip menu)
This commit is contained in:
@@ -624,20 +624,20 @@ SetPokey
|
|||||||
|
|
||||||
lda trackn_audf+0
|
lda trackn_audf+0
|
||||||
ldx trackn_audc+0
|
ldx trackn_audc+0
|
||||||
sta $d200
|
sta AUDF1
|
||||||
stx $d201
|
stx AUDC1
|
||||||
lda trackn_audf+1
|
lda trackn_audf+1
|
||||||
ldx trackn_audc+1
|
ldx trackn_audc+1
|
||||||
sta $d200+2
|
sta AUDF2
|
||||||
stx $d201+2
|
stx AUDC2
|
||||||
lda trackn_audf+2
|
lda trackn_audf+2
|
||||||
ldx trackn_audc+2
|
ldx trackn_audc+2
|
||||||
sta $d200+4
|
sta AUDF3
|
||||||
stx $d201+4
|
stx AUDC3
|
||||||
lda trackn_audf+3
|
lda trackn_audf+3
|
||||||
ldx trackn_audc+3
|
ldx trackn_audc+3
|
||||||
sta $d200+6
|
sta AUDF4
|
||||||
stx $d201+6
|
stx AUDC4
|
||||||
sty $d208
|
sty AUDCTL
|
||||||
rts
|
rts
|
||||||
RMTPLAYEREND
|
RMTPLAYEREND
|
||||||
|
|||||||
+3
-3
@@ -1,6 +1,6 @@
|
|||||||
.proc talk
|
.proc talk
|
||||||
; Maximum text length is 63 characters!!!
|
; Maximum text length is 63 characters!!!
|
||||||
L0 dta d"CTO XYEB"
|
L0 dta d"CYKA BLAT"
|
||||||
L1 dta d"DIE!"
|
L1 dta d"DIE!"
|
||||||
L2 dta d"EAT MY SHORTS!"
|
L2 dta d"EAT MY SHORTS!"
|
||||||
L3 dta d"YOU'RE TOAST!"
|
L3 dta d"YOU'RE TOAST!"
|
||||||
@@ -47,7 +47,7 @@ L43 dta d"THIS IS YOUR BRAIN ON SCORCH."
|
|||||||
L44 dta d"TAKE THIS!"
|
L44 dta d"TAKE THIS!"
|
||||||
L45 dta d"THIS SCREEN AIN'T BIG ENOUGH FOR THE BOTH OF US."
|
L45 dta d"THIS SCREEN AIN'T BIG ENOUGH FOR THE BOTH OF US."
|
||||||
L46 dta d"DIE, ALIEN SWINE!"
|
L46 dta d"DIE, ALIEN SWINE!"
|
||||||
L47 dta d"SAY ARRGGHHHHH...."
|
L47 dta d"AWRUK!!!"
|
||||||
L48 dta d"I SHALL OIL MY TURRET WITH YOUR BLOOD."
|
L48 dta d"I SHALL OIL MY TURRET WITH YOUR BLOOD."
|
||||||
L49 dta d"DIE, TANK-SCUM!"
|
L49 dta d"DIE, TANK-SCUM!"
|
||||||
L50 dta d"I'M GONNA BREAK YOUR FACE!"
|
L50 dta d"I'M GONNA BREAK YOUR FACE!"
|
||||||
@@ -104,7 +104,7 @@ L99 dta d"JOIN THE ARMY, SEE THE WORLD THEY SAID."
|
|||||||
L100 dta d"IT WASN'T JUST A JOB IT WAS AN ADVENTURE!"
|
L100 dta d"IT WASN'T JUST A JOB IT WAS AN ADVENTURE!"
|
||||||
L101 dta d"I DIDN'T LIKE VIOLENCE ANYWAY!"
|
L101 dta d"I DIDN'T LIKE VIOLENCE ANYWAY!"
|
||||||
L102 dta d"I THOUGHT YOU LIKED ME?"
|
L102 dta d"I THOUGHT YOU LIKED ME?"
|
||||||
L103 dta d"SUCH SENSELESS VIOLENCE! I DON'T UNDERSTAND IT."
|
L103 dta d"CTO XYEB"
|
||||||
L104 dta d"I THINK THIS GUY'S A LITTLE CRAZY."
|
L104 dta d"I THINK THIS GUY'S A LITTLE CRAZY."
|
||||||
L105 dta d"SOMEHOW I DON'T FEEL LIKE KILLING ANYMORE."
|
L105 dta d"SOMEHOW I DON'T FEEL LIKE KILLING ANYMORE."
|
||||||
L106 dta d"HEY! KILLIN' AIN'T COOL."
|
L106 dta d"HEY! KILLIN' AIN'T COOL."
|
||||||
|
|||||||
+2
-1
@@ -45,7 +45,8 @@
|
|||||||
@ lda vcount
|
@ lda vcount
|
||||||
bne @-
|
bne @-
|
||||||
mwa #:1 VVBLKD
|
mwa #:1 VVBLKD
|
||||||
lda #$40 ;Enable IRQ interrupts
|
mva #$40 nmien
|
||||||
|
;Enable IRQ interrupts
|
||||||
sta pokmsk
|
sta pokmsk
|
||||||
sta irqen
|
sta irqen
|
||||||
cli
|
cli
|
||||||
|
|||||||
+5
-6
@@ -11,8 +11,8 @@ POKMSK = $00 ;pokmsk at $00 on Atari 5200 instead of $10 on Atari
|
|||||||
RTCLOK = $01 ;Actually $01/$02
|
RTCLOK = $01 ;Actually $01/$02
|
||||||
CRITIC = $03
|
CRITIC = $03
|
||||||
ATRACT = $04 ;attact at $04 on Atari 5200 instead of $4D on Atari XL
|
ATRACT = $04 ;attact at $04 on Atari 5200 instead of $4D on Atari XL
|
||||||
DLPTRS = $05 ;sdlstl at $05/$06 on Atari 5200 instead of $230 on Atari XL
|
DLPTRS = $05 ;DLPTRS at $05/$06 on Atari 5200 instead of $230 on Atari XL
|
||||||
DMACTLS = $07 ;sdmactl at $07 on Atari 5200 instead of $22f on Atari XL
|
DMACTLS = $07 ;DMACTLS at $07 on Atari 5200 instead of $22f on Atari XL
|
||||||
SSKCTL = skctl ;There is no shadow on Atari 5200
|
SSKCTL = skctl ;There is no shadow on Atari 5200
|
||||||
PCOLR0 EQU $08 ;P0 COLOR
|
PCOLR0 EQU $08 ;P0 COLOR
|
||||||
PCOLR1 EQU $09 ;P1 COLOR
|
PCOLR1 EQU $09 ;P1 COLOR
|
||||||
@@ -34,7 +34,9 @@ PADDL6 EQU $17
|
|||||||
PADDL7 EQU $18
|
PADDL7 EQU $18
|
||||||
STICK0 = $19 ;There is no stick0 but we will make the analog stick look like a digital one and store it here
|
STICK0 = $19 ;There is no stick0 but we will make the analog stick look like a digital one and store it here
|
||||||
STRIG0 = $1a ;There is no strig0 but we will make this the shadow of the TRIG0 ($c010) of GTIA
|
STRIG0 = $1a ;There is no strig0 but we will make this the shadow of the TRIG0 ($c010) of GTIA
|
||||||
chbas = $1b ;There is no strig0 but we will make this the shadow of the CHBASE
|
chbas = $1b ;There is no CHBAS but we will make this the shadow of the CHBASE
|
||||||
|
CONSOL = $1c ;There are no console keys on Atari 5200, so we replace console h/w reads with a new shadow based on the keypad keys
|
||||||
|
consol_reset = $07;The constant value representing that no consol key is pressed
|
||||||
|
|
||||||
; PAGE 2
|
; PAGE 2
|
||||||
VIMIRQ EQU $0200 ;IMMED IRQ VECTOR
|
VIMIRQ EQU $0200 ;IMMED IRQ VECTOR
|
||||||
@@ -57,9 +59,6 @@ ROM_SETTINGS = $bfe8 ; game ROM info start (24 bytes total, 20b title, 2b year,
|
|||||||
|
|
||||||
; HARDWARE REGISTERS
|
; HARDWARE REGISTERS
|
||||||
|
|
||||||
; GTIA
|
|
||||||
CONSOL = $280 ;There are no console keys on Atari 5200, so we replace console h/w reads with a new shadow based on the keypad keys
|
|
||||||
consol_reset = $07 ;The constant value representing that no consol key is pressed
|
|
||||||
; ---------------------------------------------------------------------------
|
; ---------------------------------------------------------------------------
|
||||||
POKEY EQU $EB00
|
POKEY EQU $EB00
|
||||||
; ---------------------------------------------------------------------------
|
; ---------------------------------------------------------------------------
|
||||||
|
|||||||
+45
-38
@@ -6,7 +6,7 @@
|
|||||||
;Miami & Warsaw 2022
|
;Miami & Warsaw 2022
|
||||||
|
|
||||||
;---------------------------------------------------
|
;---------------------------------------------------
|
||||||
.def target = 800 ;5200 ; or 800
|
.def TARGET = 800; 5200 ; or 800
|
||||||
;---------------------------------------------------
|
;---------------------------------------------------
|
||||||
|
|
||||||
OPT r+ ; saves 12 bytes :O
|
OPT r+ ; saves 12 bytes :O
|
||||||
@@ -222,9 +222,11 @@ FirstSTART
|
|||||||
lda #$ff ;initial value
|
lda #$ff ;initial value
|
||||||
sta sfx_effect
|
sta sfx_effect
|
||||||
|
|
||||||
lda #0
|
RMTSong 0
|
||||||
jsr RmtSongSelect
|
|
||||||
|
|
||||||
|
.IF TARGET = 5200
|
||||||
|
mva #$0f STICK0
|
||||||
|
.ENDIF
|
||||||
VMAIN VBLinterrupt,7 ;jsr SetVBL
|
VMAIN VBLinterrupt,7 ;jsr SetVBL
|
||||||
|
|
||||||
START
|
START
|
||||||
@@ -1104,8 +1106,9 @@ MakeTanksVisible
|
|||||||
ldy dliCounter
|
ldy dliCounter
|
||||||
lda dliColorsBack,y
|
lda dliColorsBack,y
|
||||||
ldy dliColorsFore
|
ldy dliColorsFore
|
||||||
nop
|
.IF TARGET = 800
|
||||||
nop
|
nop ; necessary on 800 because DLIs take less time, jitter visible without it
|
||||||
|
.ENDIF
|
||||||
nop
|
nop
|
||||||
sta COLPF1
|
sta COLPF1
|
||||||
sty COLPF2
|
sty COLPF2
|
||||||
@@ -1152,7 +1155,7 @@ ColoredLines
|
|||||||
cmp #9
|
cmp #9
|
||||||
beq CreditsScroll
|
beq CreditsScroll
|
||||||
tay
|
tay
|
||||||
lda GameOverColoursTable-3,y ; -2 becouse this is DLI nr 2 and -1 (labels line)
|
lda GameOverColoursTable-3,y ; -2 because this is DLI nr 2 and -1 (labels line)
|
||||||
ldy #$0a ; text colour (brightnes)
|
ldy #$0a ; text colour (brightnes)
|
||||||
STA WSYNC
|
STA WSYNC
|
||||||
sta COLPF2
|
sta COLPF2
|
||||||
@@ -1186,8 +1189,9 @@ EndOfDLI_GO
|
|||||||
.proc DLIinterruptText
|
.proc DLIinterruptText
|
||||||
;sta dliA
|
;sta dliA
|
||||||
pha
|
pha
|
||||||
|
lda #TextBackgroundColor
|
||||||
sta WSYNC
|
sta WSYNC
|
||||||
mva #TextBackgroundColor COLPF2
|
sta COLPF2
|
||||||
mva #TextForegroundColor COLPF3
|
mva #TextForegroundColor COLPF3
|
||||||
;lda dliA
|
;lda dliA
|
||||||
pla
|
pla
|
||||||
@@ -1231,32 +1235,35 @@ lab2
|
|||||||
; ------- RMT -------
|
; ------- RMT -------
|
||||||
SkipRMTVBL
|
SkipRMTVBL
|
||||||
exitVBL
|
exitVBL
|
||||||
.IF target = 5200
|
.IF TARGET = 5200
|
||||||
; center = 114 ;Read analog stick and make it look like a digital stick
|
center = 114 ;Read analog stick and make it look like a digital stick
|
||||||
; threshold = 60
|
threshold = 60
|
||||||
;
|
|
||||||
; lda pot0 ;Read POT0 value (horizontal position)
|
lda paddl0 ;Read POT0 value (horizontal position)
|
||||||
; cmp #center+threshold ;Compare with right threshold
|
cmp #center+threshold ;Compare with right threshold
|
||||||
; rol stick0 ;Feed carry into digital stick value
|
rol stick0 ;Feed carry into digital stick value
|
||||||
; cmp #center-threshold ;Compare with left threshold
|
cmp #center-threshold ;Compare with left threshold
|
||||||
; rol stick0 ;Feed carry into digital stick value
|
rol stick0 ;Feed carry into digital stick value
|
||||||
;
|
|
||||||
; lda pot1 ;Read POT1 value (vertical position)
|
lda paddl1 ;Read POT1 value (vertical position)
|
||||||
; cmp #center+threshold ;Compare with down threshold
|
cmp #center+threshold ;Compare with down threshold
|
||||||
; rol stick0 ;Feed carry into digital stick value
|
rol stick0 ;Feed carry into digital stick value
|
||||||
; cmp #center-threshold ;Compare with down threshold
|
cmp #center-threshold ;Compare with down threshold
|
||||||
; rol stick0 ;Feed carry into digital stick value
|
rol stick0 ;Feed carry into digital stick value
|
||||||
;
|
|
||||||
; lda stick0 ;0 indicates a press so the right/down values need to be inverted
|
lda stick0 ;0 indicates a press so the right/down values need to be inverted
|
||||||
; eor #2+8
|
eor #2+8
|
||||||
; and #$0f
|
and #$0f
|
||||||
; sta stick0
|
sta stick0
|
||||||
;
|
|
||||||
; mva trig0 strig0 ;Move hardware to shadow
|
mva trig0 strig0 ;Move hardware to shadow
|
||||||
;
|
|
||||||
; lda skstat ;Reset consol key shadow is no key is pressed anymore
|
mva chbas chbase
|
||||||
; and #4
|
|
||||||
; seq:mva #consol_reset consol
|
lda skstat ;Reset consol key shadow is no key is pressed anymore
|
||||||
|
and #4
|
||||||
|
seq:mva #consol_reset consol
|
||||||
|
|
||||||
pla
|
pla
|
||||||
tay
|
tay
|
||||||
pla
|
pla
|
||||||
@@ -1536,6 +1543,7 @@ SetRandomWalls
|
|||||||
;--------------------------------------------------
|
;--------------------------------------------------
|
||||||
jsr WaitForKeyRelease
|
jsr WaitForKeyRelease
|
||||||
@
|
@
|
||||||
|
.IF TARGET = 800
|
||||||
lda SKSTAT
|
lda SKSTAT
|
||||||
cmp #$ff
|
cmp #$ff
|
||||||
beq checkJoyGetKey ; key not pressed, check Joy
|
beq checkJoyGetKey ; key not pressed, check Joy
|
||||||
@@ -1548,7 +1556,7 @@ SetRandomWalls
|
|||||||
bne getkeyend
|
bne getkeyend
|
||||||
mvx #$80 escFlag
|
mvx #$80 escFlag
|
||||||
bne getkeyend
|
bne getkeyend
|
||||||
|
.ENDIF
|
||||||
checkJoyGetKey
|
checkJoyGetKey
|
||||||
;------------JOY-------------
|
;------------JOY-------------
|
||||||
;happy happy joy joy
|
;happy happy joy joy
|
||||||
@@ -1584,15 +1592,13 @@ getkeyend
|
|||||||
;--------------------------------------------------
|
;--------------------------------------------------
|
||||||
.proc WaitForKeyRelease
|
.proc WaitForKeyRelease
|
||||||
;--------------------------------------------------
|
;--------------------------------------------------
|
||||||
.IF TARGET = 5200
|
|
||||||
rts
|
|
||||||
.ELSE
|
|
||||||
lda STICK0
|
lda STICK0
|
||||||
and #$0f
|
and #$0f
|
||||||
cmp #$0f
|
cmp #$0f
|
||||||
bne WaitForKeyRelease
|
bne WaitForKeyRelease
|
||||||
lda STRIG0
|
lda STRIG0
|
||||||
beq WaitForKeyRelease
|
beq WaitForKeyRelease
|
||||||
|
.IF TARGET = 800
|
||||||
lda SKSTAT
|
lda SKSTAT
|
||||||
cmp #$ff
|
cmp #$ff
|
||||||
bne WaitForKeyRelease
|
bne WaitForKeyRelease
|
||||||
@@ -1637,6 +1643,7 @@ noKey
|
|||||||
.endp
|
.endp
|
||||||
MakeDarkScreen
|
MakeDarkScreen
|
||||||
mva #0 dmactls ; dark screen
|
mva #0 dmactls ; dark screen
|
||||||
|
sta dmactl
|
||||||
; and wait one frame :)
|
; and wait one frame :)
|
||||||
.proc WaitOneFrame
|
.proc WaitOneFrame
|
||||||
lda CONSOL
|
lda CONSOL
|
||||||
@@ -1678,7 +1685,7 @@ noingame
|
|||||||
.proc CopyFromROM
|
.proc CopyFromROM
|
||||||
;-------------------------------------------------
|
;-------------------------------------------------
|
||||||
;copy from CART to RAM
|
;copy from CART to RAM
|
||||||
; trashes Y
|
; trashes: Y
|
||||||
; temp: source
|
; temp: source
|
||||||
; temp2: destination
|
; temp2: destination
|
||||||
; modify: destination-end
|
; modify: destination-end
|
||||||
|
|||||||
BIN
Binary file not shown.
BIN
Binary file not shown.
Reference in New Issue
Block a user