Quantcast
Channel: Questions in topic: "loadleveladditive"
Viewing all articles
Browse latest Browse all 102

Load AssetBundle(scene object) after LoadLevel

$
0
0
Hi, all I made two AssetBundle files, one is scene and the other is scene's Object, like following fake code: BuildPipeline.PushAssetDependencies(); { // generate fbx(prefab) AssetBundle BuildPipeline.BuildAssetBundle(...); BuildPipeline.PushAssetDependencies(); { // generate level's AssetBundle BuildPipeline.BuildStreamedSceneAssetBundle(...); } BuildPipeline.PopAssetDependencies(); } BuildPipeline.PopAssetDependencies(); so that the scene AssetBundle file is much smaller to download and load easier, I load scene AssetBundle before scene's objects , like following fake code: IEnumerator LoadFunction() { WWW www = new WWW(...); // download the scene first yield return www; Application.LoadLevelAdditive("scene"); ... // many other operation later if(canVisible){ www = new WWW(...); // download the scene's object at some condition yield return www; www.assetBundle.LoadAsync(...); } } **Problem is** the scene's object is display abnormally, it maybe invisible, if I load the scene's object first (before scene loading), it's right. My method can make scene (Level) load quickly and download scene's objects selectively. **Has any method to refresh current loaded scene(Level) in order to retrieve/reload asset which download/load after scene(Level) has been loaded?** Thanks a lot!

Viewing all articles
Browse latest Browse all 102

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>