head football. The C++ project for BP course of electrical engineering department of Sharif university of technology.
at first you should install SDL2, SDL2_gfx, SDL2_image, SDL2_ttf. in debian based distributions this command will do that:
sudo apt install libsdl2*
also you will need g++ as compiler. You can install it by runnig this:
sudo apt install g++
There are two options for building the project.
- CMake (recommended)
- Build script
Building using CMake (recommended)
You are gonna need CMake. So install it using your favorite package manager. For example under debian systems:
project-root$ sudo apt install cmake
After installing CMake, navigate to the root directory of the project and insert the following command:
project-root$ cmake . -B build && cd build && make
Now, you should be able to run the program placed at the build directory:
project-root/build$ ./Program
Building using the build script
There is a shell file named make.sh in the project root directory which helps you build the game. Just try these commands at the project root directory:
project-root$ sudo chmod u+x make.sh && ./make.sh
To run the program:
project-root$ ./Program.out
After selecting names, characters and ball the game will start.
there are two characters which are controlled using 'w s a d' and arrow keys.
also, each character has a special power which is shown below its names (top of the screen).
the powers can be enabled by pressing 's' or bottom arrow. it is obvious that power bars(below each goal) must be complete.
you have 90 seconds. if any player scores more than 10 the game will finish!