Tank-Trauma is a LibGDX-based top-down tank combat game featuring physics-based movement, bullet ricochet, and procedurally generated mazes.
- Physics-Based Tank Movement: Realistic controls with momentum and rotation.
- Projectile System: Bullets with lifespans and physics interactions.
- Maze Generation: Randomized battlefield layout using a custom maze generator.
- Collision Handling: A robust Box2D physics system for accurate object interactions.
- Multiple Tank Colors: Customizable tank appearances.
- Menu & Settings: Start, configure, and adjust gameplay settings.
- Java Development Kit (JDK) (Version 8 or higher)
- Gradle (For project building)
- LibGDX (Game development framework)
git clone https://github.com/JRPrice5/Tank-Trauma.git
cd Tank-Trauma- Navigate to the Project Directory:
cd Tank-Trauma - Run Gradle Build:
This will compile the project and handle dependencies.
./gradlew build
After building:
- Desktop: Execute the generated JAR file located in
desktop/build/libs/.java -jar desktop-1.0.jar
- Android: Deploy the APK found in
android/build/outputs/apk/to an emulator or device.
-
Tank 1 (Player 1):
- Move:
WASD - Fire:
Spacebar - Rotate turret:
Mouse
- Move:
-
Tank 2 (Player 2, if applicable):
- Move:
Arrow Keys - Fire:
Right Control / Right Alt - Rotate turret:
Mouse
- Move:
-
Game Controls:
- Pause:
Escape - Navigate Menu:
Mouse
- Pause:
- Multiplayer (Local): Compete against another player.
Tank.java- Handles tank movement, shooting, and physics.Bullet.java- Defines projectile behavior and interactions.Projectile.java- Abstract base class for all projectiles.GameScreen.java- Main game logic, rendering, and physics updates.MenuScreen.java- Main menu UI and navigation.SettingsScreen.java- Configurable game options.CollisionListener.java- Detects and handles collisions between game objects.MazeGenerator.java- Generates randomized maps for battles.MazeHitboxParser.java- Processes maze data into Box2D hitboxes.TankTrauma.java- Main game entry point and state management.
We welcome contributions! Please:
- Fork the Repository.
- Create a New Branch:
git checkout -b feature-name. - Commit Your Changes:
git commit -m 'Description of feature'. - Push to Branch:
git push origin feature-name. - Submit a Pull Request.
This project is licensed under the MIT License. See the LICENSE file for details.
- LibGDX: For providing a robust game development framework.
- Contributors: Thanks to all who have contributed to this project.