OBT/1.2.1(Summer update)

Sync with upstream
This commit is contained in:
NotAlwaysTrue
2026-06-16 22:17:29 +08:00
committed by GitHub
parent 59bc21973a
commit d109c8f827
85 changed files with 1377 additions and 497 deletions
@@ -29,6 +29,31 @@ namespace Barotrauma
partial class SubmarineInfo : IDisposable
{
public static HashSet<string> SubmarinePathsWithRemoteStorage { get; set; } = [];
public bool SaveToRemoteStorage
{
get
{
if (FilePath == null) { return false; }
return SubmarinePathsWithRemoteStorage.Contains(FilePath.CleanUpPathCrossPlatform(correctFilenameCase: false));
}
set
{
if (FilePath == null) { return; }
if (value)
{
SubmarinePathsWithRemoteStorage.Add(FilePath.CleanUpPathCrossPlatform(correctFilenameCase: false));
}
else
{
SubmarinePathsWithRemoteStorage.Remove(FilePath.CleanUpPathCrossPlatform(correctFilenameCase: false));
}
}
}
private static List<SubmarineInfo> savedSubmarines = new List<SubmarineInfo>();
public static IEnumerable<SubmarineInfo> SavedSubmarines => savedSubmarines;
@@ -197,6 +222,8 @@ namespace Barotrauma
set;
}
public bool IsFromRemoteStorage;
/// <summary>
/// When enabled, the <see cref="SubmarineElement">XML element is not loaded</see> until it is accessed.
/// </summary>