shadows — Multiplayer Shadowy Halloween Maze Game!
Welp, I misread the timestamp on the bramjam, so I guess I can't submit this, but I'm posting it here anyway! ( @bramley that is right, correct?)
This was a little experiment in raycasting and FOV graphics. The goal is to get to the green light at the end of the maze... the problem is that you only have a tiny lantern which casts light in one direction! So, it's basically a maze game where you can't see the goal, only what you could see in real life. Sounds fun, eh? :D
There is a server, so you can race your friends to the end. Additionally, you can drop beacons to help others out... provided that you're going the right way!
- WASD/Arrow keys to move
- SPACE to drop beacon
@DynamicSquid Basically, there are a bunch of "rays" each going from the player to the edge of the FOV (the angle of the ray being the variable). For each ray, it finds the nearest wall that it intersects and passes that to the player. The player then renders the walls based on that data.
The way it finds that nearest wall is lines 122 to 148. It's standard raycasting math, so I won't explain it here, but basically it calls
cast on each wall and takes the closest point.