HTML and CSS Reference
The RectShape funcion is a useful class that helps to build the game's prototype.
We can rapidly represent game elements with colored shapes. Once we get the game
logic implemented, we can replace the shape into gorgeous graphics.
From the irst task unil just now, we have used RectShape to represent boxes, lives,
and the falling deadline. Now, its job is done and we can get rid of it unil we need a
new game element in future.
With the eight tasks, we have successfully created an educaional canvas-based game. The
game makes use of a simple-to-use game loop icker. A well-structured game library helps us
manage the game elements' hierarchy. And finally, we make the game ready to be published
with some pixel art-style graphics.
The following screenshot shows what we have accomplished in this project:
A Hotshot challenge
We can make the game more challenging by gradually increasing the boxes' falling speed.
Let's say we set the iniial falling speed to 0.3 and gradually increase the falling speed to 1.0
over a ime span of 5 minutes. The boxes fall faster when the player plays longer. This can
make the game more fun by challenging the player's limit.