New AI tank - Toosser and angle bugfixex

This commit is contained in:
Pecusx
2022-07-03 16:43:43 +02:00
parent a860c4dfa1
commit 2a5595f3c9
3 changed files with 45 additions and 14 deletions
+1 -7
View File
@@ -1142,14 +1142,8 @@ LimitForce
.proc MoveBarrelToNewPosition
jsr DrawTankNr
ldx TankNr
lda AngleTable,x
clc
adc #90 ;shift angle to the positive values
sta temp
lda NewAngle
clc
adc #90
cmp temp
cmp AngleTable,x
beq BarrelPositionIsFine
bcc rotateLeft ; older is bigger
rotateRight;older is lower