[quote="newt":rz36gi4h]Yeah the turret behavior was designed to either be attached to something that moves, or stationary, so basically all its good for is attacking.
Quite honestly you'd be better off dropping physics, and using the custom movement behavior, and either using the line of sight behavior, or distance(), with you own attacking/ retreating events.
For the black hole there's even a command that would work well for that "restrain distance from position" If you use a lerp on the distance to restrain, and set it to "distance lower".
Course you would have to have to include a escape velocity condition in there.[/quote:rz36gi4h]
Just when I got it all dialed in with physics and turret behaviors!
If I were to stick with physics, I was thinking that I might create several "escape points" and arrange them around the black hole. And then assign them the attribute "escape point." That way, if the ship strayed too far into the "black hole zone", I could tell it to aquire the nearest escape point, target that and add thrust.
Unfortunately, when I try to do this, either with the "follow first in range" or even the "always the nearest" properties it refuses to work. It will only target one of the "escape points" and always the same one. If I then delete that escape point. It'll pick another one and target only that. Regardless of which one is closer.
I even tried dropping attributes in favor makeing the escape points out of families instead. Still the same response.
I must be doing something wrong.
Right now it is:
If Ships Distance to Black Hole lower than 350 > Aquire target "escape point." Add thrust.
If Ships Distance to Black Hole greater than 350 > Go back to hunt and shoot behaviors.
I've tried clearing the targets first, then acquiring the "escape points." Nothing works.
Should I be using the "add object to target" action instead? What's the difference between "add object to target" and "acquire target"? I've tried using both at the same time to no avail.
I wanted to see if something like this could work before I scrapped all the physics stuff I'm doing (there is alot of stuff that right now requires the physics behavior.)
Any thoughts appreciated. Thanks!