v1.3.0.1 (Epic Store release)

This commit is contained in:
Regalis11
2024-03-28 18:34:33 +02:00
parent 81ca8637be
commit 3791670c42
269 changed files with 13160 additions and 2966 deletions
@@ -1,20 +1,10 @@
using System.Threading.Tasks;
#nullable enable
using System.Threading.Tasks;
namespace Barotrauma
{
static class TaskExtensions
public static class TaskExtensions
{
public static bool TryGetResult<T>(this Task task, out T result)
{
if (task is Task<T> { IsCompletedSuccessfully: true } castTask)
{
result = castTask.Result;
return true;
}
result = default;
return false;
}
public static async Task<T> WaitForLoadingScreen<T>(this Task<T> task)
{
var result = await task;
@@ -27,4 +17,4 @@ namespace Barotrauma
return result;
}
}
}
}