Hi, I have some troubles making a loading bar for the progress of a level loading.
I know I can use Application.LoadLevelAsync to load a level and get the progress of loading, but for a reason the variable “progress” of the AsyncOperation always returns 0, and skips to 1 until it loads the entire scene.
Is there another way to make a level loading bar with Unity or to get the progress of the loading in order to display a bar that shows it?
Thanks =)
There isn’t a way, no. You can make an animated progress indicator, but not a progress bar as such.
–Eric
Wait, so what is the purpose of the AsyncOperation.progress field?
I’m pretty sure i’ve seen unity projects out there that feature loading screens with their progress bars… So it must be possible, there’s gotta be some trick to it…
I reckon this Async loading thing is meant for web deployment… Could it be related to not having the assets placed in the StreamingAssets folder, or because it’s running locally?
Cheers
Hopefully someday it will have a meaningful return value.
You haven’t seen it, and there’s no trick. What you might have seen is web players using Application.GetStreamProgressForLevel, which does work, but is for web players only.
Nope, see above.
–Eric