Commit graph

7 commits

Author SHA1 Message Date
1b0f044834
feat: add a side panel for user interaction
Some checks failed
test / test (pull_request) Failing after 6s
This commit adds a simple side panel to allow users to interact with the
application. The side panel allows the user to:

- Generate and regenerate mazes
- Choose between the searching algorithms
- Choose whether or not to add randomness to the algorithm
- Run and re-run the simulation
2024-02-18 08:53:36 +00:00
ed5f0033fa
fix(solver): call random.seed() from constructor 2024-02-17 04:01:56 +00:00
fa75e61acf
fix: add randomisation to original DFS algorithm
Update the DFS algorithm to allow the user to select if the solver
should randomly choose the directions when traversing through the maze.

The duplicate method has been removed.
2024-02-17 03:55:34 +00:00
b4d2e1161b
feat: add the BFS search algorithm to Solver
Add the BFS algorithm to the Solver class. This method can be executed
with or without random directions enabled.
2024-02-17 03:39:24 +00:00
611935050b
refactor: DFS not DST
The searching algorithm is called Depth-First Search not DST.
2024-02-17 02:35:01 +00:00
8466500092
feat: add the Randomised DST search algorithm
Implement a variation to the DST search algorithm to the Solver class.
In this variation, the solver randomly chooses the next direction when
it reaches a fork in its path.
2024-02-17 01:37:20 +00:00
a091f0a68d
refactor: add a dedicated class for the solver
Create a separate class to represent the solver of the maze.
Additional search algorithms will be implemented here.

Additional changes:

- Add public methods to mark cells as visited and to get results of
  the visits.
- Renamed MazeDirections to MazeDirection.
- Renamed _num_cell_rows to _height.
- Renamed _num_cells_per_row to _width.
- Created a dedicated method to configure a cell's walls in the Maze
  class.
- created a dedicated public method to draw a path between two cells in
  the Maze class.
2024-02-16 23:27:09 +00:00