January 2015

Writing a computer game was an interesting experience. It started with the concept of the game. I decided I would try to implement a platformer with the time travelling feature. From there I spent many hours thinking through different parts until I had a general Idea of how the program would work. I thought long and hard about how to implement the time travelling feature, finally deciding that the best way would be to record their velocities in a two dimensional array. Upon attempting to implement this I discovered that it would be easier and more practical to record the input instead of the velocities.

Throughout this project I learned many things. I learned how to use allegro to create a GUI for my game. I also learned how to organize a large program into multiple files and functions. One of the most interesting things I learned how to do and the one I struggled with doing the most, was implementing a collision detection system. I spent a lot of time lying in bed thinking through collisions in my mind, trying to understand how to differentiate between a collision from the side and one from the top. Once I thought I understood how it worked, I started trying to implement it into my code. This proved much harder than I expected. I spent a long time sitting, staring at my computer screen trying to visualize collisions and how the program would interpret them. I would then tweak a line of code, run the program and, after the disappointment of its failure, go back to staring at the screen. One of my proudest moments on this project was when the collision detection finally worked. I also learned how to detect the source of bugs or crashes in my program. I found the key was to print as much information as I could. If my program was crashing, I would print a number after every line in order to determine at exactly which point the crash would happen. If my program was not acting as I expected I would print every variable involved in the operation that was misbehaving.

While writing this program I added a few features that I did not originally expect to add. The first of these was a credits screen which I was inspired to make after seeing the credits sequence at the beginning of Ryan Torrington-Smith’s program. I also added music after Ryan told me how easy it was. It was not very easy. I had to employ help of others because allegro will only properly play sound files with some specific properties that mine did not possess.

One of my favourite parts of this assignment was watching people play my game. It brought me joy to see people enjoy my hard work. It was also amusing to watch people struggle with the levels that I knew exactly how to beat. Sharing my work with others brought me a great sense of accomplishment.

Overall I really enjoyed this project. I feel that I learned a lot and I am very proud of the game that I have made over the past weeks.