https://github.com/matteocalvanico/doomclone
A simple C++ game similar to Doom and Wolfenstein 3D
https://github.com/matteocalvanico/doomclone
cpp raycasting sdl2 video-game
Last synced: about 1 month ago
JSON representation
A simple C++ game similar to Doom and Wolfenstein 3D
- Host: GitHub
- URL: https://github.com/matteocalvanico/doomclone
- Owner: MatteoCalvanico
- License: mit
- Created: 2024-09-23T09:42:07.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-16T09:51:29.000Z (over 1 year ago)
- Last Synced: 2025-01-20T06:42:41.204Z (over 1 year ago)
- Topics: cpp, raycasting, sdl2, video-game
- Language: C++
- Homepage:
- Size: 17.4 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# DoomClone
A simple C++ game similar to Doom and Wolfenstein 3D.

## Commands AND rule
- **WASD**: Move
- **SX or DX mouse**: Fire
- **F**: Open the doors
- **ESC**: Quit
## Info AND Compilation
This game use **SDL2, SDL2_Image AND SDL2_ttf** to work.
Before build the project you need to follow this [video](https://www.youtube.com/watch?v=9Ca-RVPwnBE&ab_channel=vader) to setup the header and lib file to make the game work; after that you can use the Makefile or this command:
```sh
g++ -Iinclude -Iinclude/sdl -Iinclude/headers -Llib -o DoomClone src/*.cpp -lmingw32 -lSDL2 -lSDL2_image -lSDL2_ttf -mconsole
```
directly in the project's root to compile.
*!!! You need to do the same step show in the video but with SDL2_ttf !!!*
**[NEED FIX]**
**Or** you can use Docker for *Build and Run*:
```sh
docker build -t doomclone .
docker run -it --rm doomclone
```
### Bug to fix
- The player can shoot and kill enemies even if they are behind a wall
- Enemies get stuck in the wall
#### Credits
This game was created thanks to this tutorial: [ssloy/tinycaster](https://github.com/ssloy/tinyraycaster), which allowed me to learn the basics of game programming and 3D engines.
To better understand the principles of *raycaster* I recommend this page: [Lode's Computer Graphics Tutorial](https://lodev.org/cgtutor/raycasting.html)