Just don't prevent start points being in walls.

main
Zed A. Shaw 2 months ago
parent 6f952bfd28
commit 243d15c123
  1. 6
      map.cpp
  2. 1
      status.txt

@ -180,11 +180,7 @@ bool Map::neighbors(Point &out, bool greater) {
int zero_i = -1; int zero_i = -1;
int cur = $paths[out.y][out.x]; int cur = $paths[out.y][out.x];
if(cur == 1000) { // BUG: sometimes cur is in a wall so finding neighbors fails
// BUG: sometimes the generation clips a door and we
// start in a wall
return false;
}
for(int i = 0; i < 4; ++i) { for(int i = 0; i < 4; ++i) {
Point dir = dirs[i]; Point dir = dirs[i];

@ -2,4 +2,5 @@ TODO:
* Figure out how to render color fonts from FTUI. * Figure out how to render color fonts from FTUI.
* Dynamically determine the font vs. screensize to get an exact FTXUI screen size. * Dynamically determine the font vs. screensize to get an exact FTXUI screen size.
* Write a test that generates a ton of maps then confirms there's a path from one room to every other room?
* Lua integration? * Lua integration?

Loading…
Cancel
Save