private static CoroutinePlus StartCoroutine(Yielder yielder) { var routine = new CoroutinePlus(yielder); StartCoroutine(routine); return(routine); }
internal CoroutinePlus Then(Yielder next) { if (_hasRunAndFinished) { return(StartCoroutine(next)); } if (_then == null) { _then = new Queue <CoroutinePlus>(); } var promised = new CoroutinePlus(next); _then.Enqueue(promised); return(promised); }
public static void StartCoroutine(CoroutinePlus coroutine) { coroutine.SetCoroutine(Executor.StartCoroutine(coroutine.Run())); }
private static CoroutinePlus CreateCoroutine(Yielder yielder) { var routine = new CoroutinePlus(yielder); return(routine); }