private static IEnumerator Record_DownloadProgress_Async(LoaderRequest rRequest, UnityWebRequest rWebRequest) { while (!rRequest.IsDone) { UtilTool.SafeExecute(rRequest.DownloadProgress, rWebRequest.downloadProgress); yield return(0); } rWebRequest = null; }
public T Alloc() { if (mStack.Count == 0) { return(UtilTool.SafeExecute(mActionAlloc)); } else { return(mStack.Pop()); } }
private static IEnumerator Record_DownloadProgress_Async(LoaderRequest rRequest, UnityWebRequest rWebRequest) { while (!rRequest.IsDone) { try { UtilTool.SafeExecute(rRequest.DownloadProgress, rWebRequest.downloadProgress); } catch (System.Exception) {} yield return(new WaitForEndOfFrame()); } rWebRequest = null; }
public void Destroy() { if (mStack == null) { return; } foreach (var rItem in mStack) { UtilTool.SafeExecute(mActionDestroy, rItem); } mStack.Clear(); }
public T Alloc() { T rElement = default(T); if (mStack.Count == 0) { rElement = new T(); } else { rElement = mStack.Pop(); } UtilTool.SafeExecute(mActionAlloc, rElement); return(rElement); }