Journal Entry 2
Activity:
- implemented water shooting as a way to extinguish fires
- added place where player can refill water
- made the amount of water player has affect his speed
- added game over screen when player touches fire
Notes:
Setting up the water shooting was more tricky than I expected. I made the water shoot in the direction of the mouse but this was working very inconsistently. The problem was I wasn't converting the "camera coordinates" to "world coordinates". After I solved this problem I encountered another one: even though I was normalizing the speed of the water, the speed kept varying. Some debugging later I realised that calculating the speed from the position of the mouse made the water to sometimes move in the unseen Z dimension.
When making the place where players refills water (hydrant/well) I needed to detect collisions with the player but didn't want them to collide - I had to learn how to use the "IsTrigger" option of colliders. I also learned how to make a game over screen.
Invested hours:
- programming new mechanics: 4 hours
Files
Get Project C
Project C
mff-gdintro-2023-t
More posts
- Journal Entry 5May 20, 2023
- Journal Entry 4May 17, 2023
- Journal Entry 3May 14, 2023
- Journal Entry 1May 01, 2023
Leave a comment
Log in with itch.io to leave a comment.