(da82264a0) Use ISpatialEntity as the target of "go to" objective to get rid of the reaching issues. Use display units instead of sim units. Don't calculate a standing point in "fix leak" objective, because it's handled in the AIOperate method when the bot get's near enough,
This commit is contained in:
@@ -142,7 +142,7 @@ namespace Barotrauma
|
||||
bool run = objectiveManager.CurrentObjective.ForceRun || objectiveManager.GetCurrentPriority() > AIObjectiveManager.RunPriority;
|
||||
if (ObjectiveManager.CurrentObjective is AIObjectiveGoTo goTo && goTo.Target != null)
|
||||
{
|
||||
run = Vector2.DistanceSquared(Character.SimPosition, goTo.Target.SimPosition) > 3 * 3;
|
||||
run = Vector2.DistanceSquared(Character.WorldPosition, goTo.Target.WorldPosition) > 300 * 300;
|
||||
}
|
||||
if (run)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user