Rogue Basement annotated source code
I took the time to extensively comment my entire game. I ended up with 885 lines of comments (wrapped at 80 characters!) for 1,570 lines of code. The code is pretty good for a 48-hour game and might give you a starting point for writing your own roguelike.
Topics covered:
- Python 3 in general
- Scene management
- Efficient drawing with BearLibTerminal
- Level generator with BSP trees
- Strategies for storing and using data
- Flexible system for simulation and AI
- Using pyglet for music and not graphics
- FoV using recursive shadowcasting via clubsandwich (post-compo)
