AI optimisations

This commit is contained in:
Pecusx
2022-07-31 22:49:34 +02:00
parent 025afbce91
commit 6a0c3a91e9
5 changed files with 19 additions and 14 deletions
+8 -3
View File
@@ -609,11 +609,16 @@ skipThisPlayer
lda OptionsTable+2 ; selected gravity lda OptionsTable+2 ; selected gravity
asl asl
tay tay
clc
lda AIForceTable,y lda AIForceTable,y
sta ForceTableL,x sta RandBoundaryLow
adc #60
sta RandBoundaryHigh
lda AIForceTable+1,y lda AIForceTable+1,y
sta ForceTableH,x sta RandBoundaryLow+1
jsr RandomizeForce.LimitForce adc #0
sta RandBoundaryHigh+1
jsr RandomizeForce
lda ForceTableL,x lda ForceTableL,x
sta Force sta Force
lda ForceTableH,x lda ForceTableH,x
+1 -1
View File
@@ -20,7 +20,7 @@ CashOptionH
GravityTable .by 10,20,25,30,40 GravityTable .by 10,20,25,30,40
MaxWindTable .by 5,20,40,70,99 MaxWindTable .by 5,20,40,70,99
RoundsTable .by 10,20,30,40,50 RoundsTable .by 10,20,30,40,50
AIForceTable .wo 400,500,650,750,850 ; starting shoot forces for different gravity AIForceTable .wo 375,470,630,720,820 ; starting shoot forces for different gravity
flyDelayTable .by 255,150,75,35,1 flyDelayTable .by 255,150,75,35,1
seppukuTable .by 255, 45,25,15,9 seppukuTable .by 255, 45,25,15,9
mountainsDeltaTableH .by 0,1,3,5,7 mountainsDeltaTableH .by 0,1,3,5,7
+7 -7
View File
@@ -744,16 +744,16 @@ ldahashzero
NotNegativeEnergy NotNegativeEnergy
sta Energy,x sta Energy,x
;now increase the gain of the shooting tank ;now increase the gain of the shooting tank
phx ; phx
ldx TankNr ldy TankNr
clc clc
lda gainL,x lda gainL,y
adc EnergyDecrease adc EnergyDecrease
sta gainL,x sta gainL,y
lda gainH,x lda gainH,y
adc #$00 adc #$00
sta gainH,x sta gainH,y
plx ; plx
rts rts
.endp .endp
BIN
View File
Binary file not shown.
+3 -3
View File
@@ -764,8 +764,8 @@ ExplosionLoop2
;calculation ;calculation
ldx NumberOfPlayers ldx NumberOfPlayers
dex
DistanceCheckLoop DistanceCheckLoop
dex
lda eXistenZ,x lda eXistenZ,x
jeq EndOfDistanceCheckLoop jeq EndOfDistanceCheckLoop
;here the tank exist ;here the tank exist
@@ -838,8 +838,8 @@ UseShield
sta TankNr ; restore TankNr value :) sta TankNr ; restore TankNr value :)
TankIsNotWithinTheRange TankIsNotWithinTheRange
EndOfDistanceCheckLoop EndOfDistanceCheckLoop
txa dex
jne DistanceCheckLoop jpl DistanceCheckLoop
mva #sfx_silencer sfx_effect mva #sfx_silencer sfx_effect
rts rts
.endp .endp