A retro style homage to 80s dungeon crawlers hand crafted in C++.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
 
 
 
 
 
 
Zed A. Shaw 9e91c71125 BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
amt The tracy directory now has an experiment in getting Tracy to work. It's _not_ as easy as it is touted to be. 2 years ago
assets BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
magick Some quick hacks that do the seamless texture splits. 2 years ago
scratchpad Now the sprites are rendered in the 3d scene with just SFML sprites. 2 years ago
scripts Tweaking the build to turn on various debug options in GCC and enable -Wall -Werror on only our executable configs because turning them on globally causes most of the dependencies to fail. One thing to note is if you try to move the -D_GLIBCXX options from the project() to the executable() then you get segfaults inside the libc++ and other places. This is because the ABI changes when you enable these options, so you have to recompile _all_ dependencies with these options. 2 years ago
shaders Sprites now have a distance lighting calculation that's the same as the raycaster using a shader. 2 years ago
tests BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
tracy The tracy directory now has an experiment in getting Tracy to work. It's _not_ as easy as it is touted to be. 2 years ago
wraps We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
.gdbinit My gdb debug thing. 2 years ago
.gitignore First build that actually works. SDL_main errors before but didn't figure out the cause. 2 years ago
.vimrc_proj First build that actually works. SDL_main errors before but didn't figure out the cause. 2 years ago
Makefile We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
README.md A quick warning in case people are funding the thing. 2 years ago
animator.cpp Tiles now record their textures and this is loaded from the map then converted to an indexed integer on the fly. 2 years ago
animator.hpp Implement a little junk camera on its own that we can use later for movement and views. 2 years ago
ansi_parser.cpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
ansi_parser.hpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
ansi_parser.rl We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
camera.cpp FINALLY fix that stupid bug. The cause was two-fold: I was giving every 'enemy' a sprite, but that automatically included the player in the list of enemies, which meant that I was rendering the player's sprite while moving. Then in the sprite casting loop I was rendering things at 0. 2 years ago
camera.hpp FINALLY fix that stupid bug. The cause was two-fold: I was giving every 'enemy' a sprite, but that automatically included the player in the list of enemies, which meant that I was rendering the player's sprite while moving. Then in the sprite casting loop I was rendering things at 0. 2 years ago
color.hpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
combat.cpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
combat.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
components.hpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
config.cpp Amit's code mostly converted to use the new texture.hpp but there's an error on line amt/pixel.hpp:472 2 years ago
config.hpp Finished the first pass of moving everything around and cleaning up as much as possible. 2 years ago
constants.hpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
dbc.cpp Fixed that crash and cleaned up more variables for some study next. I might also try out my debug macros. 2 years ago
dbc.hpp First cut at a replica of the python raycaster. Left side almost works the same but have to sort out math differences. 2 years ago
dbg.h Fixed that crash and cleaned up more variables for some study next. I might also try out my debug macros. 2 years ago
devices.cpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
devices.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
dinkyecs.cpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
dinkyecs.hpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
events.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
fsm.hpp Trying out an FSM for controlling the main loop. 2 years ago
gui.cpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
gui.hpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
inventory.cpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
inventory.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
levelmanager.cpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
levelmanager.hpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
lights.cpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
lights.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
main.cpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
map.cpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
map.hpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
matrix.cpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
matrix.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
meson.build BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
meson.options Add the tracy wrap and meson options. 2 years ago
panel.cpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
panel.hpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
pathing.cpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
pathing.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
point.hpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
rand.cpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
rand.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
raycaster.cpp Sprites now have a distance lighting calculation that's the same as the raycaster using a shader. 2 years ago
raycaster.hpp Sprites now have a distance lighting calculation that's the same as the raycaster using a shader. 2 years ago
render.cpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
render.hpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
save.cpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
save.hpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
shiterator.hpp Brought over a bunch of code from the roguelike and now will use it to generate a random map. 2 years ago
spatialmap.cpp More cleanup of the raycaster, finally removed the window as a dependency but I went against making it an sf::Drawable since that had a lot of code quality problems. 2 years ago
spatialmap.hpp Raycaster now controls the sprite locations with SpatialMap rather than the old way. Quick hack job in main.cpp that shows how they can move too. 2 years ago
stats.cpp Bring in the gnu omni font for text, and rewrite my stats code to use c++ and then use that to calc FPS stats for an FPS display on the left. Debug build gets about 48, release gets about 500fps. Amit's code will probably do even better. 2 years ago
stats.hpp Bring in the gnu omni font for text, and rewrite my stats code to use c++ and then use that to calc FPS stats for an FPS display on the left. Debug build gets about 48, release gets about 500fps. Amit's code will probably do even better. 2 years ago
systems.cpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
systems.hpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
texture.cpp Raycaster now controls the sprite locations with SpatialMap rather than the old way. Quick hack job in main.cpp that shows how they can move too. 2 years ago
texture.hpp Sprite is no more, now using the position from the level's world. 2 years ago
tilemap.cpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
tilemap.hpp We now have a full map that's basically the same mapping system from Roguish. There's a bug right now where it needs you to move once to calc the light and it's not being centered, but it does work. 2 years ago
worldbuilder.cpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago
worldbuilder.hpp BROKEN: Big refactoring happening, so it compiles but game does not run and the tests fail. 2 years ago

README.md

Simple Raycaster Study

This is a study project for me to learn the raycasting technique. It's an older technique that's not really used much but I'm learning game dev historically and it's definitely been used in the past (Doom).

Don't Study This Code

This code is mostly a tech study and demo, not an actual game. It could be a game but it will require a significant cleanup to improve the layout and design. It's also the culmination of studying about 6 different tutorials on raycasting so it has a weird mix-match code style as I brought ideas over from other tutorials.

Eventually this will be more understandable, but for now just browse it casually and ignore the inconsistent style and kind of stupid structure.