in Game Development

January Milestone Progress

It’s been one busy month and I’ve been making lots of progress on my code base. This milestone was on a tighter schedule compared to the last one but I think I’ve managed to get a decent amount of work done. Here is my progress for this milestone. You can read my previous post which contains more details about each item in the milestone.

Milestone Progress

  • Tweening for Stage Objects – Completed!

  • Option State – Completed!

  • XML/YAML Support – Completed!

  • Stage Object Pruning – Completed!

  • Particle effects – Completed!

  • CMake Support for creating functional XCode and VC++ projects – Partially Completed!

  • Refactor all Resource Managers – Completed!

I started this milestone by refactoring all of my resource managers. They are now all based upon a central resource manager that maintains reference counts to resources. This system is much simpler than the approach I was using before which maintained resources in a stack. I also added the ability to reload all resources which allowed me to properly handle cases where the screen size would change and OpenGL would need to reload all loaded textures.

After refactoring all of the resource managers I then moved onto tweening and stage object pruning. Stage object pruning was simple to implement. I just created an object represented the stage, much like the stage used in Flash and then didn’t draw items when they were offstage and created events as objects moved on and off of the stage. Tweening was relatively straightforward as well. The results look fantastic as sprites rotate around any give point, change transparency and more while still having their axis aligned bounding boxes in tact. Animation definitely makes your work feel more alive.

XML library research came next. I decided to use RapidXML because of its speed. I found the interface for RapidXML to not be as friendly as I would have liked. You have to allocate memory for all of the information you pass into it. I also decided to stop supporting yaml-cpp because I could not load a file and modify it without first reading the whole file in and then writing it all out again. After writing an XML Parser object I wrote code and tests for editing the Game Configuration XML file and the key mapping XML file. This resulted in the OptionState being a simple plug and play exercise.

In the last few days I finished off creating the particle system. I decided to use an architecture that was similar to that describe in this article. However I heavily use typedef in order to try and keep the type definitions readable. The end result was fantastic, like animation, particle systems look amazing for such little work. I didn’t flesh out the different effects on the particle system. Mostly because I currently have no practical use for them at the moment.

The one thing that I didn’t complete was writing my CMake files to support Visual Studio and XCode. I got very close to building in Windows except I ran into a few weird linking errors. There are changes to support XCode and Visual Studio but they just haven’t been tested. In order to test stuff out on Windows I had to install and configure pkg-config. Over the last month I reinstalled OSX but haven’t set up all of my libraries. Namely due to this bug.

Here are some screens of my progress over the last month.

It's a bit hard to appreciate but these two images are moving. The top one is moving from left to right with no easing. The bottom one is moving, rotating and scaling with easing.

Option Screen with common options.

Key Configuration Options as based on the key config XML file.

Pretty Particle effects

I’m considering making the next milestone shorter in order to start writing Rotablock. Most of the code now is becoming too specialised so I feel that it’s about time to get cracking on a game. I’ll post details about the next milestone soon.

Write a Comment

Comment