π Pong!
October 05, 2016β Specifications β
Gameplay
The ball bounces off the upper and lower edges of the field and the playersβ paddles. Each time the ball bounces off a paddle, its speed increases by a small amount. When the ball bounces off a paddle, its direction is reversed with a small random variation to add unpredictability to the game. Itβs like ping pong, but for nerds. Itβs like ping pong.
Scoring
β If the ball touches the left or right edge of the field, a point is scored for the opposite player.
β When one player reaches 5 points, the game is over and that player is the winner. The winner is announced on the screen and the player is given the opportunity to start a new game.
Player Control
β Paddles are positioned a short distance away from the side they are defending, and can only move up and down, not side to side.
β The player can control the paddle with your choice of keys or the mouse.
β The other paddle should be controlled by THE COMPUTER
βοΈ Checklist
Custom Blocks
- Throughout your program, you should use custom blocks to generalize common operation, like keeping score.
- Your program must include at least three custom blocks, at least one of which must take inputs.
Required Checkpoints
- Players control their paddle.
- The ball starts in the middle (INITIALIZE), moves in a random direction, and bounce.
- The ball speeds up when it hits a paddle, and resets to the middle when it hits the left or right edge
- A point is scored when the ball hits the edge on the opponentβs side of the field; the game ends when one player reaches five points; players can start a new game after the game ends