This is a set of workshop files for writing (parts of) a JS + <canvas>
Pong-style game called "Pong Around".
The workshop is organized into multiple steps, each in their own branch:
- Step 1: adding the paddles
- Step 2: adding the ball
- Step 3: bouncing and speeding up the ball
- Step 4: keeping score
- Final: final solution branch
Go through the steps in order, and compare your code to the beginning of each next-step before moving on, to make sure you're getting everything in the right place.
Things you can consider adding to this game to make it more fun to play:
- Make the paddles shorten little by little as the number of bounces increases
- Add an extra obstacle (of any shape) in the middle of the board after a certain number of bounces
- Add "multi-ball" mode, where the game adds another ball after a certain number of bounces
The code and all the documentation are released under the MIT license.