feat: Addressables rules/sync tools, UI fixes, AddressKeys update
- Add AddressableRules.cs: single source of truth for prefix->group and prefix->label rules - Add AddressableRuleSyncWindow.cs: scan/fix/export-CSV tool (BaseGames > Addressables > Rule Sync) - AddressableBatchTool.cs: delegate DeriveGroupName to AddressableRules, remove duplicate PrefixGroupMap - AddressKeys.cs: add Labels constants (Preload, Poolable, Enemy, BGM, SFX, Charms, Config, Weapon) - Docs/Standards/AddressablesLabelSpec.md: new label naming & assignment spec - Docs/Standards/AssetFolderSpec.md: update Addressables group strategy section - SplashScreenController.cs: fix MainMenu loading flow - BootFlowSetupWizard.cs / SceneScaffoldTools.cs: scene scaffold fixes - PlayerInputActions: set UI/Point to Pass-Through type - Persistent.unity: add BootSequencer to auto-load MainMenu on play - EditorBuildSettings.asset: register scenes for build Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
8
Assets/_Game/Scripts/UI/MainMenu.meta
Normal file
8
Assets/_Game/Scripts/UI/MainMenu.meta
Normal file
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a81c593ef6b215e4c9752363738c131b
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
11
Assets/_Game/Scripts/UI/MainMenu/MainMenuController.cs.meta
Normal file
11
Assets/_Game/Scripts/UI/MainMenu/MainMenuController.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5e1f947f274273f4c9a5a310fc40a625
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
8
Assets/_Game/Scripts/UI/Splash.meta
Normal file
8
Assets/_Game/Scripts/UI/Splash.meta
Normal file
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a4714b32299804648acbfef71cf9ac81
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -1,5 +1,6 @@
|
||||
using System.Collections;
|
||||
using UnityEngine;
|
||||
using UnityEngine.InputSystem;
|
||||
using BaseGames.Core.Events;
|
||||
|
||||
namespace BaseGames.UI.Splash
|
||||
@@ -35,6 +36,7 @@ namespace BaseGames.UI.Splash
|
||||
[SerializeField] private VoidEventChannelSO _onSplashComplete; // Raise
|
||||
|
||||
private bool _skipRequested;
|
||||
private InputAction _anyButtonAction;
|
||||
private readonly CompositeDisposable _subs = new();
|
||||
|
||||
// ── 生命周期 ─────────────────────────────────────────────────────────
|
||||
@@ -45,10 +47,28 @@ namespace BaseGames.UI.Splash
|
||||
SetAlpha(_splashRoot, 1f, blocksRaycasts: true);
|
||||
SetAlpha(_studioLogoGroup, 0f, blocksRaycasts: false);
|
||||
SetAlpha(_gameTitleGroup, 0f, blocksRaycasts: false);
|
||||
|
||||
// 通配符绑定:捕获任意设备的任意按键/手柄键/触屏按压
|
||||
_anyButtonAction = new InputAction(binding: "/*/<button>");
|
||||
_anyButtonAction.performed += _ => _skipRequested = true;
|
||||
}
|
||||
|
||||
private void OnEnable() => _onSplashStartRequest?.Subscribe(OnStartRequested).AddTo(_subs);
|
||||
private void OnDisable() => _subs.Clear();
|
||||
private void OnEnable()
|
||||
{
|
||||
_onSplashStartRequest?.Subscribe(OnStartRequested).AddTo(_subs);
|
||||
_anyButtonAction.Enable();
|
||||
}
|
||||
|
||||
private void OnDisable()
|
||||
{
|
||||
_subs.Clear();
|
||||
_anyButtonAction.Disable();
|
||||
}
|
||||
|
||||
private void OnDestroy()
|
||||
{
|
||||
_anyButtonAction.Dispose();
|
||||
}
|
||||
|
||||
// ── 入口 ─────────────────────────────────────────────────────────────
|
||||
|
||||
@@ -94,14 +114,6 @@ namespace BaseGames.UI.Splash
|
||||
gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
// ── Unity 输入(任意按键跳过)────────────────────────────────────────
|
||||
|
||||
private void Update()
|
||||
{
|
||||
if (Input.anyKeyDown)
|
||||
_skipRequested = true;
|
||||
}
|
||||
|
||||
// ── 内部工具 ─────────────────────────────────────────────────────────
|
||||
|
||||
private IEnumerator FadeGroup(CanvasGroup group, float from, float to, float duration)
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b14de374a70f8234bb49050dd91c9b6a
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user