Hi Jim, Yes, this is the basic idea.
When creating an adjustable loop without hard-coding the timing as you are doing below, you would simply calculate the time your loop has taken to process all of its instructions for a particular frame and then sleep for an appropriate time until your next frame should happen. Also, you would check to see if your instructions took longer than a maximum allowed time for a single frame so you can skip or drop frames if necessary. This is also important for keeping events consistent. HTH! Smiles, Cara :) --- View my Online Portfolio at: http://www.onemodelplace.com/CaraQuinn Follow me on Twitter! https://twitter.com/ModelCara On Aug 1, 2013, at 3:24 AM, Jim Kitchen <[email protected]> wrote: Hi Cara, Yeah, frame rate is more of a video games term, but still applies, or is the same thing for audio games, right. Just my bit of basic pseudo code below Main game loop1: start time = get tick count get keyboard and or joystick input adjust placement and sounds of objects check for collisions etc wait until get tick count > start time plus .05 seconds goto main game loop1 Just very simple, but that is pretty much how it goes right? BFN Jim I like Visual Basic 6.0 because I can not C. [email protected] http://www.kitchensinc.net (440) 286-6920 Chardon Ohio USA --- Gamers mailing list __ [email protected] If you want to leave the list, send E-mail to [email protected]. You can make changes or update your subscription via the web, at http://audyssey.org/mailman/listinfo/gamers_audyssey.org. All messages are archived and can be searched and read at http://www.mail-archive.com/[email protected]. If you have any questions or concerns regarding the management of the list, please send E-mail to [email protected]. --- Gamers mailing list __ [email protected] If you want to leave the list, send E-mail to [email protected]. You can make changes or update your subscription via the web, at http://audyssey.org/mailman/listinfo/gamers_audyssey.org. All messages are archived and can be searched and read at http://www.mail-archive.com/[email protected]. If you have any questions or concerns regarding the management of the list, please send E-mail to [email protected].
