This project has been created as part of the 42 curriculum by aielo and uponci.
Using miniLibX and ray-casting principles we must create a “realistic” 3D graphical representation of a maze from a first-person perspective, modelled on the style of Wolfenstein 3D.
The program displays the image in a window and respects the following rules:
- The left and right arrow keys of the keyboard must allow you to look left and right in the maze.
- The W, A, S, and D keys must allow you to move the point of view through the maze.
- Pressing ESC must close the window and quit the program cleanly.
- Clicking on the red cross on the window’s frame must close the window and quit the program cleanly.
Raycasting is a rendering technique used to create a 3D perspective in a 2D map.
It works by projecting rays from the player’s position at regular angular intervals across their field of view.
Each ray travels until it hits a wall, and the distance determines the apparent height of the wall on the screen.
https://en.wikipedia.org/wiki/Ray_casting
https://lodev.org/cgtutor/raycasting.html
https://devabdilah.medium.com/3d-ray-casting-game-with-cub3d-7a116376056a
AI was used to handle the mathematics involved in ray casting and the DDA algorithm.