An implementation of Super-Pac Man game with C++
for Software Development II - Course Project. Super-Pac Man is a spin-off of the classic Pac-Man game released in 1980. Its gameplay mechanics were altered radically from the first two entries into the Pac-Man series -- instead of eating dots, the player is required to eat keys in order to open doors, which open up sections of the maze that contain what in earlier games were known as “fruits”, the basic items that must be cleared. Once all the food is eaten, the player advances to the next level, in which the food is worth more points.
Watch the game demo on YouTube
This code is developed on a Windows machine, but I have since switched to
Linux. This code has been compiled in both systems, Windows and Linux, without modifying the code. The problem is that as I'm writing the README
, I'm on Linux, So I'll only provide a thorough guide for compiling and testing the source code in Linux
.
make
, C++ compiler, i.e g++
, SFML library
, Doctest
$ sudo apt update
Install all the prerequisites:
$ sudo apt-get install make g++ libsfml-dev doctest-dev
To verify that you have installed make
and g++
, run:
$ make -v
$ g++ -v
And to check the list of files installed to your system from package-name
$ dpkg -L <package-name>
Then check libsfml-dev
and doctest-dev
using the above command.
Change directory to the source code:
$ cd game-source-code/
Build the game source code:
$ make
If your machine has multiple core processors, you can speed the build process by running make
in multiple threads. To run make
in N threads, use:
$ make -jN
Run the game executable:
$ ./game.out
The code is thoroughly tested using Unit tests to
limit regression bugs during development. The tests are in test-source-code
directory.
Change the directory to the tests
$ cd test-source-code/
Build the tests
$ make
run the tests executable:
$ ./test.out
- Windows, 64-bit binaries.
- Linux, x64-bit binaries.