bool AddStreamAtPath(ref AssetBundleContext context, string assetpath) { if (File.Exists(assetpath)) { IParseDependencyReader reader = AssetBundleTypeGetter.GetDepReader(); if (reader != null) { if (reader.IsAsync) { Block = true; GUpdater.mIns.StartCoroutine(TryRead(reader, assetpath)); } else { List <AssetBundleInfo> list; if (reader.Read(assetpath, out list)) { context.Cache.Load(list); ListPool <AssetBundleInfo> .Release(list); } return(true); } } } return(false); }
bool AddPersistentAtPath(ref AssetBundleContext context, string assetpath) { if (File.Exists(assetpath)) { IParseDependencyReader reader = AssetBundleTypeGetter.GetDepReader(); if (reader != null) { List <AssetBundleInfo> list; if (reader.Read(assetpath, out list)) { context.Cache.Load(list); ListPool <AssetBundleInfo> .Release(list); } return(true); } } return(false); }