fix(): 修复重启后切换模式后相机丢失BUG,修复重启后UI绑定失效的BUG,将GameManager移动到Gameplay

This commit is contained in:
2025-10-26 09:56:23 +08:00
parent 95616f8c10
commit 9094b17a3d
7 changed files with 55 additions and 367 deletions

View File

@@ -1,16 +1,20 @@
using UnityEngine;
using Core;
using Script.Gameplay.Input;
using Script.Gameplay.Global;
namespace UI
{
public class StartGameButton : UIBase
{
public string levelName = "Level1";
public void StartGame()
{
ScenesManager.Instance.LoadGameplay(levelName);
InputManager.Instance.SetCursorState(false,CursorLockMode.Locked);
if (levelName == "Level1")
GameManager.Instance.StartGameplay();
else if (levelName == "Test")
GameManager.Instance.StartTest();
InputManager.Instance.SetCursorState(false, CursorLockMode.Locked);
}
}
}