OVERVIEW
In this project, I created a simple catching game with my illustrations. I used p5 and p5.play
libraries to create the game interactions and mechanisms.
DEVELOPMENT PROCESS
These are the main steps I took in approaching this project.
Set up development environment with npm
Looked at tutorial code of p5.play library functions
Laid out 3 stages/screens for the game: start, play, and game over
Imported sound, images, and font
- Editing sources to fit the dimensions of the game
Editing the catching mechanism to fit my illustration
(2 mid-process photos shown below)
ISSUE DEEP DIVE
I ran into several issues in this project. One of the most notable issues was having different
music playing at each stage of the game. This was a logic problem, as each song belonged to a different
stage, and had to play at a different time depending on the user's actions.
I approached this problem with several steps, including:
The audio was stacking on top of each other, so I created a boolean for each song to check if it was playing or not
The music would only play in the correct stage if their corresponding boolean = false
After looping through the game once, all music would stop playing
- With the mousePressed function, I reset the booleans of the previous song back to false so when it loops back, the music will play again
Final game here or shown below (best played on Chrome):
IDEAS AND FUTURE WORK
Here are some ideas for improving on this extension:
Have "lives" for the players, signified by musubi on the screen
Have a mute option for the game
Have different food themes/options for the player
Add multiple musubi or other foods, add some "bad" items to avoid catching
KUDOS
I got lots of support and resources during this project, including: