From 8cf389aaf748c77aecda0b3a3773c45053b0f231 Mon Sep 17 00:00:00 2001 From: Loek Le Blansch Date: Fri, 25 Oct 2024 13:02:38 +0200 Subject: implement all ALGA features --- PathfindingContext.h | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'PathfindingContext.h') diff --git a/PathfindingContext.h b/PathfindingContext.h index bb6fc23..c2c591c 100644 --- a/PathfindingContext.h +++ b/PathfindingContext.h @@ -12,16 +12,16 @@ class Museum; class PathfindingContext { public: PathfindingContext(Museum &); + void update(); public: void set_start(const XY & point); const XY & get_start() { return this->start_point; } void set_end(const XY & point); const XY & get_end() { return this->end_point; } +public: bool empty_point(const XY & point); - void update(); - public: void register_weight(const std::string & type, unsigned int weight); unsigned int get_weight(const std::string & type); @@ -33,11 +33,14 @@ private: XY end_point = { -1, -1 }; public: - Pathfinder & get_solver(); + Pathfinder & get_solver(); void cycle_solver(); private: - std::vector> solvers; - size_t solver_index = 0; + std::vector> solvers; + size_t solver_index = 0; + +public: + bool has_collision = false; private: Museum & museum; -- cgit v1.2.3