Merge branch 'dev' of https://github.com/Regalis11/Barotrauma.git into unstable-tests

This commit is contained in:
Evil Factory
2022-04-08 15:28:28 -03:00
20 changed files with 156 additions and 145 deletions
@@ -545,7 +545,7 @@ namespace Barotrauma
savedSubmarines.Add(subInfo);
}
public static void RefreshSavedSub(string filePath)
public static void RemoveSavedSub(string filePath)
{
string fullPath = Path.GetFullPath(filePath);
for (int i = savedSubmarines.Count - 1; i >= 0; i--)
@@ -555,7 +555,11 @@ namespace Barotrauma
savedSubmarines[i].Dispose();
}
}
}
public static void RefreshSavedSub(string filePath)
{
RemoveSavedSub(filePath);
if (File.Exists(filePath))
{
var subInfo = new SubmarineInfo(filePath);