Skip to content

xXKareemXx/Space-Ship-Game

Repository files navigation

Space Rocket Game

It is a simple game implemented using OpenGL and C++. Basically modified to create an engaging and interactive game where the player controls a space rocket for controlling its movements to destroy asteroids by the laser beam that the rocket initiate it.

Demo Video

SpaceRocket.webm

Requirenments

To run this project, you need the following:

  • C++ compiler: Ensure that you have a C++ compiler installed on your system, such as GCC or Clang.
  • OpenGL Libraries: Make sure you have the necessary OpenGL libraries installed on your system. These include the OpenGL Utility Toolkit (GLUT) and the OpenGL Extension Wrangler Library (GLEW). Refer to the documentation of your operating system to install these libraries.

Building and Running the Game:

To build and run the space rocket game, follow these steps:

  1. Use the command git clone https://github.com/xXKareemXx/Space-Ship-Game.git to clone the project repository onto your local machine.
  2. Open a terminal or command prompt and change the current directory to the project directory.
  3. Use the appropriate build command (e.g., make or cmake) to compile the C++ source files and link the necessary libraries. Make sure to provide any additional build instructions or configuration options specific to your project.
  4. After successfully building the project, run the game executable file generated by the build process. You may need to specify any required command-line arguments or options to start the game.

Game Rules:

Below are the illustrative rules of the game:

  • In each gameplay, 25 asteroids are generated at random X positions and begin falling towards the space rocket.
  • Each asteroid is assigned a random color (red, green, or blue).
  • The user should be able to move the space rocket using the mouse without dragging.
  • A colored laser beam (red, green, or blue) shoots out the rocket, and the user can change the color of the beam using the "Spacebar".
  • The user can destroy asteroids by: Aligning the laser beam with the asteroid and selecting the same color as asteroid.
  • When an asteroid is successfully destroyed, the score increases by one point.
  • There is a time limit of 20 seconds, after which the "Time's Up" screen is displayed with the user's final score.
  • The user can press on F1 to restart the game.

About

A simple game implemented using OpenGL and C++.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages