A roguelike RPG game where you must defeat the evil boss to escape from a corrupted realm.
Before building the game, make sure you have the following installed:
- CMake (version 3.10 or higher)
- C++ compiler with C++17 support
- SFML 2.6 library
brew install sfml@2
sudo apt-get update
sudo apt-get install libsfml-dev
- Download SFML 2.6 from https://www.sfml-dev.org/download.php
- Extract it to a known location
- Add the SFML bin directory to your PATH environment variable
- Clone the repository:
git clone [repository-url]
cd FightGPT
- Create a build directory:
mkdir build
cd build
- Configure with CMake:
cmake ..
cmake .. -DSFML_DIR=path/to/SFML/lib/cmake/SFML
- Build the game:
make
cmake --build . --config Release
From the build directory:
./FightGPT
.\Release\FightGPT.exe
- Arrow keys: Move character/Navigate menus
- Enter: Confirm selection
- A: Attack in combat
- E: Try to escape from combat
- I: Access inventory during combat
- 1-4: Use items from inventory
- ESC: Exit game
- Knight: High HP and Defense, balanced Attack
- Mage: High Attack Power, low Defense
- Archer: High Speed and Avoidance, medium Attack
If you want to modify the source code, the project structure is as follows:
FightGPT/
βββ include/ # Header files
βββ src/ # Source files
βββ assets/ # Game assets (fonts, images)
βββ build/ # Build directory (created during build)
βββ CMakeLists.txt # CMake configuration
-
SFML not found
- Make sure SFML is installed
- Check if SFML_DIR is set correctly in CMake
- On macOS, verify Homebrew installation of SFML
-
Build errors
- Ensure you have a C++17 compatible compiler
- Check if all dependencies are installed
- Try cleaning the build directory and rebuilding
-
Runtime errors
- Verify that assets are copied to the build directory
- Check if SFML dynamic libraries are in the system path