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.
29 lines
607 B
29 lines
607 B
#pragma once
|
|
#include "matrix.hpp"
|
|
#include "map.hpp"
|
|
|
|
namespace maze {
|
|
|
|
|
|
struct Builder {
|
|
Matrix& $walls;
|
|
std::vector<Room>& $rooms;
|
|
std::vector<Point>& $dead_ends;
|
|
|
|
Builder(Map& map) :
|
|
$walls(map.$walls), $rooms(map.$rooms), $dead_ends(map.$dead_ends)
|
|
{
|
|
init();
|
|
}
|
|
|
|
void hunt_and_kill();
|
|
|
|
void init();
|
|
void randomize_rooms();
|
|
void inner_donut(float outer_rad, float inner_rad);
|
|
void inner_box(size_t outer_size, size_t inner_size);
|
|
void divide(Point start, Point end);
|
|
void remove_dead_ends();
|
|
void dump(const std::string& msg);
|
|
};
|
|
}
|
|
|