Skip to content

phi5ic/Pong-

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

Python Ping Pong Game

This is a simple two-player Ping Pong game developed in Python using the turtle graphics library.

Features

  • Two paddles controlled by players.

  • A ball that bounces off walls and paddles.

  • Score tracking for both players.

How to Play

Controls

  • Left Paddle (Player 1):

    • Move Up: W key

    • Move Down: S key

  • Right Paddle (Player 2):

    • Move Up: Up Arrow key

    • Move Down: Down Arrow key

Game Rules

  • The goal is to hit the ball past your opponent's paddle.

  • If the ball goes off the screen on your opponent's side, you score a point.

  • The first player to reach a certain score (not implemented in this version, but can be added) wins.

Setup and Running

Prerequisites

You need Python installed on your system. The turtle module is part of the Python standard library, so no additional installations are typically required.

Running the Game

  1. Save the file: Save the provided Python code as ping_pong.py in a directory of your choice.

  2. Open a terminal/command prompt: Navigate to the directory where you saved the file.

  3. Run the script: Execute the following command:

    python ping_pong.py
    

    A new window will open with the game running.

Contributing

Feel free to fork this repository, make improvements, and submit pull requests.

License

This project is licensed under the MIT License - see the LICENSE file for details.

About

This is a classic two-player Ping Pong game, implemented in Python using the turtle graphics library. Players control paddles on opposite sides of the screen, aiming to hit the ball past their opponent to score.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages