public IABLoader(LoaderProgrecess tmpProgess, LoadFinish tmpFinish) { commonBundlePath = ""; bundleName = ""; commResLoaderProcess = 0; loadProgress = tmpProgess; loadFinish = tmpFinish; abResloader = null; }
//对外的接口 public void LoadAssetBundle(string bundleName, LoaderProgrecess progreces, LoadAssetBundleCallBack callBack) { if (!loadHelper.ContainsKey(bundleName)) { IABRelationManager loader = new IABRelationManager(); loader.Initial(bundleName, progreces); loadHelper.Add(bundleName, loader); callBack(sceneName, bundleName); } else { Debug.Log("IABManager have contain bundle name==" + bundleName); } }
public void LoadAssetBundle(string bundleName, LoaderProgrecess progress, LoadAssetBundleCallBack callBack) { if (!loadHelper.ContainsKey(bundleName)) { IABRelationManager loader = new IABRelationManager(); loader.Initial(bundleName, progress); loadHelper.Add(bundleName, loader); callBack(scenceName, bundleName); } else { } }
/// <summary> /// /// </summary> /// <param name="bundleName"> Load </param> /// <param name="progress"></param> /// <param name="callBack"></param> public void LoadAsset(string bundleName, LoaderProgrecess progress, LoadAssetBundleCallBack callBack) { //scenceone/load.ld if (allAssets.ContainsKey(bundleName)) { string tmpValue = allAssets[bundleName]; Debug.Log("iab scenceManager ==" + tmpValue + "bundleName==" + bundleName); abManager.LoadAssetBundle(tmpValue, progress, callBack); } else { Debug.Log("Dont contain the bundle ==" + bundleName); } }
public void Initial(string bundle, LoaderProgrecess progress) { IsLoadFinish = false; theBundleName = bundle; loaderProgress = progress; assetLoader = new IABLoader(progress, BundleLoadFinish); //yujie fixed assetLoader.SetBundleName(bundle); string bundlePath = IPathTools.GetAssetBundleWWWStreamPath(bundle); // IPathTools.GetWWWAssetBundlePath()+"/"+bundle; assetLoader.LoadResources(bundlePath); }
public IEnumerator LoadAssetBundleDependences(string bundleName, string refName, LoaderProgrecess progreces) { if (loadHelper.ContainsKey(bundleName)) { IABRelationManager loader = new IABRelationManager(); loader.Initial(bundleName, progreces); if (refName != null) { loader.AddReference(refName); } loadHelper.Add(bundleName, loader); yield return(LoadAssetBundles(bundleName)); } else { if (refName != null) { IABRelationManager loader = loadHelper[bundleName]; loader.AddReference(bundleName); } } }
public void Initial(LoaderProgrecess progrecess) { IsLoadFinish = false; assetLoader = new ABLoader(progrecess, BundleLoadFinish); }
public IABLoader(string _commomBundlePath, string _commomBundleFilePath, string _bundleName, LoaderProgrecess loadProgress = null, LoadFinish loadFinish = null) { bundleName = _bundleName; commomBundlePath = _commomBundlePath; commomBundleFilePath = _commomBundleFilePath; commonResourceLoaderProcess = 0; this.loadProgress = loadProgress; this.loadFinish = loadFinish; abloader = null; }