update core 完善核心游戏循环

This commit is contained in:
2024-10-26 21:50:45 +08:00
parent a5ae3c79dc
commit 6c3690c802
7 changed files with 61 additions and 90 deletions

View File

@@ -17,6 +17,7 @@ using IcecreamView;
using StateSystem;
using UniFramework.Event;
using UnityEngine;
using UnityEngine.Playables;
using Views;
using Object = UnityEngine.Object;
@@ -33,10 +34,11 @@ namespace Game
public class RoomManager : MgrBase<RoomManager>
{
private EventGroup _eventGroup;
private GameFsm _gameFsm;
private RoomGlobalData _roomGlobalData;
public bool HasLock { get ; private set; }
private EventGroup _eventGroup;
private GameFsm _gameFsm;
private RoomGlobalData _roomGlobalData;
public PlayableDirector _BossSceneDirector;
public bool HasLock { get ; private set; }
public GameState CurrentGameState => this._gameFsm.CurrentState;
@@ -109,6 +111,13 @@ namespace Game
var scenePart = AssetManager.Instance.LoadAsset<GameObject> (loadName).GetComponent<ScenePart> ();
var instantiate = Object.Instantiate (scenePart, MapContent.Instance.transform, true);
MapContent.Instance.SetPart (instantiate);
if (partIndex == 3)
{
//额外加载boss场景
var bossScene = AssetManager.Instance.LoadAsset<GameObject>("");
var gameObject = Object.Instantiate (bossScene , MapContent.Instance.ScenePart.SuccessProp.transform.position , Quaternion.identity);
this._BossSceneDirector = gameObject.GetComponent<PlayableDirector> ();
}
}
#region