IEnumerator TaskKiller(float delay, ETask t) { yield return(new WaitForSeconds(delay)); t.Stop(); }
public void Test() { ETask spam = TaskManagerComponent.instance.CreateTask(MyAwesomeTask()); new ETask(TaskKiller(5, spam)); }
public ETask CreateTask(IEnumerator c, bool autoStart = true) { ETask task = new ETask(c, autoStart); return(task); }