Tehtsuo / Combot

5 stars 2 forks source link

Speed Tank loiters on objects instead of targets #108

Closed fingerboxes closed 11 years ago

fingerboxes commented 11 years ago

I'm not exactly sure how to explain this behavior, but sometimes the speed tank will orbit some random object in a pocket, instead of its target, for extended periods of time, allowing the target to wander far outside the range of weapons.

fingerboxes commented 11 years ago

Figured it out. I had my orbit distance set lower than the threshold for orbiting objects to avoid them (5km).

It seems to me that if you change that threshold to be ${Config.SpeedTankDistance}, instead of a hardcoded value, this bug could not appear in the future.

fingerboxes commented 11 years ago

But, no, that is wrong too, because then you'd be catching all sorts of objects instead of targets.

Maybe, 5km or ${Config.SpeedTankDistance}, whichever is smaller? idk.