Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - HylianEvil

Pages: [1]
1
General / Clock and openGL
« on: April 25, 2012, 11:42:08 pm »
Hello, I'm pretty new here and new to game programming in general.
What I'm trying to do is make a game in openGL/SFML 1.6 and I realized that I need
a clock to have the same experience independent of how fast someone's computer is.

What I'm doing is something like this

void Sprite::updateX(float tempX)
{
   x += tempX*Clock->GetElapsedTime();
}

I've noticed there's a stutter in my animations that happens predictably with time.

Does anyone know a good tutorial on setting up a clock for use in a game or does anyone know how to properly use the clock feature to get rid of this stutter?

Pages: [1]