Skip to content

GlepZorg/Alien-Invasion

Repository files navigation

Alien Invasion

Alien Invasion is a classic arcade-style game written in Python. The player controls a spaceship that can move left and right and shoot bullets upwards. The objective is to destroy all the aliens before they reach the bottom of the screen.

Table of Contents

Introduction

Alien Invasion is built using the Pygame library and follows the principles laid out in the book "Python Crash Course" by Eric Matthes. It's a fun way to learn game development and Python programming.

Features

  • Classic arcade-style gameplay
  • Control a spaceship to shoot bullets
  • Multiple levels with increasing difficulty
  • High score tracking
  • Sound effects and animations

Installation

To run Alien Invasion on your local machine, follow these steps:

  1. Clone the repository:

    git clone https://github.com/yourusername/alien-invasion.git
  2. Navigate to the project directory:

    cd alien-invasion
  3. Create a virtual environment:

    python3 -m venv venv
  4. Activate the virtual environment:

    • On Windows:

      venv\Scripts\activate
    • On macOS/Linux:

      source venv/bin/activate
  5. Install the required dependencies:

    pip install -r requirements.txt

Usage

To start the game, simply run the following command:

python alien_invasion.py

Gameplay

  • Use the left and right arrow keys to move the spaceship.
  • Press the spacebar to shoot bullets.
  • Destroy all the aliens before they reach the bottom of the screen.
  • The game gets progressively harder with each level.
  • Track your high score and try to beat it!

Contributing

Contributions are welcome! If you have any ideas, suggestions, or bug reports, please open an issue or submit a pull request.

  1. Fork the repository.
  2. Create a new branch (git checkout -b feature-branch).
  3. Make your changes.
  4. Commit your changes (git commit -m 'Add some feature').
  5. Push to the branch (git push origin feature-branch).
  6. Open a pull request.

License

This project is licensed under the MIT License.

Credits

Alien Invasion was created by Alexis Gonzalez. Special thanks to Eric Matthes for his book "Python Crash Course" which provided the foundation for this game.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages