|
Hi everybody, I've been looking for some answers for a moment now, and a lot of people seem to have this problem, but I never found any correct answer to that. Basically I just use the code found on the Application.LoadLevelAsync doc page
It does load the level correctly, but it actually doesn't do anything different than the simple Application.LoadLevel; by this, I mean that I'm willing to have a user-friendly animation playing while my level is loading, and it doesn't. Even using the asynchronous loading, the scene just freezes until the new one is loaded. In addition, I want to state that no, the scene being loaded is not heavy at all, so it can't come from a long initialization post level loading. As stated earlier, a lot of people are complaining about that and there is never any answer given, so is it just a bug of Unity's last version or what? Thanks.
(comments are locked)
|
|
Mine seems to work fine and I am on iphone, but I have all the gameObject's turned off in the next scene so as not to fire the Start() on all their scripts which have heavy work loads.... Here is how I do it, where LoadingScreen has a bunch of animated sprites Still not working... The only difference between yours and mine at the moment is that you turn off the gameobjects of the next scene; so I guess the problem comes from here. Though in that case I don't see the point of LoadingLevelAsync() as you actually do all the loading (understand here the activation of your gameObjects that you turned off) afterwards, which just delay the problem. Furthermore, in order to do that, I would have to create all my objects from my next scene into my menu scene, in order to be able to deactivate them, and thus would have a heavy loading at he app start...
Apr 06 '11 at 07:45 AM
Thomas 6
Unlike with Thomas, this solved my issue!! We replaced
Mar 07 '12 at 07:13 PM
Cawas
Seriously... the whole engine stopping while LoadLevelAsync is loading my next level is driving me insane. Has anyone found a solid answer for this? It seems like all these discussions just fizzle out. Here are the specifics of my case:
while(!asyncOpLvlLoad.isDone) { yield return 0; } as opposed to just yielding the async op. No luck. I'd really appreciate any help with this, what a pain in the butt.
Aug 27 '12 at 11:49 AM
rbisso
Thank you for the trick sir!! but my problem is that the application kind of "Lags" when using the LoadLevelAsync... It feels like just using the normal loadlevel. when I check the "progress", it always logs "1" no luck of using it to Lerp the position of my progress bar.. :(
Jan 20 at 11:21 AM
vanofthedawn12
@vanofthedawn even in Unity4, loadlevelasync doesn't work on Editor. Compile and test it, it should work.
Jan 21 at 01:13 PM
Cawas
(comments are locked)
|
|
Well, i haven't used Application.LoadLevelAsync yet, but the only thing that comes to my mind is that you forgot to mark your GameObject with DontDestroyOnLoad. When the loading is finished it will destroy all objects that are not marked with DontDestroyOnLoad and therefore your coroutine will just be erased. Don't forget that coroutines run on a MonoBehaviour-script instance. If the script is destroyed the coroutine will be removed as well. This is a great insight, but I'm having a very similar issue as Thomas and even usin
Oct 10 '11 at 06:04 PM
Cawas
(comments are locked)
|
|
It's been a few years since you asked, but just in case someone is still looking: http://answers.unity3d.com/questions/338000/the-solution-to-asyncoperationprogress.html This page solved the problem. The issue is that AsyncOperation.progress can get rounded to 0 or 1 unless handled carefully. The person in the link simply multiplied the value by 100f. Cheers. -Ryan Thank you, Ryan!!! I'll give this a shot, it still wasn't working for us.
May 21 at 08:25 PM
rbisso
(comments are locked)
|
|
I am searching the answer anywhere, but get nothing now, waha
(comments are locked)
|
|
I agree! I've tried to track the progress of the AsyncOperation and it goes from 0 straight to 1. I have a bigger scene that I am trying to load. There's no way an async load on it should go from 0 to 1. Anyone know what's going on here? Jumping from 0 to 1 has been a known bug since like v2.6, it still loads the level, just doesn't accurately report the normalized progress. This pretty much kills the ability to do progress bars, but the isDone property will be accurate in reporting that the async operation finished. ==
Apr 12 '11 at 08:27 PM
equalsequals
Well it seems to me that instead of just killing the ability to do progress bars, it's killing the entire concept of asynchronous as in the end it just does the same thing as the usual LoadLevel() (unless there is something I missed)
Apr 13 '11 at 07:22 AM
Thomas 6
I have also found this to be the case. Is it reported as a bug?
Oct 21 '12 at 06:39 PM
rbisso
(comments are locked)
|
1 2 next page »

Have you, by any chance, found a solution to this issue? - plus, postouros related: http://answers.unity3d.com/questions/61598/how-to-preload-a-scene-with-progress-bar-so-it-can.html