Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Making a loading bar

Author
Message
Oster200
13
Years of Service
User Offline
Joined: 21st Jan 2011
Location:
Posted: 17th Feb 2012 16:21
How would i go about making a loading bar for a FPS 3d game?

I dont know where to start making one. i want it so it tell you how much longer you have to wait.

Sorry i dont have much info for you but like i said i dont know where to start. like i can make the rectangle i just dont know how to make it move to how many more 3d object are left to load.

California is a fine place to live - if you happen to be an orange. - Fred Allen
If you die in an elevator, be sure to push the Up button.
vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 17th Feb 2012 18:01
Unless your game takes more than 20 seconds loading you dont need one

If it takes.. you can make a var like progress and then as you load something you put: progress += 10;

Then show that progress in a way using the bar like dbRect() with the X being a point + the progress .

Its kinda old school but its not that hard.

C++ Medium 3.5/5
www.oryzhon.com <-- My company's website (W.I.P)
xix psycho xix
16
Years of Service
User Offline
Joined: 15th Sep 2008
Location:
Posted: 17th Feb 2012 18:08
haha old school yeah cuz if you do a basic one like that the graphics come out looking like windows 1.0 lol. Oh wait, that's what my GUI library currently looks like!!! Lololol
Hassan
15
Years of Service
User Offline
Joined: 4th May 2009
Location: &lt;script&gt; alert(1); &lt;/script&gt;
Posted: 17th Feb 2012 19:31 Edited at: 17th Feb 2012 19:33
want to make it look prettier? just put a sprite on top of it that covers the whole loading area, your dbRect might be changed to a sprite with stretching because it could be drawn over your "style"-sprite.

or even better:
create sprites that could be aligned in a circular path to form a circle, for demonstration sake, imagine a pizza with 8 pieces, you will just do this: (algorithm)
1- know & store the total number of things to load
2- float fProgressForNextPiece = numThings / 8 (8=pizza pieces)
3- current progress < numThings? go to 4, else, we're done
4- load something, progress++
5- draw <progress / fProgressForNextPiece> sprites
6- sync
7- go to step 3

and for step 5, every time you create a new sprite, do something like:


though there's nothing like "how to make a loading bar", every game has its own way, everyone tries to be creative with his idea, your best choice is to make it something relative to your game itself

vitinho444
14
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 17th Feb 2012 20:02
@xix
dont worry my graphics are made in paint xDDDDDDDDDDDDDDDD

Im thinking in making them better but paint rules anyway

C++ Medium 3.5/5
www.oryzhon.com <-- My company's website (W.I.P)
Oster200
13
Years of Service
User Offline
Joined: 21st Jan 2011
Location:
Posted: 18th Feb 2012 05:41 Edited at: 18th Feb 2012 05:42
Alright thanks i will have to try out both your ideas.

What does Star Trek and toilet paper have in common?

Login to post a reply

Server time is: 2024-11-22 23:59:59
Your offset time is: 2024-11-22 23:59:59