Client LuaCsForBarotrauma
TaskExtensions.cs
1
#nullable enable
2
using
System.Threading.Tasks;
3
4
namespace
Barotrauma
5
{
6
public
static
class
TaskExtensions
7
{
8
public
static
async Task<T> WaitForLoadingScreen<T>(
this
Task<T> task)
9
{
10
var result = await task;
11
#if CLIENT
12
while
(GameMain.Instance.LoadingScreenOpen)
13
{
14
await Task.Delay((
int
)(1000 * Timing.Step));
15
}
16
#endif
17
return
result;
18
}
19
}
20
}
Barotrauma
Definition:
AchievementManager.cs:12
Barotrauma
BarotraumaShared
SharedSource
Utils
TaskExtensions.cs
Generated by
1.9.1