开头合并

This commit is contained in:
2025-05-14 13:03:08 +08:00
parent 4d34b96154
commit 4120482e88
35 changed files with 12913 additions and 584 deletions
@@ -45,7 +45,6 @@ namespace AibisDream.FixSystem
private void Awake()
{
InitComponentRefs();
}
@@ -53,7 +52,7 @@ namespace AibisDream.FixSystem
{
// 注册数据
StorageSystem.Instance.RegisterData(_data);
// 处理内部索引
_bodyModuleGroup = transform.Find("Body Module Group")?.gameObject;
_headModuleGroup = transform.Find("Head Module Group")?.gameObject;
@@ -62,8 +61,9 @@ namespace AibisDream.FixSystem
{
heatMapController = transform.Find("HeatMapController").GetComponent<HeatMapController>();
}
FixSystemCenter.SystemDic.Register(this);
// 注册Camera
var virtualCam = transform.GetComponentInChildren<ICinemachineCamera>();
CameraKit.Instance.RegisterCamera(CameraEnum.BodyModule, virtualCam);
@@ -199,6 +199,7 @@ namespace AibisDream.FixSystem
default:
throw new ArgumentOutOfRangeException(nameof(moduleState), moduleState, null);
}
// 重新获取ModuleGroup
var root = moduleState == ModuleState.Body ? _bodyModuleGroup : _headModuleGroup;
BodyModules = root?.GetComponentsInChildren<BodyModule>().ToList();
@@ -220,7 +221,7 @@ namespace AibisDream.FixSystem
public class ModuleSystemData : IData
{
public ModuleState moduleState;
public IEnumerator Load()
{
FixSystemCenter.SystemDic.Get<BodyModuleSystem>().SwitchModuleGroup(moduleState);