[Add] Check for weapon range when running away with turrets.
This commit is contained in:
parent
04fc879ac8
commit
19cbc18ff3
@ -52,7 +52,7 @@ function runaway()
|
||||
ai.accel()
|
||||
if ai.hasturrets() then
|
||||
dist = ai.dist(ai.pos(target))
|
||||
if dist < 300 then
|
||||
if dist < ai.getweaprange() then
|
||||
ai.settarget(target)
|
||||
ai.shoot()
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user