Skip to content

Commit

Permalink
Fix WebGL Start
Browse files Browse the repository at this point in the history
  • Loading branch information
davidmfinol committed Nov 7, 2023
1 parent 674e2b7 commit bda226c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Assets/Scripts/Cgs/CardGameManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -607,8 +607,14 @@ internal void ResetGameScene()
}

#if UNITY_WEBGL && !UNITY_EDITOR
private void Start()
private IEnumerator Start()
{
Debug.Log("CardGameManager::Start:WaitForCurrentIsDownloading");

yield return null;
while (Current is {IsDownloading: true})
yield return null;

Debug.Log("CardGameManager::Start:GameReady");
GameReady();
}
Expand Down

0 comments on commit bda226c

Please sign in to comment.