mirror of
https://github.com/Pecusx/scorch_src.git
synced 2026-05-20 22:33:43 +02:00
Funky bomb bounces off the walls!
And optimizations.
This commit is contained in:
+35
-21
@@ -5,10 +5,7 @@
|
||||
.proc Explosion
|
||||
;--------------------------------------------------
|
||||
;cleanup of the soil fall down ranges (left and right)
|
||||
mwa #screenwidth RangeLeft
|
||||
lda #0
|
||||
sta RangeRight
|
||||
sta RangeRight+1
|
||||
jsr ClearScreenSoilRange
|
||||
|
||||
ldx TankNr
|
||||
lda ActiveWeapon,x
|
||||
@@ -192,6 +189,7 @@ EndOfLeapping
|
||||
mva #1 Erase
|
||||
jsr drawtanks
|
||||
mva #0 Erase
|
||||
sta FunkyWallFlag
|
||||
pla
|
||||
sta TankNr
|
||||
mva #1 color
|
||||
@@ -224,6 +222,10 @@ NoExplosionInFunkyBomb
|
||||
dec FunkyBombCounter
|
||||
bne FunkyBombLoop
|
||||
mva #0 tracerflag
|
||||
lda FunkyWallFlag
|
||||
beq NoWallsInFunky
|
||||
jsr SetFullScreenSoilRange
|
||||
NoWallsInFunky
|
||||
rts
|
||||
.endp
|
||||
; ------------------------
|
||||
@@ -1519,7 +1521,7 @@ RandomizeOffensiveText
|
||||
|
||||
sta TextNumberOff
|
||||
ldy TankNr
|
||||
mva #1 plot4x4color
|
||||
mva #$ff plot4x4color
|
||||
jsr DisplayOffensiveTextNr
|
||||
|
||||
mva #0 LaserFlag ; $ff - Laser
|
||||
@@ -2099,10 +2101,7 @@ MIRVcopyParameters
|
||||
sta vx03+4
|
||||
|
||||
; clearing ranges of soil down registers
|
||||
mwa #screenwidth RangeLeft
|
||||
lda #0
|
||||
sta RangeRight
|
||||
sta RangeRight+1
|
||||
jsr ClearScreenSoilRange
|
||||
|
||||
ldx #$FF ; it will turn 0 in a moment anyway
|
||||
stx MirvMissileCounter
|
||||
@@ -2334,7 +2333,7 @@ MIRValreadyAll
|
||||
|
||||
;first clean the offensive text...
|
||||
ldy TankNr
|
||||
mva #0 plot4x4color
|
||||
mva #$00 plot4x4color
|
||||
jsr DisplayOffensiveTextNr
|
||||
|
||||
; temporary removing tanks from the screen (otherwise they will fall down with soil)
|
||||
@@ -2377,12 +2376,14 @@ MakeBump
|
||||
sbc vx+#
|
||||
sta vx+#
|
||||
.endr
|
||||
inc FunkyWallFlag
|
||||
rts
|
||||
WrapAndNone
|
||||
bvc NoWall
|
||||
cpw xtraj+1 #screenwidth
|
||||
bcc OnScreen
|
||||
; (wrapping wall)
|
||||
inc FunkyWallFlag
|
||||
bit xtraj+2
|
||||
bmi LeftWrap
|
||||
RightWrap
|
||||
@@ -2464,10 +2465,7 @@ NextLine2
|
||||
lda #0
|
||||
ldx TankNr
|
||||
sta ActiveDefenceWeapon,x ; deactivate Nuclear Winter
|
||||
|
||||
sta RangeLeft ; whole screen in range of soil down
|
||||
sta RangeLeft+1
|
||||
mwa #screenwidth RangeRight
|
||||
jsr SetFullScreenSoilRange
|
||||
jsr SoilDown2
|
||||
jsr drawtanks ; for restore PM
|
||||
rts
|
||||
@@ -2560,7 +2558,7 @@ ReachSky
|
||||
lda FloatingAlt
|
||||
sbc #12
|
||||
sta LineYdraw
|
||||
lda #0
|
||||
lda #$00
|
||||
jsr TypeLine4x4.staplot4x4color
|
||||
; and Soildown at the start (for correct mountaintable if tank was buried)
|
||||
; calculate range
|
||||
@@ -2727,7 +2725,7 @@ pressedSpace
|
||||
lda FloatingAlt
|
||||
sbc #12
|
||||
sta LineYdraw
|
||||
lda #0
|
||||
lda #$00
|
||||
jsr TypeLine4x4.staplot4x4color
|
||||
ldx TankNr
|
||||
;=================================
|
||||
@@ -2981,10 +2979,7 @@ CalculateExplosionRange0
|
||||
;(for the first or single explosion)
|
||||
|
||||
;zero soil fall out ranges
|
||||
mwa #screenwidth RangeLeft
|
||||
lda #0
|
||||
sta RangeRight
|
||||
sta RangeRight+1
|
||||
jsr ClearScreenSoilRange
|
||||
;--------------------------------------------------
|
||||
.proc CalculateExplosionRange
|
||||
;--------------------------------------------------
|
||||
@@ -3016,7 +3011,26 @@ RangesChecked
|
||||
|
||||
rts
|
||||
.endp
|
||||
|
||||
|
||||
;--------------------------------------------------
|
||||
.proc SetFullScreenSoilRange
|
||||
; whole screen in range of soil down
|
||||
;--------------------------------------------------
|
||||
lda #0
|
||||
sta RangeLeft
|
||||
sta RangeLeft+1
|
||||
mwa #screenwidth RangeRight
|
||||
rts
|
||||
.endp
|
||||
;--------------------------------------------------
|
||||
.proc ClearScreenSoilRange
|
||||
; cleanup of the soil fall down ranges (left and right) ;--------------------------------------------------
|
||||
mwa #screenwidth RangeLeft
|
||||
lda #0
|
||||
sta RangeRight
|
||||
sta RangeRight+1
|
||||
rts
|
||||
.endp
|
||||
;--------------------------------------------------
|
||||
.proc DecreaseWeaponBeforeShoot
|
||||
;--------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user