Journal Entry 7: Pausing and Refactoring
Date: 16. 9. 2021
My first task today was the implementation of game pausing. After some amount of googling I found out that pausing the game is quite simple, all I had to do is setting the time scale to zero. Everything I did so far seems to be compatible with this approach, but to be sure, I added mechanisms to call custom hooks when pausing and unpausing the game. This will hopefully cover any possible use case that could show up during development. I also wired the button P to pause the game for now.
In the last few days I realized that my code has become a bit messy. I was mostly worried about random constants controlling the game difficulty scattered around the code, so I decided to set aside some bonus time for refactoring. However it took me much longer than anticipated, and I'm still not completely done, there is a bit more work to do mostly regarding walls. All of this time spent should massively simplify implement falling down to another platform once I get to that point.
Files
Get Don't Be Afraid To Fall
Don't Be Afraid To Fall
Status | In development |
Author | Martin Mihálik |
Tags | mff-gdintro-2021-c |
More posts
- Journal Entry 10: Time is upSep 19, 2021
- Journal Entry 9: Change of PlansSep 18, 2021
- Journal Entry 8: Finished Refactoring and Repeating WorldSep 17, 2021
- Journal Entry 6: Walls and Automatic Meteor SpawningSep 15, 2021
- Journal Entry 5: Rubble Collection and Damage SystemSep 14, 2021
- Journal Entry 4: Explosions and RubbleSep 13, 2021
- Journal Entry 3: Fixed Movement and MeteorsSep 12, 2021
- Journal Entry 2: Terrain and Player ControlsSep 12, 2021
- Journal Entry 1: The Design and PlanningSep 10, 2021
Leave a comment
Log in with itch.io to leave a comment.