Week 40

This is a weekly recap of the goings-on in my professional life – to keep track of what I’m doing and to give you a peek at what it’s like being an independent creative.

Things really started coming together on my game this week. I’d been living mostly in a test environment last week where every game element was thrown together in one space, so when I created a proper scene with some nice background art it felt like things were going somewhere.

Early in the week I did some resolution tests, and uprezzed and tweaked the characters. I was pretty satisfied with the designs I had made but those were still considered placeholder so not nearly high enough resolution to use in the game, so I had to repaint the edges to tighten things up.

On thursday I sketched out the rest of the locations, and finally got some dialogue in the game so it actually started to feel like a game. It was time to make build 0.2. I also wrote a post explaining deltaTime for some guys on the Idle Forums, an elusive and abstract concept in programming.

On friday I had lunch with Niels ‘t Hooft to catch up and share our current projects. It’s great to chat with someone who shares your passion for a certain thing. After that I squashed some bugs and tightened up some UI elements then left everything be for the Kingsday holiday weekend.

Explaining deltaTime

The concept of ‘Delta Time’ took me the longest time to figure out. It’s a concept in computer programming that helps make sure that every user has the same experience regardless of the clockspeed of their machine. This is especially useful in game development, where you don’t want the player on an older machine being inherently worse than the player on a state-of-the-art machine.

I still have to think really hard when I explain it to someone but it’s basically like this:

Take one second of gameplay from your game and imagine it as a white picket fence.

Each fencepost represents a frame, a still image, so in a regular game your fence would have 30 posts. (30 fps)

If your computer is slower, there are less posts in your fence. This makes the space between the posts bigger. That space between the posts is the deltaTime.

So if you want your guy to move from A to B, and it takes 30 frames to get to B, players on 30fps will get there in one second, and players on 15fps get there in two seconds. Obviously unacceptable, especially in a multiplayer game.

So if you multiply the movement speed with the deltaTime (the gap between the frames), you ensure that every player always reaches point B in the same amount of time, regardless of how fast their computer is.

This is because when you run at a lower fps your deltaTime is LARGER, because the GAP between frames is larger, and so each movement gets multiplied with a LARGER number, which means your dude will move FASTER so he can keep up with the intended pace of the game.

Hope that helps.