(86280d29b) Merge branch 'dev' of github.com:Regalis11/Barotrauma-development into dev

This commit is contained in:
Joonas Rikkonen
2019-05-16 06:31:49 +03:00
parent fc22eb5088
commit 80c563e7b0
23 changed files with 296 additions and 295 deletions
@@ -91,8 +91,7 @@ namespace Barotrauma
}
else
{
if (container.Item.CurrentHull != character.CurrentHull ||
(Vector2.DistanceSquared(character.Position, container.Item.Position) > Math.Pow(container.Item.InteractDistance, 2) && !container.Item.IsInsideTrigger(character.WorldPosition)))
if (!character.CanInteractWith(container.Item, out _, checkLinked: false))
{
TryAddSubObjective(ref goToObjective, () => new AIObjectiveGoTo(container.Item, character, objectiveManager));
return;