This project works because of raycasting. This is when you make a block that shoots a single sprite so fast and so many times that it will act like a flashlight when you add color to the lines. Normally it would just be a line because until you add a height, and distance variable you can't simulate video or a 3D world with barriers.
This was made with the same code that @Griffpatch used to make his 3D maze game. Thanks @Griffpatch!