Update the Pause menu flow to be slightly less scoffed

This commit is contained in:
Michal Pikulski
2025-10-16 23:19:33 +02:00
parent 09ae4b5ba7
commit b2384269e5
11 changed files with 167 additions and 92 deletions

View File

@@ -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);
}
}
}

View File

@@ -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");
}