public static void PushFront(Task task, TaskInit func) { TaskInit oInit = task.init; task.init = delegate(){ func(); oInit(); }; }
public static void PushFront(Task task, TaskInit func) { Debug.Log("front...."); TaskInit oInit = task.init; task.init = delegate() { func(); Debug.Log("front init..."); oInit(); }; }
public static TaskSet AddAnimation(this TaskSet set, TweenTask.Maker maker, TaskInit init = null, TaskShutdown shutdown = null) { var tt = new TweenTask( maker ); if (init != null) { tt.init = init; } if (shutdown != null) { tt.shutdown = shutdown; } set.push(tt); return(set); }
public ControlableTask(TaskUpdate updateFunc, TaskInit initFunc = null, TaskShutdown shutdownFunc = null, Action pauseFunc = null, Action continuePlayFunc = null) { _task.update = updateFunc; if (initFunc != null) { _task.init = initFunc; } if (shutdownFunc != null) { _task.shutdown = shutdownFunc; } if (pauseFunc != null) { onPause = pauseFunc; } if (continuePlayFunc != null) { onContiunePlay = continuePlayFunc; } }