mirror of
https://github.com/pkali/scorch_src.git
synced 2026-05-20 22:34:21 +02:00
Meteors added :)
This commit is contained in:
@@ -161,6 +161,36 @@ ClearPlot
|
||||
rts
|
||||
.endp
|
||||
|
||||
; -----------------------------------------
|
||||
.proc ExPlot ;ExPlot (EplotX, EplotY)
|
||||
; EOR plot:
|
||||
; Inverts color of a pixel
|
||||
; Note: No coordinate control!!!
|
||||
; With off-screen coordinates, it can damage main program.
|
||||
; -----------------------------------------
|
||||
; let's calculate coordinates from xdraw and ydraw
|
||||
;xbyte = xbyte/8
|
||||
lda EplotX+1
|
||||
lsr
|
||||
lda EplotX
|
||||
ror ;just one bit over 256. Max screenwidth = 512!!!
|
||||
lsr
|
||||
lsr
|
||||
sta EplotByte
|
||||
;---
|
||||
ldx EplotY
|
||||
ldy linetableL,x
|
||||
lda linetableH,x
|
||||
sta EplotByte+1
|
||||
|
||||
ldx EplotX ; optimization (256 bytes long bittable)
|
||||
|
||||
lda (EplotByte),y
|
||||
eor bittable1_long,x
|
||||
sta (EplotByte),y
|
||||
rts
|
||||
.endp
|
||||
|
||||
; -----------------------------------------
|
||||
.proc point_plot
|
||||
; -----------------------------------------
|
||||
|
||||
@@ -142,6 +142,54 @@ lab2
|
||||
jsr RASTERMUSICTRACKER+3 ;1 play
|
||||
; ------- RMT -------
|
||||
SkipRMTVBL
|
||||
; ------ meteors ------ start
|
||||
bit Mcounter
|
||||
bpl MeteorOnSky
|
||||
bit MeteorsFlag
|
||||
bmi SkipMeteors
|
||||
; randomize meteor
|
||||
lda random
|
||||
and #%11111111
|
||||
bne SkipMeteors
|
||||
lda random
|
||||
sta Mpoint1X
|
||||
sta Mpoint2X
|
||||
lda #0
|
||||
sta Mpoint1X+1
|
||||
sta Mpoint2X+1
|
||||
lda random
|
||||
and #$1f
|
||||
sta Mpoint1Y
|
||||
sta Mpoint2Y
|
||||
mva #10 Mcounter
|
||||
MeteorOnSky
|
||||
lda Mpoint1Y
|
||||
cmp #64
|
||||
beq NoFirstPlot
|
||||
sta EplotY
|
||||
inc Mpoint1Y
|
||||
mwa Mpoint1X EplotX
|
||||
inw Mpoint1X
|
||||
jsr Explot
|
||||
NoFirstPlot
|
||||
lda Mcounter
|
||||
beq @+
|
||||
dec Mcounter
|
||||
bpl SkipSecondPlot
|
||||
@ lda Mpoint2Y
|
||||
cmp #64
|
||||
bne GoSecondPlot
|
||||
mva #$ff Mcounter
|
||||
bmi SkipMeteors
|
||||
GoSecondPlot
|
||||
sta EplotY
|
||||
inc Mpoint2Y
|
||||
mwa Mpoint2X EplotX
|
||||
inw Mpoint2X
|
||||
jsr Explot
|
||||
SkipSecondPlot
|
||||
SkipMeteors
|
||||
; ------ meteors ------ end
|
||||
bit ScrollFlag
|
||||
bpl EndOfCreditsVBI
|
||||
CreditsVBI
|
||||
|
||||
+4
-4
@@ -45,7 +45,7 @@
|
||||
dta d"HASTA LA VISTA, BABY!"^
|
||||
dta d"THIS IS YOUR BRAIN ON SCORCH."^
|
||||
dta d"TAKE THIS!"^
|
||||
dta d"THIS SCREEN AIN'T BIG ENOUGH FOR THE BOTH OF US."^
|
||||
dta d"THIS SCREEN AIN'T BIG ENOUGH FOR US."^
|
||||
dta d"DIE, ALIEN SWINE!"^
|
||||
dta d"AWRUK!!!"^
|
||||
dta d"I SHALL OIL MY TURRET WITH YOUR BLOOD."^
|
||||
@@ -78,12 +78,12 @@
|
||||
dta d"OH MAN!"^
|
||||
dta d"DOOUGH!"^
|
||||
dta d"NEW DAY, NEW BOMB."^
|
||||
dta d"THIS IS THE END, MY ONLY FRIEND."^
|
||||
dta d"THIS IS END."^
|
||||
dta d"VERY FUNNY."^
|
||||
dta d"THE FAT LADY SANG."^
|
||||
dta d"WHY DOES EVERYTHING HAPPEN TO ME?"^
|
||||
dta d"WHY DOES HAPPEN TO ME?"^
|
||||
dta d"I'M GOING DOWN."^
|
||||
dta d"I'VE GOT A BAD FEELING ABOUT THIS."^
|
||||
dta d"I'VE GOT A BAD FEELING."^
|
||||
dta d"CRAPOLA."^
|
||||
dta d"POW!"^
|
||||
dta d"BIF!"^
|
||||
|
||||
@@ -42,6 +42,7 @@ MainGameLoop
|
||||
jsr RoundInit
|
||||
|
||||
jsr MainRoundLoop
|
||||
mva #$ff MeteorsFlag
|
||||
bit escFlag
|
||||
jvs GoGameOver
|
||||
bmi START
|
||||
@@ -360,6 +361,8 @@ CheckNextTankAD
|
||||
jsr PutTankNameOnScreen
|
||||
; jsr DisplayStatus ; There is no need anymore, it is always after PutTankNameOnScreen
|
||||
|
||||
mva #0 MeteorsFlag
|
||||
|
||||
lda SkillTable,x
|
||||
beq ManualShooting
|
||||
|
||||
@@ -392,6 +395,7 @@ ManualShooting
|
||||
spl:rts ; keys Esc or O
|
||||
|
||||
AfterManualShooting
|
||||
mva #$ff MeteorsFlag
|
||||
mva #$00 plot4x4color
|
||||
jsr DisplayTankNameAbove
|
||||
; defensive weapons without flight handling
|
||||
|
||||
+14
-1
@@ -26,7 +26,7 @@
|
||||
|
||||
;---------------------------------------------------
|
||||
.macro build
|
||||
dta d"1.37" ; number of this build (4 bytes)
|
||||
dta d"1.38" ; number of this build (4 bytes)
|
||||
.endm
|
||||
|
||||
.macro RMTSong
|
||||
@@ -37,6 +37,17 @@
|
||||
;---------------------------------------------------
|
||||
icl 'definitions.asm'
|
||||
;---------------------------------------------------
|
||||
AdditionalZPvariables = $20
|
||||
.zpvar EplotX .word = AdditionalZPvariables
|
||||
.zpvar EplotByte .word
|
||||
.zpvar EplotY .byte
|
||||
.zpvar Mpoint1X .word ; meteor first point X position
|
||||
.zpvar Mpoint1Y .byte ; meteor first point Y position
|
||||
.zpvar Mpoint2X .word ; meteor last point X position
|
||||
.zpvar Mpoint2Y .byte ; meteor last point Y position
|
||||
.zpvar Mcounter .byte ; meteor length counter ( $ff - no meteor on sky )
|
||||
.zpvar MeteorsFlag .byte ; $ff - block meteors
|
||||
|
||||
|
||||
FirstZpageVariable = $51
|
||||
.zpvar DliColorBack .byte = FirstZpageVariable
|
||||
@@ -374,6 +385,8 @@ NoRMT_PALchange
|
||||
|
||||
lda #$ff ; initial value
|
||||
sta sfx_effect
|
||||
sta Mcounter
|
||||
sta MeteorsFlag
|
||||
|
||||
RMTSong 0
|
||||
|
||||
|
||||
BIN
Binary file not shown.
+2
-1
@@ -35,8 +35,9 @@
|
||||
icl 'definitions.asm'
|
||||
;---------------------------------------------------
|
||||
|
||||
FirstZpageVariable = $55 ; $57
|
||||
FirstZpageVariable = $54 ; $57
|
||||
.zpvar DliColorBack .byte = FirstZpageVariable
|
||||
.zpvar MeteorsFlag .byte
|
||||
.zpvar GradientNr .byte
|
||||
.zpvar GradientColors .word
|
||||
.zpvar WindChangeInRound .byte ; wind change after each turn (not round only) flag - (0 - round only, >0 - each turn)
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user