mirror of
https://github.com/Pecusx/scorch_src.git
synced 2026-05-20 22:33:43 +02:00
The first attempt at handling defensive weapons
Only for test. Now all players has active Parachute berore round.
This commit is contained in:
+10
-1
@@ -128,7 +128,16 @@ START
|
||||
|
||||
jsr RandomizeSequence
|
||||
; for the round #1 shooting sequence is random
|
||||
|
||||
|
||||
; activate parachutes for all players (test)
|
||||
lda #$35
|
||||
ldx numberOfPlayers
|
||||
dex
|
||||
@
|
||||
sta ActiveDefenceWeapon,x
|
||||
dex
|
||||
bpl @-
|
||||
; parachutes activated! (test)
|
||||
MainGameLoop
|
||||
VDLI DLIinterruptText ; jsr SetDLI for text (purchase) screen
|
||||
|
||||
|
||||
BIN
Binary file not shown.
@@ -95,6 +95,8 @@ NewAngle .DS 1
|
||||
|
||||
ActiveWeapon ;number of the selected weapon
|
||||
.DS [MaxPlayers]
|
||||
ActiveDefenceWeapon ;number of the activated defence weapon - 0
|
||||
.DS [MaxPlayers]
|
||||
WeaponDepleted .DS 1 ; if 0 deactivate the weapon and switch to Baby Missile
|
||||
;----------------------------------------------------
|
||||
|
||||
|
||||
+5
-7
@@ -1298,9 +1298,10 @@ ShotUnderGround
|
||||
sta Parachute
|
||||
|
||||
; let's check if the given tank has got the parachute
|
||||
lda #$35 ; parachute
|
||||
jsr HowManyBullets
|
||||
beq TankFallsX
|
||||
ldx TankNr
|
||||
lda ActiveDefenceWeapon,x
|
||||
cmp #$35 ; parachute
|
||||
bne TankFallsX
|
||||
inc Parachute
|
||||
TankFallsX
|
||||
; coordinates of the first pixel under the tank
|
||||
@@ -1502,6 +1503,7 @@ EndOfFall
|
||||
; first we clear parachute on the screen
|
||||
mva #1 Erase
|
||||
ldx TankNr
|
||||
mva #0 ActiveDefenceWeapon,x ; deactivate defence weapon (parachute)
|
||||
lda #$34
|
||||
sta CharCode
|
||||
lda Ytankstable,x
|
||||
@@ -1514,10 +1516,6 @@ EndOfFall
|
||||
sta xdraw+1
|
||||
jsr TypeChar
|
||||
mva #0 Erase
|
||||
; now we can deduct one parachute from the list of weapons
|
||||
|
||||
lda #$35 ; parachute
|
||||
jsr DecreaseWeapon
|
||||
ThereWasNoParachute
|
||||
mva #sfx_silencer sfx_effect
|
||||
rts
|
||||
|
||||
Reference in New Issue
Block a user