Cub3D: my very own 3D game engine!

Cub3D: my very own 3D game engine!
Photo by and machines / Unsplash

For this 42 School project, I had to recreate the classic Wolvenstein game. Apparently this brings up some serious nostalgia for many people, but I guess I am way too young for all of that. Before I started the project, I explored this game a bit to get an idea of the look and feel of it. (It's to tell yourself this is preparation and not procrastination.) It was a cool experience to be honest; you can tell that is very primitive of course, back from a time when computing resources were much more limited. But you can also tell there must be some very smart algorithm behind, because it works very smoothly regardless.

What I learned

Later in the project when implementing this raycasting algorithm – that was the innovation that Wolvenstein 3D brought to the gaming world – my awe got confirmed, a bit like it did for the 42 School project push_swap. It was another lesson in how smart algorithms can yield big results with little computations, but this time not in organizing things, but in creating a very convincing visual illusion that is a first-person game.

Gotten curious? Check out the code!

Yannick / cub3d · GitLab
GitLab.com