Better? AI purchases and new WAIT macro

This commit is contained in:
Pecusx
2022-08-05 12:04:14 +02:00
parent 05409fa301
commit d448eb2e1e
4 changed files with 20 additions and 20 deletions
+5 -6
View File
@@ -961,10 +961,10 @@ SorryNoPurchase
; what is my money level
ldx TankNr
lda MoneyH,x ; money / 256
sta tempXroller ; perform this many purchase attempts
; lda MoneyH,x ; money / 256
; sta tempXroller ; perform this many purchase attempts
; first try to buy defensives
mva #2 tempXroller; number of defensive purchases to perform
mva #1 tempXroller; number of defensive purchases to perform
@
randomize ind_Battery________ ind_Auto_Defense___
jsr TryToPurchaseOnePiece
@@ -991,7 +991,7 @@ SorryNoPurchase
;lda MoneyH,x ; money / 256
;sta tempXroller ; perform this many purchase attempts
; first try to buy defensives
mva #2 tempXroller; number of defensive purchases to perform
mva #1 tempXroller; number of defensive purchases to perform
@
randomize ind_Battery________ ind_Auto_Defense___
jsr TryToPurchaseOnePiece2
@@ -1000,8 +1000,7 @@ SorryNoPurchase
; and now offensives
lda MoneyH,x ; money / 256
asl ;*4
asl
:4 asl ;*16
sta tempXroller ; perform this many purchase attempts
@
randomize ind_Missile________ ind_Plasma_Blast___
+7 -7
View File
@@ -535,7 +535,7 @@ PurchaseMeTable ;weapons good to be purchased by the robot
dta 0 ;"Dirt Charge " ; 29
dta 0 ;"Earth Disrupter " ; 30
dta 0 ;"Plasma Blast " ; 31
dta 1 ;"Laser " ; 32
dta 0 ;"Laser " ; 32
dta 0 ;"----------------" ; 33
dta 0 ;"----------------" ; 34
dta 0 ;"----------------" ; 35
@@ -571,13 +571,13 @@ PurchaseMeTable ;weapons good to be purchased by the robot
PurchaseMeTable2 ;weapons good to be purchased by the robot (Cyborg)
;the comment is an index in the tables
dta 1 ;"Baby Missile " ; 0
dta 1 ;"Missile " ; 1
dta 0 ;"Missile " ; 1
dta 1 ;"Baby Nuke " ; 2
dta 1 ;"Nuke " ; 3
dta 0 ;"LeapFrog " ; 4
dta 0 ;"Funky Bomb " ; 5
dta 0 ;"MIRV " ; 6
dta 0 ;"Death's Head " ; 7
dta 1 ;"Death's Head " ; 7
dta 0 ;"Napalm " ; 8
dta 1 ;"Hot Napalm " ; 9
dta 0 ;"Tracer " ; 10
@@ -601,8 +601,8 @@ PurchaseMeTable2 ;weapons good to be purchased by the robot (Cyborg)
dta 0 ;"Liquid Dirt " ; 28
dta 0 ;"Dirt Charge " ; 29
dta 0 ;"Earth Disrupter " ; 30
dta 1 ;"Plasma Blast " ; 31
dta 1 ;"Laser " ; 32
dta 0 ;"Plasma Blast " ; 31
dta 0 ;"Laser " ; 32
dta 0 ;"----------------" ; 33
dta 0 ;"----------------" ; 34
dta 0 ;"----------------" ; 35
@@ -624,10 +624,10 @@ PurchaseMeTable2 ;weapons good to be purchased by the robot (Cyborg)
dta 0 ;"Horz Guidance " ; 51
dta 0 ;"Vert Guidance " ; 52
dta 0 ;"Lazy Boy " ; 53
dta 1 ;"Parachute " ; 54
dta 0 ;"Parachute " ; 54
dta 1 ;"Strong Parachute" ; 55
dta 1 ;"Mag Deflector " ; 56
dta 1 ;"Shield " ; 57
dta 0 ;"Shield " ; 57
dta 1 ;"Heavy Shield " ; 58
dta 1 ;"Force Shield " ; 59
dta 0 ;"Super Mag " ; 60
+8 -7
View File
@@ -79,13 +79,14 @@
lda CONSOL
cmp #6 ; START KEY
beq ?nowait
LDA VCOUNT
ldy vcount
?WA cpy VCOUNT
BEQ ?WA
?wframe
cmp vcount
bne ?wframe
?zero LDA VCOUNT
beq ?zero
?WA cmp VCOUNT
beq ?WA
bcc ?WA
?WFRAME cmp VCOUNT
beq ?nowait
bcs ?WFRAME
?nowait
.ENDM
;-------------------------------------
BIN
View File
Binary file not shown.