private void Init() { if (dialogueStructData == null) { dialogueStructData = DataCenter.Instance.GetMetaData <DialogueStructData>(); } if (runtimeTasksData == null) { runtimeTasksData = DataCenter.Instance.GetEntity <TaskMap.RunTimeTaskData>(); } if (iInteractiveState == null) { iInteractiveState = GameState.Instance.GetEntity <IInteractiveState>(); } if (iNowTaskState == null) { iNowTaskState = GameState.Instance.GetEntity <INowTaskState>(); } if (iGameState == null) { iGameState = GameState.Instance.GetEntity <IGameState>(); } if (iNPCSpriteState == null) { iNPCSpriteState = GameState.Instance.GetEntity <INPCSpriteState>(); } }
// Use this for initialization void Start() { runTimeTaskData = new RunTimeTaskData(); runTimeTaskData.OnDeserializedMethod(default(StreamingContext)); List <TaskMap.RunTimeTaskInfo> runtimeTaskInfos = runTimeTaskData.GetAllToDoList(); foreach (var item in runtimeTaskInfos) { item.IsStart = true; item.IsOver = true; } runtimeTaskInfos = runTimeTaskData.GetAllToDoList(); foreach (var item in runtimeTaskInfos) { item.IsStart = true; item.IsOver = true; } runtimeTaskInfos = runTimeTaskData.GetAllToDoList(); foreach (var item in runtimeTaskInfos) { if (item.ID == 4) { item.IsStart = true; item.IsOver = true; } } DebugNowState(); }
void Start() { verticalLayoutGroup = GetComponent <VerticalLayoutGroup>(); iNowTaskState = GameState.Instance.GetEntity <INowTaskState>(); iMapState = GameState.Instance.GetEntity <IMapState>(); GameState.Instance.Registor <INowTaskState>(INowTaskStateChanged); GameState.Instance.Registor <IMapState>(IMapStateChanged); runTimeTasksData = DataCenter.Instance.GetEntity <TaskMap.RunTimeTaskData>(); ShowNowTask(); }
void Start() { npcIDToTalkShowStructDic = new Dictionary <int, TalkShowStruct>(); npcIDToShowObjDic = new Dictionary <int, GameObject>(); iInteractiveState = GameState.Instance.GetEntity <IInteractiveState>(); dialogueStructData = DataCenter.Instance.GetMetaData <DialogueStructData>(); runtimeTasksData = DataCenter.Instance.GetEntity <TaskMap.RunTimeTaskData>(); iGameState = GameState.Instance.GetEntity <IGameState>(); playerState = DataCenter.Instance.GetEntity <PlayerState>(); npcData = DataCenter.Instance.GetMetaData <NPCData>(); }
private void OnEnable() { dialogueStructData = DataCenter.Instance.GetMetaData <DialogueStructData>(); runtimeTasksData = DataCenter.Instance.GetEntity <TaskMap.RunTimeTaskData>(); iInteractiveState = GameState.Instance.GetEntity <IInteractiveState>(); iNowTaskState = GameState.Instance.GetEntity <INowTaskState>(); iGameState = GameState.Instance.GetEntity <IGameState>(); iGameState.PushEnumGameRunType(EnumGameRunType.TaskTalk); showItemList = new List <Transform>(); UIManager.Instance.KeyUpHandle += Instance_KeyUpHandle; InitTalk(); }
public DataCenter() { PlayerState = new PlayerState(); KeyConatactData = new KeyContactData(); RuntimeTasks = new RuntimeTasksData(); gameRunnedState = new GameRunnedState(); RuntimeTaskMap = new TaskMap.RunTimeTaskData(); BusinessmanStates = new BusinessmanStates(); GameRunningStaetData = new GameRunningStateData(); ActionInteractiveStateData = new ActionInteractiveStateData(); SceneStateDatas = new SceneStateDatas(); }
private void Start() { if (NPCDataInfo != null) { if (NPCDataInfo.NPCShowCondition != null) { NPCDataInfo.NPCShowCondition.TimeRangePath = true; NPCDataInfo.NPCShowCondition.TaskCoditionHidePath = false; NPCDataInfo.NPCShowCondition.TaskCoditionShowPath = true; } } if (GameState.Instance != null) { GameState.Instance.Registor <INowTaskState>(CheckTask); runTimeTaskData = DataCenter.Instance.GetEntity <TaskMap.RunTimeTaskData>(); CheckTask(GameState.Instance.GetEntity <INowTaskState>()); } }
private void Init() { if (runtimeTasksData == null) { runtimeTasksData = DataCenter.Instance.GetEntity <TaskMap.RunTimeTaskData>(); } if (iInteractiveState == null) { iInteractiveState = GameState.Instance.GetEntity <IInteractiveState>(); } if (iNowTaskState == null) { iNowTaskState = GameState.Instance.GetEntity <INowTaskState>(); } if (iGameState == null) { iGameState = GameState.Instance.GetEntity <IGameState>(); } }