Thank god for Sticky Notes

Without that app i would never had been able to keep track of what I’ve done that day.

Today we worked in the Game room most of the day and while i ran into several problems i still feel like i did pretty well. First of all i fixed an issue where guards would still cause the player to reset on contact even after being killed, due to them having their own bool to check whether they were removed or not as well as the same bool in their Gameobject class. After i removed this bool they only had the bool from their inherited GameObject class left which worked as it should.

The next issue i ran into was the player being unable to interact with keycards dropped by guards, this was because the keycard was added to the Level-class’ list of objects which does not include the player who is updated from the list of objects in the Engine class. For some reason we have two functions for updating everything. My solution to this was to in the Engine class add the PlayerObject into the Level’s list of objects, this worked well enough but with the side effect of the player being updated twice every frame, causing it to move at double speed, I will discuss this with Oliver and see if there is any way to merge the two update functions. I was also unable to remove either of the update functions as one was handling the update of the player and one caused exceptions when it was removed.

After this i put in and tested the door object and made it remove itself from the level if the player interacted with it while carrying a keycard. The most simple thing i did today.

Right now i am stuck on attempting to make weapons throwable, the two main issues i’m having is that my function for calcualting the direction is wrong somehow and the item flies in a random direction. The other issue is that it needs to detect when colliding with a wall and stop moving. I considered making the items their own class as they have a couple of variables not used by any other game object. I might do that tomorrow if there is a need.