Skip to content

raphael-pietrzak/network-project

Repository files navigation

Networked Pygame Project

This is a Python project that demonstrates network communication using Pygame for graphical display. It supports both TCP and UDP protocols and includes a terminal monitoring feature.

Getting Started

These instructions will help you set up and run the project on your local machine for testing and development purposes. I personally tested it both locally and online by adjusting a setting on my internet router. I tested it on MacOS.

Prerequisites

To run this project, you'll need the following:

  • Python 3.x
  • Pygame library (install it using pip3 install pygame (macOS) or pip install pygame (Windows))

Installation

  1. Clone the repository to your local machine:

    git clone https://github.com/your/repository.git
    cd networked-pygame-project
  2. Run the server script:

    python3 mainServer.py

Open a new terminal window and run the following command:

  1. Run the client script:

    python3 mainServer.py

The client and server should now be running.

Usage

Use the client to interact with the game. Observe the game display with Pygame and the network communication using TCP and UDP. You can monitor network activity in the terminal while playing the game. You can test UDP with arrows to move the square. You can test TCP by pressing the 'RETURN' key.

Features TCP and UDP Support: This project demonstrates network communication using both TCP and UDP protocols.

Pygame Integration: The graphical display is built using Pygame, providing a visual interface for the game.

Video Preview: Check out the video preview of the project :

Alt text

Terminal Monitoring: See a snapshot of terminal monitoring :

Alt text

License

This project is licensed under the GNU GENERAL PUBLIC License.

Acknowledgments

Contact If you have any questions or feedback, please feel free to reach out to pietrzakraphael7@gmail.com .