Advertisement

FrameTime mystery

Started by December 29, 2000 04:32 AM
1 comment, last by Ecco2000 24 years ago
Ok I''m writting my first pong clone and I have added a PerformaceCounter timer and am using the FrameTime to scale the paddle movement but the paddle seems to move faster when it''s going in the up direction. To test this even further I held down both up and down at the same time and the paddle moved upward at about half of it''s full speed when theoretically it should stay still since i update frametime every frame. if (sysw_keys[VK_UP]) { BluePaddleY = BluePaddleY - 200 * tm_FrameTime; } if (sysw_keys[VK_DOWN]) { BluePaddleY = BluePaddleY + 200 * tm_FrameTime; } "Don''t make me come down there..." -GOD
"Don't make me come down there..." -GOD
Hi!
Post a little more code....The stuff you have already posted is perfectly correct.

Greets, XBTC!
Advertisement
ok nevermind I fixed it i had BluePaddleY as an int instead of float so now it works like a charm.
"Don't make me come down there..." -GOD

This topic is closed to new replies.

Advertisement