private void TaskFinshed(CoroutineTask task, bool IsFinsh) { if (CoroutineTasks.Contains(task)) { CoroutineTasks.Remove(task); } }
public CoroutineTask StartCoroutine(IEnumerator coroutine) { CoroutineTask task = CoroutineModel.Instance.StartCoroutineTask(coroutine); task.Finished += TaskFinshed; CoroutineTasks.Add(task); return(task); }
public CoroutineTask StartCoroutine(IEnumerator coroutine) { CoroutineTask task = new CoroutineTask(coroutine); task.Finished += TaskFinished; AllTask.Add(task); MyCentorl.StartTask(task); return(task); }
/// <summary> /// 任务完成通知 /// </summary> public void TaskFinished(CoroutineTask Task, bool IsFinish) { AllTask.Remove(Task); }
public void StartTask(CoroutineTask Task) { Manager_ManagerModel.Instance.StartCoroutine(Task.CallWrapper()); }
public void StopCoroutine(CoroutineTask task) { task.Stop(); }