using Fie.Core; using Fie.Manager; using Fie.Scene; using GameDataEditor; using System.Collections.Generic; using UnityEngine; namespace Fie.DebugUtility { public class FieDebugGameSceneBoot : MonoBehaviour { [Range(1f, 3f)] [SerializeField] private int playerNum = 1; [SerializeField] private List _debugCharacters = new List(); [SerializeField] private List _debugCharactersIntelligenceTypes = new List(); [SerializeField] private List _debugCharactersNames = new List(); [SerializeField] private List _debugSkills = new List(); private void Awake() { if (!FieBootstrap.isBootedFromBootStrap && _debugCharacters.Count == _debugCharactersIntelligenceTypes.Count && _debugCharactersIntelligenceTypes.Count == _debugCharactersNames.Count && _debugCharacters.Count == _debugCharactersNames.Count) { PhotonNetwork.offlineMode = true; PhotonNetwork.InstantiateInRoomOnly = false; FieManagerFactory.I.currentSceneType = FieSceneType.INGAME; FieManagerBehaviour.I.StartUp(); FieManagerBehaviour.I.StartUp(); FieManagerBehaviour.I.StartUp(); FieManagerBehaviour.I.StartUp(); FieManagerBehaviour.I.nowPlayerNum = playerNum; FieManagerBehaviour.I.StartUp(); List list = FieMasterData.FindMasterDataList(delegate (GDESkillTreeData data) { return _debugSkills.Contains((FieConstValues.FieSkill)data.ID); }); for (int i = 0; i < playerNum; i++) { _debugCharacters[i].intelligenceType = _debugCharactersIntelligenceTypes[i]; if (list != null && list.Count > 0) { FieSaveManager.debugSkills = list; } FieManagerBehaviour.I.SetUserName(i, _debugCharactersNames[i]); FieManagerBehaviour.I.SetUserCharacterPrefab(i, _debugCharacters[i]); } } } private void Start() { FieManagerBehaviour.I.StartUp(); } } }