Slight better but I think place_doors can be even better.

This commit is contained in:
Zed A. Shaw 2026-03-15 01:21:33 -04:00
parent f304538325
commit 908f5bfb3e
4 changed files with 37 additions and 36 deletions

View file

@ -23,7 +23,7 @@ TEST_CASE("hunt-and-kill", "[mazes]") {
maze.randomize_rooms(ROOM_SIZE);
maze.hunt_and_kill();
maze.make_doors();
maze.place_doors();
REQUIRE(maze.repair() == true);
if(DUMP) maze.dump("ROOM MAZE");
@ -44,7 +44,7 @@ TEST_CASE("hunt-and-kill box", "[mazes]") {
maze.hunt_and_kill();
maze.open_box(6);
maze.make_doors();
maze.place_doors();
auto valid = maze.repair();
if(i == 41 && DUMP) {
@ -101,7 +101,7 @@ TEST_CASE("hunt-and-kill too much", "[mazes]") {
maze.inner_donut(9, 4);
maze.divide({3,3}, {15,16});
maze.hunt_and_kill();
maze.make_doors();
maze.place_doors();
auto valid = maze.repair();
if(i == 41 && DUMP && valid) {
@ -127,7 +127,7 @@ TEST_CASE("hunt-and-kill validator", "[mazes]") {
maze.randomize_rooms(ROOM_SIZE);
maze.hunt_and_kill();
maze.open_box(6);
maze.make_doors();
maze.place_doors();
valid = maze.repair();
if(i == 9 && DUMP) {
@ -165,7 +165,7 @@ TEST_CASE("hunt-and-kill scripting", "[mazes]") {
{"action": "hunt_and_kill"},
{"action": "open_box", "data": [6]},
{"action": "remove_dead_ends"},
{"action": "make_doors"}
{"action": "place_doors"}
]
)"_json;