This project, "Tankers," is a game developed using Pygame. Its primary purpose is to reinforce the fundamentals of software programming and object-oriented programming (OOP) by implementing a fun and interactive game.
- Two-player tank game.
- Tank movement and shooting.
- Terrain generation and rendering.
- Collision detection.
- Health and score tracking.
- Game over and restart functionality.
- Python
- Pygame library
-
Make sure you have Python installed on your system.
-
Install the Pygame library using
pip
:pip install pygame
-
Clone this repository:
git clone https://github.com/devorbs/tankers-game.git
-
Navigate to the project directory:
cd tankers-game
-
Run the game:
python main.py
-
Player 1 controls:
-
Move Up: Up Arrow Key
-
Move Down: Down Arrow Key
-
Move Left: Left Arrow Key
-
Move Right: Right Arrow Key
-
Shoot: Enter Key (from keypad)
-
Player 2 controls (if available):
-
Move Up: W Key
-
Move Down: S Key
-
Move Left: A Key
-
Move Right: D Key
-
Shoot: Spacebar
- The objective of the game is to destroy the opponent's tank while avoiding their attacks.
- Players can shoot bullets to attack their opponents.
- Tanks have limited health, and resets when a player's health reaches zero.
- The player who can stay alive for 3 rounds wins.
This project is inspired by the desire to reinforce programming fundamentals through practical application. It also serves as a fun way to learn about game development and software design using Python and the Pygame library.
Game Assets by Kenney Vleugels (Kenney.nl)
- Bokang Makibinye
- GitHub: devorbs
This project is open-source and available under the MIT License.