(2ffcd0a06) Retry writing files in SaveUtil.DecompressFile up to 4 times (in case the file is being used by another process), fixed DecompressFiletoStream "retrying" 4 times even if the first try succeeds
This commit is contained in:
+6
-6
@@ -28,6 +28,10 @@ namespace Barotrauma
|
||||
|
||||
private AIObjectiveGoTo gotoObjective;
|
||||
|
||||
private bool useController;
|
||||
|
||||
private AIObjectiveGoTo gotoObjective;
|
||||
|
||||
public override bool CanBeCompleted
|
||||
{
|
||||
get
|
||||
@@ -47,6 +51,8 @@ namespace Barotrauma
|
||||
|
||||
public ItemComponent Component => component;
|
||||
|
||||
public ItemComponent Component => component;
|
||||
|
||||
public override float GetPriority(AIObjectiveManager objectiveManager)
|
||||
{
|
||||
if (gotoObjective != null && !gotoObjective.CanBeCompleted) { return 0; }
|
||||
@@ -116,12 +122,6 @@ namespace Barotrauma
|
||||
return;
|
||||
}
|
||||
else if (!character.Inventory.Items.Contains(component.Item))
|
||||
{
|
||||
//controller/target can't be selected and the item cannot be picked -> objective can't be completed
|
||||
canBeCompleted = false;
|
||||
return;
|
||||
}
|
||||
else if (!character.Inventory.Items.Contains(component.Item))
|
||||
{
|
||||
//controller/target can't be selected and the item cannot be picked -> objective can't be completed
|
||||
abandon = true;
|
||||
|
||||
Reference in New Issue
Block a user