144 useThisActions:= true |
144 useThisActions:= true |
145 end; |
145 end; |
146 |
146 |
147 BestActions.Score:= Actions.Score + Score; |
147 BestActions.Score:= Actions.Score + Score; |
148 |
148 |
149 if HHHasAmmo(Me^.Hedgehog^, amInvulnerable) > 0 then |
149 // if not between shots, activate invulnerability/vampirism if available |
150 begin |
150 if CurrentHedgehog^.MultiShootAttacks = 0 then |
151 AddAction(BestActions, aia_Weapon, Longword(amInvulnerable), 80, 0, 0); |
151 begin |
152 AddAction(BestActions, aia_attack, aim_push, 10, 0, 0); |
152 if HHHasAmmo(Me^.Hedgehog^, amInvulnerable) > 0 then |
153 AddAction(BestActions, aia_attack, aim_release, 10, 0, 0); |
153 begin |
154 end; |
154 AddAction(BestActions, aia_Weapon, Longword(amInvulnerable), 80, 0, 0); |
155 |
155 AddAction(BestActions, aia_attack, aim_push, 10, 0, 0); |
156 if HHHasAmmo(Me^.Hedgehog^, amExtraDamage) > 0 then |
156 AddAction(BestActions, aia_attack, aim_release, 10, 0, 0); |
157 begin |
157 end; |
158 AddAction(BestActions, aia_Weapon, Longword(amExtraDamage), 80, 0, 0); |
158 |
159 AddAction(BestActions, aia_attack, aim_push, 10, 0, 0); |
159 if HHHasAmmo(Me^.Hedgehog^, amExtraDamage) > 0 then |
160 AddAction(BestActions, aia_attack, aim_release, 10, 0, 0); |
160 begin |
161 end; |
161 AddAction(BestActions, aia_Weapon, Longword(amExtraDamage), 80, 0, 0); |
|
162 AddAction(BestActions, aia_attack, aim_push, 10, 0, 0); |
|
163 AddAction(BestActions, aia_attack, aim_release, 10, 0, 0); |
|
164 end; |
|
165 end; |
162 |
166 |
163 AddAction(BestActions, aia_Weapon, Longword(a), 300 + random(400), 0, 0); |
167 AddAction(BestActions, aia_Weapon, Longword(a), 300 + random(400), 0, 0); |
164 |
168 |
165 if (ap.Angle > 0) then |
169 if (ap.Angle > 0) then |
166 AddAction(BestActions, aia_LookRight, 0, 200, 0, 0) |
170 AddAction(BestActions, aia_LookRight, 0, 200, 0, 0) |