- Home /
Loading bar with visual bar
I no absolutely nothing on this part of unity, i now application.loadlevel and thats it! how do I put together a loading bar scene with a visible bar?
PLEASE ANSWER IN JAVA SCRIPT! I suck at C#!
ha ha ha very funny, Just trying to make myself as clear as possible.
Answer by MikezNesh · Jun 28, 2010 at 01:02 PM
This section is for a time based progess bar: (Next section on more complicated synced system)
Check this post out for the Progress bar.It is Very helpful. Below I will show how to change level when the bar is loaded.
http://answers.unity3d.com/questions/328/how-do-i-make-a-progress-bar
Now I will show how to load level when the progress bar is done loading....
Add this in the Update function...
if(progress >= 1) { Application.LoadLevel "levelname"}
For a more syncronized one try this:
http://answers.unity3d.com/questions/6140/how-to-use-loadlevelasync-to-make-a-progress-bar
Hope this helps.
After adding this code drag a texture in for the code to use. Unfortunately the background matches the loading bar. So to get rid of the background bar, just comment out the first GUI.DrawTexture piece of code. This should make the background bar dissapear. Then you can add your own bakground bar image behind the loading bar to make it look nice.
How does this update the progress bar while the level is loading? It looks like it just counts up to 100% and then loads the level whereas what I want to do is show updating progress while loading the level. Am I missing something?
The loading bar is just to give time for the level to load.... all games are like that ( I think). I'm not quite sure about actually updating when the level loads.... but giving time should be enough.
Your answer
Follow this Question
Related Questions
player prefs, problem but no problem??? 1 Answer
Application.CommitSuicide? 3 Answers
Setting variable as type "Scene" 4 Answers
level loader script wont work 1 Answer