(client):feat:添加对列表定义读取的支持,ui管理器将对没有键的窗口也进行统一管理

This commit is contained in:
m0_75251201
2025-07-20 15:21:21 +08:00
parent 2e74833a18
commit 9dcc67d710
77 changed files with 2158 additions and 3750 deletions

View File

@ -11,11 +11,6 @@ namespace UI
public Prefab.TextPrefab textTemplate;
public Prefab.ButtonPrefab buttonTemplate;
void Awake()
{
actionButton = KeyCode.F1;
}
void Start()
{
@ -27,6 +22,9 @@ namespace UI
InitEvent();
InitCharacter();
}
void InitEvent()
{
var title = InstantiatePrefab(textTemplate, menuContent.transform);
@ -42,7 +40,7 @@ namespace UI
void InitCharacter()
{
var title = InstantiatePrefab(textTemplate, menuContent.transform);
title.Label = "点击切换人物";
title.Label = "生成人物";
var defList = Managers.DefineManager.Instance.QueryNamedDefinesByType<Data.CharacterDef>();
foreach (var def in defList)

View File

@ -0,0 +1,24 @@
namespace UI
{
public class EscUI:UIBase
{
public void ContinueButton()
{
Base.UIInputControl.Instance.CloseWindow(this);
}
public void ExitButton()
{
#if UNITY_EDITOR
UnityEditor.EditorApplication.isPlaying = false; // 停止编辑器播放模式
#else
Application.Quit(); // 关闭游戏
#endif
}
public void SettingsButton()
{
}
}
}

View File

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 7eac7c56e1474c4ea646c0a408d293a3
timeCreated: 1752932683

View File

@ -0,0 +1,8 @@
namespace UI
{
public class PauseUI : UIBase
{
}
}

View File

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: bcc7e9d015ee465684be520b65c2e182
timeCreated: 1752932641