Any sleep function for win32 app? not console app please!

I have created a basic tetris game that I want to draw using windows.h graphics. It works great but the problem with is its too fast to even see a single block, let alone control it. Any sleep or delay function suggestion would be very much appreciated. Do mind that I know about the console Sleep() function and its not what I require for my game.
Sleep() isn't a console function, it's a WinAPI function which can be used by any Windows program, GUI or console.

But timers -- as thomas1955 mentioned -- are more commonly used in GUI programs.

You could also read up about "how to throttle a game loop", e.g.
https://www.mvps.org/directx/articles/writing_the_game_loop.htm

See the "Applying a Throttle" section.

Andy
Topic archived. No new replies allowed.