Update the Pause menu flow to be slightly less scoffed
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
using System;
|
||||
using Core;
|
||||
using UnityEngine;
|
||||
using UnityEngine.SceneManagement;
|
||||
@@ -10,9 +11,10 @@ public class DivingGameOverScreen : MonoBehaviour
|
||||
|
||||
}
|
||||
|
||||
public void PlayAgain()
|
||||
public async void PlayAgain()
|
||||
{
|
||||
SceneManagerService.Instance.ReloadCurrentScene();
|
||||
var progress = new Progress<float>(p => Logging.Debug($"Loading progress: {p * 100:F0}%"));
|
||||
await SceneManagerService.Instance.ReloadCurrentScene(progress);;
|
||||
gameObject.SetActive(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -124,7 +124,8 @@ namespace UI
|
||||
// Clear paused flag and broadcast event
|
||||
_isPaused = false;
|
||||
InputManager.Instance.SetInputMode(InputMode.GameAndUI);
|
||||
OnGameResumed?.Invoke();
|
||||
if(resetInput)
|
||||
OnGameResumed?.Invoke();
|
||||
|
||||
Logging.Debug("[PauseMenu] Game Resumed");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user