void Update() { if (Input.GetKeyDown(KeyCode.A)) { Debug.Log(GetType() + " 测试销毁资源"); AssetBundlerManager.GetInstance().DisposeScene(_ScenesName); } }
public static AssetBundlerManager GetInstance() { if (instance == null) { instance = new GameObject("AssetBundleMgr").AddComponent <AssetBundlerManager>(); } return(instance); }
private void LoadAllABComplete(string abName) { UnityEngine.Object tmpObj = null; //提取资源 tmpObj = AssetBundlerManager.GetInstance().LoadAsset(_ScenesName, _AssetBundelName, _AssetName, false); if (tmpObj != null) { Instantiate(tmpObj); } }
void Start() { StartCoroutine(AssetBundlerManager.GetInstance().LoadAssetBundlePack(_ScenesName, _AssetBundelName, LoadAllABComplete)); }