/// Garbage free static public IYieldInstruction DoUpdateUntil(this object target, Action updateHandler, Func <bool> pConditionFunc, float fTimeOut = float.PositiveInfinity) { _WaitConditionFunc pWaiter = CoroutineMgr._Instance._waitConditionPool.Get(); pWaiter.SetParams(pConditionFunc, fTimeOut, updateHandler); return(pWaiter); }
internal void _FreeConditionWaiter(_WaitConditionFunc pWaiter) { Debugger.Assert(pWaiter.GetRef() == 0); _waitConditionPool.Free(pWaiter); }