Newsletter #56 - Clock Problem

A problem between the clock system and fixed timestep updates, new sketches, a suggestion for SAO.


There is no news to report this week.

From the Programmer
Written by Invisible

Earlier this week I realized that there was a problem with the clock system in the engine. In order to time various events, the game uses a "clock". The state update code would use either GetTickCount() or QueryPerformanceCounter() (indirectly through a system that wrapped them). This in itself works fine, but the problem occurs due to the way the state is updated. I use a fixed timestep, which means that when the state is updated, it is being updated for a specific point in time which is most likely in the past. So the counter provided by the previously mentioned functions will be slightly incorrect for the time that the state is updating for. The problem gets worse after a "lag" spike (the program freezes for a certain amount of time for whatever reason), since the main loop will attempt to catch up and update all of those missed states at once.

The problem has been fixed by using a 0 based counter that is set to the correct time for the update that is currently being performed. The counter represents how many milliseconds are between the start of the program and the current update. The update code can access this counter using a function supplied by the core system. This also ensures that there is only one counter value throughout the update, which was not true before.

Artist's Easel
Written by GreyKnight

iScribble Sketches #14

(Click to enlarge)

(Click to enlarge)


Community Spotlight
Written by Jay

This week, an SAO player known as RageMan1990 suggested that a boss-like monster be added to SAO in the next update. Though it's not an original idea, the thought of having a boss brought along a discussion of what a boss would be like. Whether or not a strong boss creature is added in the future, many players will always have hopes that one will one day appear.

Latest Jobs


Vancouver, BC, Canada

Bladework games

Remote (United States)
Senior Gameplay Engineer

University of Canterbury

Christchurch, Canterbury, New Zealand
Academic in Game Arts and Animation

Fred Rogers Productions

Hybrid (424 South 27th Street, Pittsburgh, PA, USA
Producer - Games & Websites
More Jobs   


Explore the
Advertise with
Follow us

Game Developer Job Board

Game Developer


Explore the

Game Developer Job Board

Browse open positions across the game industry or recruit new talent for your studio

Advertise with

Game Developer

Engage game professionals and drive sales using an array of Game Developer media solutions to meet your objectives.

Learn More
Follow us


Follow us @gamedevdotcom to stay up-to-date with the latest news & insider information about events & more