(24bcea40e) Fix the ai checks about door buttons. Don't aim at targets that cannot be seen.
This commit is contained in:
@@ -350,12 +350,7 @@ namespace Barotrauma.Items.Components
|
||||
var door = indoorSteering.CurrentPath?.CurrentNode?.ConnectedDoor;
|
||||
if (door != null && !door.IsOpen)
|
||||
{
|
||||
var buttons = door.Item.GetComponents<Controller>();
|
||||
if (buttons.None())
|
||||
{
|
||||
buttons = door.Item.GetConnectedComponents<Controller>(true);
|
||||
}
|
||||
isOperatingButtons = buttons.Any();
|
||||
isOperatingButtons = door.HasIntegratedButtons || door.Item.GetConnectedComponents<Controller>(true).Any();
|
||||
}
|
||||
}
|
||||
if (!isOperatingButtons)
|
||||
|
||||
Reference in New Issue
Block a user