public void NextTask() { if (curTask == null) { return; } IGuideManagerData data = curTask.GetIGuideTaskData(); curTask = null; LoadUiResource.DestroyLoad(GameConstDefine.UIGuideRestPath); if (data.NextTaskId.ElementAt(0) == -1) { //ask all end HolyGameLogic.Instance.EmsgTocsAskFinishUIGuideTask(1, data.TaskId, 1); data = null; StartTriggerTask(); SetTaskIsFinish(true, true); return; } // ask end HolyGameLogic.Instance.EmsgTocsAskFinishUIGuideTask(1, data.TaskId, 0); for (int i = 0; i < data.NextTaskId.Count; i++) { SetTaskId(data.NextTaskId.ElementAt(i)); } data = null; }
public void SetCurTask(IGuideTaskList task) { curTask = task; for (int i = 0; i < currentCheckTask.Count; i++) { if (currentCheckTask.ElementAt(i) == curTask) { return; } currentCheckTask.ElementAt(i).Clean(); } currentCheckTask.Clear(); }
public void SetTaskId(int taskId) { for (int i = 0; i < currentCheckTask.Count; i++) { if (currentCheckTask.ElementAt(i).GetTaskId() == taskId) { return; } currentCheckTask.ElementAt(i).Clean(); IGuideTaskList task = currentCheckTask.ElementAt(i); task = null; } currentCheckTask.Clear(); IGuideTaskList iTask = new IGuideTaskList(taskId); iTask.OnEnter(); currentCheckTask.Add(iTask); }
public void RemoveTriggerTask(IGuideTaskList task)// if one trigger task finish ,remove update { triggerTaskList.Remove(task); task = null; }
public IGuideTask(IGuideTaskList parent, int id) { taskId = id; iParent = parent; }