Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

custom loading bar

Discussion in 'iOS and tvOS' started by cbodapati, Feb 14, 2010.

  1. cbodapati

    cbodapati

    Joined:
    Oct 13, 2008
    Posts:
    13
    Hi,

    I would like to know if I can show a custom loading bar while the level is loading.

    Im using unity IPhone Pro.

    thanks,
    Srikanth.
     
  2. HonorableDaniel

    HonorableDaniel

    Joined:
    Feb 28, 2007
    Posts:
    2,970
  3. PancakeCircus

    PancakeCircus

    Joined:
    Oct 9, 2009
    Posts:
    78
    bummer eh?

    i ended up just adding a simple scene with the words "Loading" and "Wait you impatient bastard" on it that is loaded before the gameplay scene so at least it doesn't look like the game crashed. That's my simple minded solution.
     
  4. cbodapati

    cbodapati

    Joined:
    Oct 13, 2008
    Posts:
    13
    hmmmmmmm I hope it gets better soon.
     
  5. mudloop

    mudloop

    Joined:
    May 3, 2009
    Posts:
    1,094
    I read somewhere that Unity Wii supports this, and that they plan to port it over to Unity iPhone - but I'm not entirely sure.
     
  6. SavaB

    SavaB

    Joined:
    Feb 11, 2010
    Posts:
    39
    I suppose it's possible through scripting, by using different threads. If one thread changes a value, and the other one changes the width of the mask of a bar by that value, i think it might be possible.
     
  7. mudloop

    mudloop

    Joined:
    May 3, 2009
    Posts:
    1,094
    Nope, because loading is done in the time of one frame.

    What you could do is split up the scene you want to load in multiple scenes, and load them additively, and each time one gets loaded, it updates the bar, and it loads the next part. It would involve a lot of work though, and the loading bar still wouldn't be very smooth. And I suppose loading times will increase as well.
     
  8. SavaB

    SavaB

    Joined:
    Feb 11, 2010
    Posts:
    39
    i thought it was possible to get the byte array of an object/file/whatever. So it also must be possible to loop through the bytes while loading, and adjust your loading bar by the bytearray.length/bytearray-position
     
  9. mudloop

    mudloop

    Joined:
    May 3, 2009
    Posts:
    1,094
    Okay, that might work, presuming you can create all your objects from files. It will work for textures, etc, but some other stuff might be trickier (prefabs, for instance). I'm not sure.
     
  10. minevr

    minevr

    Joined:
    Mar 4, 2008
    Posts:
    1,015
    A scene to Null scene to B scene... :D

    but...is dead~~
     
unityunity