Pong in Python
Pong is a two-dimensional sports game that simulates table tennis. The game involves two paddles and a ball, with players competing to score points against each other by hitting the ball past the opponent's paddle.
- Player-versus-player gameplay
- The bot will track the ball's y position
- Diffculties based on bot's paddle speed
To run the game locally, follow these steps:
- Ensure you have Python installed on your machine. You can download it from python.org.
- Clone this repository to your local machine using
git clone https://github.com/your-username/pong.git - Navigate to the project directory in your terminal.
- Install the required dependencies using
pip install pygame - Run the game by executing
python main.pyin the terminal.
- Launch the game using the installation instructions above.
- Use the provided controls (listed below) to move the paddles and hit the ball.
- Play against a friend or challenge the bot.
- Score 10 points to win!!!
Left:
- W: Move the paddle up
- S: Move the paddle down
Right:
- Up Arrow: Move the paddle up
- Down Arrow: Move the paddle down
Press:
- Q: To quit
- R: To Restart
- P: To pause/ start
This project is licensed under the MIT License.