(a98f03ffb) Fix target blocking itself when it's structure. Take doors into account.

This commit is contained in:
Joonas Rikkonen
2019-05-03 13:46:48 +03:00
parent 0e96e18a24
commit 3d5e402d22
5 changed files with 150 additions and 251 deletions
@@ -315,6 +315,19 @@ namespace Barotrauma.Items.Components
return true;
}
public override void OnItemLoaded()
{
sonar = item.GetComponent<Sonar>();
}
public override bool Select(Character character)
{
if (!CanBeSelected) return false;
user = character;
return true;
}
public override void Update(float deltaTime, Camera cam)
{
networkUpdateTimer -= deltaTime;