/// <summary> /// A routine to wait until this coroutine has finished running. /// </summary> /// <returns>The wait enumerator.</returns> public IEnumerator Wait() { if (_enumerator != null) { while (FeCoroutines.IsRunning(_enumerator)) { yield return(null); } } }
/// <summary> /// Stop this coroutine if it is running. /// </summary> /// <returns>True if the coroutine was stopped.</returns> public bool Stop() { return(IsRunning && FeCoroutines.Stop(_enumerator)); }