From 04bbaedb4c796bb6598fba2ccf0716ca024bb621 Mon Sep 17 00:00:00 2001 From: matixezor Date: Sun, 16 May 2021 11:59:06 +0200 Subject: [PATCH] code refactor --- src/main.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main.py b/src/main.py index 5f07f85..ceaab63 100644 --- a/src/main.py +++ b/src/main.py @@ -63,11 +63,11 @@ def main(): if event.key == pg.K_t: print('Starting to clear the sector') while env.mine_count: - print('-'*20) - #path, actions = breadth_first_search(env.field, agent.x, agent.y, agent.direction) - path, actions = a_star (env.field, agent.x, agent.y, agent.direction, - breadth_first_search_for_a_star (env.field, agent.x, agent.y, - agent.direction)) + print('-' * 20) + # path, actions = breadth_first_search(env.field, agent.x, agent.y, agent.direction) + path, actions = a_star(env.field, agent.x, agent.y, agent.direction, + breadth_first_search_for_a_star(env.field, agent.x, agent.y, + agent.direction)) if not path and not env.field[agent.y][agent.x].mine: print('Unable to find path, rocks are in the way') break