Looking at the date of my last blog post and comparing it to today’s date, I took longer off then I had previously intended. I blame this entirely on Valve and their Team Fortress 2 game, which I have become addicted to playing again.
Today however I did make some more progress with the game, I decided to implement the code for the boss monsters, and this involved creating unique AI for the boss as well as its own separate set of projectiles. I was having an issue earlier today that took me a few hours to overcome, basically I was telling the boss’s fireball AI that if it collides with the player, damage the player. When testing the code it wasn’t registering at all and the fireballs were passing straight through the player. After a couple of hours of shouting at my screen it dawned on me, I had this problem before.
Turns out that I needed to go back to the player class and add fireballs to the list of entities that the player can collide with, once I added this in all was right in the world, well at least in my code. The moral of this story is that I should really comment my code better, a lot better.