mirror of
https://github.com/Pecusx/scorch_src.git
synced 2026-05-21 06:39:40 +02:00
Small memory optimisations
This commit is contained in:
+4
-6
@@ -272,6 +272,8 @@ skipzeroing
|
|||||||
lda #0
|
lda #0
|
||||||
sta sizep0 ; P0-P1 widths
|
sta sizep0 ; P0-P1 widths
|
||||||
sta sizep0+1
|
sta sizep0+1
|
||||||
|
sta colpf2s ; status line "off"
|
||||||
|
sta colpf1s
|
||||||
|
|
||||||
tax
|
tax
|
||||||
@ sta singleRoundVars,x
|
@ sta singleRoundVars,x
|
||||||
@@ -322,9 +324,6 @@ SettingEnergies
|
|||||||
|
|
||||||
jsr SetMainScreen
|
jsr SetMainScreen
|
||||||
jsr ColorsOfSprites
|
jsr ColorsOfSprites
|
||||||
lda #0
|
|
||||||
sta colpf2s ; status line "off"
|
|
||||||
sta colpf1s
|
|
||||||
|
|
||||||
; lda #90 ; barrel fully erect
|
; lda #90 ; barrel fully erect
|
||||||
; ldx #MaxPlayers-1
|
; ldx #MaxPlayers-1
|
||||||
@@ -336,9 +335,8 @@ SettingEnergies
|
|||||||
jsr drawmountains ;draw them
|
jsr drawmountains ;draw them
|
||||||
jsr drawtanks ;finally draw tanks
|
jsr drawtanks ;finally draw tanks
|
||||||
|
|
||||||
lda #$00
|
mva #$00 TankSequencePointer
|
||||||
sta TankSequencePointer
|
|
||||||
sta TestFlightFlag
|
|
||||||
;---------round screen is ready---------
|
;---------round screen is ready---------
|
||||||
mva #TextForegroundColor colpf1s ; status line "on"
|
mva #TextForegroundColor colpf1s ; status line "on"
|
||||||
rts
|
rts
|
||||||
|
|||||||
BIN
Binary file not shown.
+7
-24
@@ -1505,15 +1505,9 @@ NotStrongShoot
|
|||||||
sta Force+1
|
sta Force+1
|
||||||
mva #sfx_shoot sfx_effect
|
mva #sfx_shoot sfx_effect
|
||||||
AfterStrongShoot
|
AfterStrongShoot
|
||||||
lda #$0
|
|
||||||
sta Force+2
|
|
||||||
lda AngleTable,x
|
lda AngleTable,x
|
||||||
sta Angle
|
sta Angle
|
||||||
|
|
||||||
lda #0
|
|
||||||
sta xtraj
|
|
||||||
sta ytraj
|
|
||||||
|
|
||||||
; Shoots tank nr X !!! :)
|
; Shoots tank nr X !!! :)
|
||||||
; set the starting coordinates of bullet with correction
|
; set the starting coordinates of bullet with correction
|
||||||
; to start where the tank's barrel ends
|
; to start where the tank's barrel ends
|
||||||
@@ -1522,26 +1516,15 @@ AfterStrongShoot
|
|||||||
|
|
||||||
mwa EndOfTheBarrelX xtraj+1
|
mwa EndOfTheBarrelX xtraj+1
|
||||||
mva EndOfTheBarrely ytraj+1
|
mva EndOfTheBarrely ytraj+1
|
||||||
mva #0 ytraj+2
|
lda #0
|
||||||
|
sta Force+2
|
||||||
;ldy Angle
|
sta ytraj+2
|
||||||
;clc
|
sta xtraj
|
||||||
;lda xtankstableL,x
|
sta ytraj
|
||||||
;adc EndOfTheBarrelX,y ; correction of X
|
sta TestFlightFlag
|
||||||
;sta xtraj+1
|
|
||||||
;lda xtankstableH,x
|
|
||||||
;adc #$00
|
|
||||||
;sta xtraj+2
|
|
||||||
;sec
|
|
||||||
;lda ytankstable,x
|
|
||||||
;sbc EndOfTheBarrelY,y ; correction of Y
|
|
||||||
;sta ytraj+1
|
|
||||||
;lda #$00
|
|
||||||
;sbc #$00
|
|
||||||
;sta ytraj+2
|
|
||||||
|
|
||||||
; checking if the shot is underground (no Flight but Hit :) )
|
; checking if the shot is underground (no Flight but Hit :) )
|
||||||
ldy #0
|
tay ; A=0 !
|
||||||
adw xtraj+1 #mountaintable temp
|
adw xtraj+1 #mountaintable temp
|
||||||
lda ytraj+1
|
lda ytraj+1
|
||||||
cmp (temp),y ; check collision witch mountains
|
cmp (temp),y ; check collision witch mountains
|
||||||
|
|||||||
Reference in New Issue
Block a user