It’s still early in March but my March game is complete. In February I built an extremely simple platformer called Color Cube. In March I’ve built on that experience and produced a larger more complex platformer called Space Cadet.

As an experiment I built Color Cube using zero artwork. I didn’t repeat that in March with the result that Space Cadet is actually not bad to look at. All the art is provided courtesy of Kenney Vleugels. Thanks Kenney.

My previous games have all run at a fixed frame rate. For Space Cadet I decided to try my hand at variable timing. This means that on faster hardware the game can potentially run at a much higher frame rate. This comes at the expense of slightly increased complexity as all movement and animation must take into account how much time has passed since the last frame.

On the plus side variable timing made it easy to manipulate the passage of time. Specifically, in Space Cadet the goal of the game is to collect mushrooms. I needed something for the player to collect, Kenney’s platformer art pack had mushrooms, so collectable fungus it was. Each time you pick up a mushroom time slows down then slowly returns to normal. It’s a little bit gimmicky but kind of cool. If I feel so inclined I might add collectable pills that cause time to speed up as that would seem to fit the theme.

This is also the first game I’ve that isn’t confined to a single screen. Creating a larger level and scrolling around within it was surprisingly simple to implement. The larger levels however meant that I really needed a way to edit levels that didn’t involve hand coding them. I came up with a fairly simple solution although I’m sure its been done before. This is the map for level 1.


Each level is a small png image. 1 pixel translates to one tile in the game world. Black pixels are terrain, yellow pixels are something for the player to collect and green pixels are monsters. The game code decides what to actually display for each of these things. It doesn’t give you a huge amount of control from within the map however it means that I could use an image editor as my map editor. Being able to alt tab into Gimp to edit a level was really cool and made it possible to quickly produce a decent sized set of levels.

As the levels are substantially bigger than the screen this is the first time I’ve felt the need to not simply take everything and blit it all. It’s not obvious to the player but I’m figuring out what tiles are on screen and only blitting those tiles. This radically cut the number of blits. I’m sure there are plenty of other efficiencies I could introduce but there didn’t seem to be any particular need. I’m trying to avoid getting drawn into spending lots of time tinkering under the hood unless I have a bona fide need.

The on screen character in Space Cadet is quite a large individual who is taller than he is wide. He spans around half a dozen tiles depending on his exact position. I was recently playing Super Meat Boy and noticed that the character is square and slightly smaller than a single tile. I think I’ll go for this approach if I make any more platformers. Having a large character makes the character feel big and a bit clumsy relative to the world around him.

Space Cadet was a lot of fun to make. Hopefully it’s at least a little bit of fun to play.

It’s available from my github account at git://

There is also a Space Cadet Windows executable.

Currently I’m thinking that April will be my last Pygame game. In May I’ll try my hand at html 5.