GLCrawler is a first-person 3D dungeon crawler built with OpenGL as a university project for Computer Graphics course at MUII.
It features different levels, real-time lighting with flickering torches, an A* powered enemy AI, collectable keys, and a particle system for visual effects.
The logic is structured around a modular architecture where game entities (Doors, Torches, Keys, Enemies) are encapsulated in dedicated modules that manage their own shaders, textures, and logic.
- First-person movement (WASD) with mouse look and sprint (Shift)
- Z-Buffer
- BoundingBox collision detection against maze walls
- Texture mapping (walls, floor, ceiling)
- Pause menu and HUD via Dear ImGui
- Maze loading from
.txtmap files - Dark-fog lighting (only areas near a light source are illuminated)
- Animated torches with flickering point lights
- Pseudo-Randomised light intensity
- Particle system
- Enemy AI with A* pathfinding
- Key collection mechanic
- Win/loss state machine (escape portal or die)
| Component | Library / Technology |
|---|---|
| Graphics API | OpenGL |
| Windowing/Input | GLFW |
| Math | GLM |
| Model Loading | Assimp |
| UI | Dear ImGui |
| Pathfinding | A* (astar) |
- GPU drivers with OpenGL 4.0 support.
- C++17 compiler
- Linux: GCC/G++
- Windows: Visual Studio 2019/2022
- macOS: Xcode
- CMake ≥ 3.7 accessible from the terminal.
All dependencies (GLFW, GLM, Assimp, GLAD, ImGui, AStar) are bundled under libs/.
mkdir build && cd build
cmake .. -DOpenGL_GL_PREFERENCE=GLVND
make -j4Open the repository folder directly in Visual Studio 2019/2022 (CMake project support) or run CMake-GUI to generate a .sln solution file, then build from the IDE.
After building, launch the game from build/bin/:
./gpo_proyecto_final # Linux / macOS
gpo_proyecto_final.exe # Windows| Key / Input | Action |
|---|---|
| W A S D | Move |
| Shift | Sprint |
| Mouse | Look around |
| ESC | Show menu |
| F11 | Toggle fullscreen mode |
- Base framework: GitHub - gpo-framework by @juanpebm
- OpenGL
- GLFW - License: zlib/libpng
- GLM - License: MIT
- Assimp - License: BSD 3-clause
- Dear ImGUI by Omar Cornut - License: BSD 3-clause
- Astar C++ algorithm: GitHub - a-star by Damian Barczyński - License: MIT
- 3D Model conversion tool: Online 3D Viewer by Viktor Kovacs - (used as an external tool)
- Brick texture: Poly Haven - Castle Brick 02 Red by Rob Tuytel - License: CC0 1.0
- Concrete texture: Poly Haven - Concrete Floor Damaged 01 by Rob Tuytel - License: CC0 1.0
- Sand texture: Poly Haven - Sand 03 by Charlotte Baglioni - License: CC0 1.0
- Fire sprite: OpenGameArt - Animated Flame by @dorkster - License: CC-BY-SA 3.0
- Door model: Sketchfab - Bunker Door by @Skotchet - License: CC BY 4.0
- Ghost model: Sketchfab - Cloth Ghost by @ANDRE - License: CC BY 4.0
- Torch model: Sketchfab - Medieval Torch (worn) by @reddification - License: CC BY 4.0
- Key model: Sketchfab - Key by @Gektark - License: CC BY 4.0
