Cub3D is a 42 school team project to create a dynamic view inside a 3D maze. Using the MiniLibX library, we must implement raycasting in the style of the famous Wolfenstein 3D game, the first true FPS in videogame history.
When launching the bonus part, you will have three difficulties available. You will always start at level 1. Every level spawns you on a map that will contain ennemies for you to kill.
Every 4 seconds, ennemis will spawn other ennemies nearby themselves. Soon, they will be everywhere on the map! And if they do, you lose.
You go to the next level by killing every ennemy on the map.
Be carefull, some levels can be quite challenging.. But wounded ennemies have different states, maybe some of them could come in handy ? ..
Have fun ! :)
There are two versions of the program, the mandatory part and the bonus part. The bonus part adds wall collision, a minimap, and the ability to rotate the view by moving the mouse. Furthermore, we made the bonus part out to be a FPS game. It is pretty fun to play !
To compile the mandatory part, cd
into the cloned directory and:
make
To compile the bonus part, cd
into the cloned directory and:
make bonus
To run the basic program:
./cub3D <path/to/map.cub>
To run the bonus part (the game), don't use any arg:
./cub3D_bonus
The program takes a map file as an argument. Maps are available in the maps
directory. There are good maps which the program should run smoothly with, and bad maps which the program should reject.
For example:
-
./cub3d maps/big_map.cub
should run. -
./cub3d maps/bad/filetype_wrong.buc
should print an error and abort.
Controls for movement and rotation are:
W
: move forwardS
: move backwardA
: strafe leftD
: strafe rightleft arrow
: rotate leftright arrow
: rotate rightmouse
: rotate by moving the mouse (bonus only)H
: displays a help menu with all available commands (bonus only)ESC
: pause/exit the gameSpace
: attack1
and2
: switch weapons (sword and shotgun)- Many others (see help menu ingame)
ABDYLI Arbesa
42intra profile : aabdyli
RUET SUQUET William
42intra profile : wruet-su
Description inspired by mcombeau