Week 17 - Making a 2.5D Game (Wolfenstein-style) from Scratch
Fun lecture today - in two hours we built a working 2.5D game client that takes nonblocking I/O for WASD + arrow keys as input, a simple map editor, and renderer that renders the world around us.
In PuTTY of all things!
The basic approach was to first get WASD input working, then to make a really terrible traceline function that allows us to raycast across the map to find the nearest wall, then to raycast a series of rays over our field of view to find out how far the walls are away in that direction. Then we just render a wall (in a column of text) with a size proportional to how close the wall is to us. Add in a little shading based on distance, and there we are.
Next steps would be adding textures to the ceiling, walls, and floors, and adding monsters and weapons to turn it into an actual game.