//------------------------------------------------------------------------- public void update(float tm) { foreach (var i in ListFTask) { if (i.Done()) { ListDoneTask.Add(i); } else { i.update(tm); } } if (ListDoneTask.Count == ListFTask.Count) { IsAllDone = true; if (!CancelTask && AllTaskDoneCallBack != null) { AllTaskDoneCallBack(MapParam); AllTaskDoneCallBack = null; } ListDoneTask.Clear(); ListFTask.Clear(); } }
//------------------------------------------------------------------------- public void cancelTask() { CancelTask = true; ListFTask.Clear(); ListDoneTask.Clear(); }