Skip to content

prishaag/Ping-Pong

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Pygame Ping Pong Game

Overview

This is a simple implementation of a ping pong game using the Pygame library in Python.

How to Run

  1. Make sure you have Python installed on your system.

  2. Install the Pygame library by running the following command:

    pip install pygame
  3. Run the script

    python pingpong.py
    

Game Controls

Left Paddle: Move Up: W key Move Down: S key Right Paddle: Move Up: Up arrow key Move Down: Down arrow key

Game Rules

The game is a classic ping pong match between two players. Each player controls a paddle on their side of the screen. The objective is to hit the ball with the paddle and score points. The game continues until one of the players reaches the winning score. The winning score is set to 10 by default but can be changed by modifying the winningscore variable in the code. Game Features The game features a simple user interface with paddles, a ball, and a score display. Paddles can be moved up and down using specified keys. The ball bounces off the paddles and walls, and scores are updated accordingly. The game announces the winner when either player reaches the winning score. After a victory, the game resets, allowing for a new match to begin.

Acknowledgements

This rendition of ping pong would not have been possible without the Pygame module, as well as this super awesome tutorial I was able to follow and draw my inspiration from https://www.youtube.com/watch?v=vVGTZlnnX3U .

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages