Journal Entry 4: Explosions and Rubble
Date: 13. 9. 2021
Creating explosions has been easier than expected. Once again I found some free assets on kenney.nl, sliced up the spritesheet created an explosion prefab with SpriteRenderer and CircleCollider set to trigger mode. With a little bit of code I made the explosions to grow made them spawn on meteor impact.
Making Rubble, however, was a bit harder. I want the rubble to interact with the ground but act as a trigger with a player. I settled for a solution with two colliders on different layers and set proper interactions in collision matrix. I had some annoyances with setting the collision matrix for 3D instead of 2D physics engine. Finally, I made the rubble shoot out on meteor impact.
I still have some stuff to figure out regarding explosion and rubble. I have to prevent taking damage twice from the same meteor, once from meteor impact itself and from the explosion as well. This is not going to matter when hitting the player, but will matter once I add walls into the game. Regarding rubble, I still have to implement collection by player.
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 7: Pausing and RefactoringSep 16, 2021
- Journal Entry 6: Walls and Automatic Meteor SpawningSep 15, 2021
- Journal Entry 5: Rubble Collection and Damage SystemSep 14, 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.