2024-02-12 23:48:41 +00:00
|
|
|
from graphics import Window
|
2024-02-13 12:18:47 +00:00
|
|
|
from maze import Maze
|
2024-02-12 19:53:45 +00:00
|
|
|
|
|
|
|
|
|
|
|
def main():
|
|
|
|
window = Window(800, 800)
|
2024-02-12 23:32:03 +00:00
|
|
|
|
2024-02-15 19:13:31 +00:00
|
|
|
game = Maze(
|
2024-02-15 01:40:16 +00:00
|
|
|
x_position=10,
|
|
|
|
y_position=10,
|
2024-02-16 10:36:06 +00:00
|
|
|
num_cell_rows=16,
|
|
|
|
num_cells_per_row=16,
|
|
|
|
cell_size_x=40,
|
|
|
|
cell_size_y=40,
|
2024-02-15 01:40:16 +00:00
|
|
|
window=window
|
|
|
|
)
|
2024-02-13 10:48:26 +00:00
|
|
|
|
2024-02-15 19:13:31 +00:00
|
|
|
solved = game.solve()
|
|
|
|
if solved:
|
|
|
|
print("Maze solved successfully :)")
|
|
|
|
else:
|
|
|
|
print("I'm unable to solve the maze :(")
|
|
|
|
|
2024-02-15 01:40:16 +00:00
|
|
|
window.mainloop()
|
2024-02-12 19:53:45 +00:00
|
|
|
|
|
|
|
|
|
|
|
if __name__ == "__main__":
|
|
|
|
main()
|