public System.Collections.IEnumerable CompleteTimeSliced(float maxMillisPerStep) { tracker.timeSlice = TimeSlice.MillisFromNow(maxMillisPerStep); while (true) { if (!coroutine.MoveNext()) { yield break; } while (!coroutine.Current.IsCompleted) { yield return(null); tracker.timeSlice = TimeSlice.MillisFromNow(maxMillisPerStep); } coroutine.Current.Complete(); if (tracker.timeSlice.expired) { yield return(null); tracker.timeSlice = TimeSlice.MillisFromNow(maxMillisPerStep); } } }