- Home /
LoadLevelAsync / AsyncOperation, isn't helping scene transition
Here's the problem. When I used loadlevelasync it appears to be preloading correctly. I've been doing a lot of testing and was logging the asyncoperation.progress value. The problem was it would get to around .9 and then it would then take longer to load the level than it took to preload. The preload seemed to take like 2 seconds to get from 0 to .9, but at that point my screen freezes and then it takes like 5 seconds for the next level to actually be loaded. I need it to be more fluid than that so I can have an animation playing. I have a 3D model moving around while it's preloading. Once it's done preloading the 3D model stops and then it takes 5 seconds for the next scene to actually load...making it pointless really.
private var async : AsyncOperation;
function Start() {
StartCoroutine(Load());
}
function Load() {
async = Application.LoadLevelAsync("Scan_Scene_Augmented");
async.allowSceneActivation = false;
yield async;
}
function OnGUI(){
if(GUI.Button(Rect(5,100,100,100),"YIP")) {
async.allowSceneActivation = true;
}
}
Answer by shiraz888 · Nov 15, 2013 at 02:25 AM
One thing to note, in my experience, when you set asycn.allowSceneActivation to false, the yield asycn operation will NOT return until the allowSceneActivation flag is set to true (like in your OnGUI statement).
Your answer

Follow this Question
Related Questions
LoadLevelAsync doesn't work as it should 2 Answers
Scene Streaming(Bethesda Style, not an internet question) 1 Answer
Webplayer Freeze / Crash After Facebook Interaction 0 Answers
Loading screen animation is getting stuck for a second randomly when using LoadLevelAsync ! 1 Answer
Loading Bar for Awake Function 1 Answer