/Python-Pacman-Game

A simple Python Pac-Man game using Pygame

Primary LanguagePythonMIT LicenseMIT

Python_Pacman_Game

This project was developed as the final project for a basic Python course. It is a classic arcade game where the player controls Pacman, a yellow character that navigates a maze, collects pellets, and avoids ghosts.

Installation

To run the Pacman Game, you need to have Python and the Pygame module installed on your machine. Follow the steps below to set up the game:

  1. Clone this repository to your local machine or download the ZIP file.

  2. Make sure you have Python installed. You can download it from the official website: https://www.python.org/downloads/.

  3. Install the Pygame module by running the following command in your terminal or command prompt: pip install pygame

  4. Once you have Python and Pygame installed, navigate to the project directory.

  5. Run the game by executing the following command: python3 pacman.py

Gameplay

In this Pacman game, your goal is to control Pacman and navigate through a maze, eating all the pellets while avoiding the ghosts. The game ends when Pacman either eats all the pellets or gets caught by a ghost.

Controls

Use the arrow keys on your keyboard to control the movement of Pacman:

  • Up Arrow: Move Up

  • Down Arrow: Move Down

  • Left Arrow: Move Left

  • Right Arrow: Move Right

Features

This Pacman game offers the following features:

  • Classic gameplay inspired by the original arcade game.

  • A maze filled with pellets for Pacman to eat.

  • Ghosts that chase Pacman and try to catch him.

  • Score tracking to keep track of the number of pellets eaten.

  • Game over screen with the final score.