Asset Bundle loading scene issue

Hi,
I am trying to load scene from asset bundle & then loading that scene at runtime. After loading scene I’m unloading the asset bundle using bundle(false). Initially it works good but after one or more attempts its showing me error No Camera is rendering and all the gameObjects are destroyed. I think it unloads before the scene is loaded. Below is my code snippet that I’ve used:
myLoadedAssetBundle = wwwAsset.assetBundle;
string[ ] path = myLoadedAssetBundle.GetAllScenePaths ();
SceneManager.LoadSceneAsync (path[0]);

myLoadedAssetBundle.Unload (false);

I can’t even unload the asset bundle after loading scene as the scene gets changed & above script is destroyed .
I would appreciate any work around for this issue.
Thanks in adv.

Since you’re using SceneManager.LoadSceneAsync, are you waiting for that to finish first before unloading the asset bundle?

Its bit problematic, I want to load a scene but also want it to unload it before switching to that scene. Or unload it from next scene but since the older scene does not exist, I cant unload it, that variable got destroyed.

Well I found the issue… Done using static variable. Thanks !! :slight_smile: