Added loading screen that shows up while awaiting the data from the database
This commit is contained in:
@@ -56,6 +56,8 @@ namespace GhostSystem
|
||||
|
||||
public static event Action OnRestartLoop;
|
||||
|
||||
public GameObject loadingScreen;
|
||||
|
||||
[Serializable]
|
||||
public class TrackedObjectBinding
|
||||
{
|
||||
@@ -83,6 +85,7 @@ namespace GhostSystem
|
||||
|
||||
private void HandleSceneIdReady(string id, List<GameObject> doors, List<RecieveHeat> targets)
|
||||
{
|
||||
loadingScreen.SetActive(true);
|
||||
sceneIdReady = true;
|
||||
loadedSceneId = id;
|
||||
foreach (GameObject door in doors)
|
||||
@@ -104,6 +107,7 @@ namespace GhostSystem
|
||||
sceneId = loadedSceneId;
|
||||
|
||||
await LoadAllFrames();
|
||||
loadingScreen.SetActive(false);
|
||||
StartReplay();
|
||||
_ = PeriodicUpdateFrames();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user