불필요한 Task 재거
This commit is contained in:
parent
1f42e5b7f7
commit
ffd534cb13
@ -25,13 +25,13 @@ public void Init()
|
||||
GameFlowDataSo.CurrentGameState = GameFlowState.None;
|
||||
}
|
||||
|
||||
public async void PostInit()
|
||||
public void PostInit()
|
||||
{
|
||||
try
|
||||
{
|
||||
if (IsGameStarted() == false)
|
||||
{
|
||||
await ChangeFlow(GameFlowState.ReadyForRestaurant);
|
||||
ChangeFlow(GameFlowState.ReadyForRestaurant);
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
@ -42,7 +42,7 @@ public async void PostInit()
|
||||
|
||||
private bool IsGameStarted() => GameFlowDataSo.CurrentGameState != GameFlowState.None;
|
||||
|
||||
public async Task ChangeFlow(GameFlowState newFlowState)
|
||||
public void ChangeFlow(GameFlowState newFlowState)
|
||||
{
|
||||
if (!CanChangeFlow(newFlowState))
|
||||
{
|
||||
@ -52,7 +52,7 @@ public async Task ChangeFlow(GameFlowState newFlowState)
|
||||
|
||||
EndCurrentFlow();
|
||||
|
||||
await ReadyNewFlow(newFlowState);
|
||||
ReadyNewFlow(newFlowState);
|
||||
}
|
||||
|
||||
private bool CanChangeFlow(GameFlowState newFlowState)
|
||||
@ -65,7 +65,7 @@ private void EndCurrentFlow()
|
||||
|
||||
}
|
||||
|
||||
private async Task ReadyNewFlow(GameFlowState newFlowState)
|
||||
private void ReadyNewFlow(GameFlowState newFlowState)
|
||||
{
|
||||
GameFlowDataSo.CurrentGameState = newFlowState;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user