Advertisement

Counters vs Timers

Started by November 09, 2000 03:25 PM
0 comments, last by Allmight 24 years ago
Im currently progging on a small Demo and have encounterd an obious problem. Right now i am using counters to decide when things are about to happen, and how much things should be rotated etc. I found a big drawback in that method. I am progging my demo on a PIII 800MHz with a Geforce2 GTS Gfx card. When i run it on a friends computer that is only 433MHz with a TNT2 it is very slow. First i though it had to do with my code requiring too much of the computer or the computer had some problem, so i tested on another computer witht the same result. After some thinking i came to the conclusion that none of the above is the true. He has a slower computer, that means it does''nt run the program as fast as mine wich in turn make the counters to increase more slowly. I hear you say, yeah of course it does smartass Well, i can be slow sometimes Well, that leaves me a problem. How the heck am i to proceed? Timers sounds like a solution, but what type of timer. One that is based on system time, or one that gets called at certain time intervalls? I want the program to run at the same speed on all computers, given the computer can handle it of course. I am open on sugestions from you, fellow coders. Thanks in advance... ( Allmight )
-------------------------------------------------Founder and DirectorAllSoft Studios
timers are a solution but its not the solution u want
just time how long the last frame took to render and update the next frames vars based on that
eg check the winswapextension demo on me site

http://members.xoom.com/myBollux

This topic is closed to new replies.

Advertisement