Feb 27, 2016

Project Update - Almost Done

So I've made lots of progress on my game. It's pretty much completed with very few bugs, and no game-breaking bugs. Crashes are very rare and are fixed with a simple restart. There are two things I'd like to go into in this post: the way I used collision detection, and the audio I used for this project.

There were a couple resources for collision detection posted in Piazza (I even posted one of them) but in the end I decided to go with a method I have used in the past. In my IMM 120 class, I was taught a method to check if a point is inside of a rectangle. This is useful, in most cases, for checking to see if the cursor is inside of a shape, but I changed it to work for my use case, It resulted in this gigantic, poorly-coded, bad practice if statement:
It's not pretty, but it works. I haven't found a case yet where the squares touch without triggering the gameOver variable. I'm sure there's a better way to do this, in fact I'm positive there is, but this method worked for me.

My game's a little bare, graphics wise. I felt that I didn't really need too many distractions, since the game is all about the two players. I did however want to add in some audio. I found a pretty cherry playground-y song that I thought works well for tag (in fact, the song is called Tag Game Song). It fits the game perfectly in my opinion.