Usunięcie pdb
This commit is contained in:
parent
ef76909342
commit
9d1891524e
2
agent.py
2
agent.py
@ -37,7 +37,6 @@ class Agent:
|
|||||||
def find_path(self):
|
def find_path(self):
|
||||||
self.closed = []
|
self.closed = []
|
||||||
self.open = PriorityQueue()
|
self.open = PriorityQueue()
|
||||||
import pdb
|
|
||||||
start_node = Node(self.x, self.y)
|
start_node = Node(self.x, self.y)
|
||||||
self.open.put((0, start_node))
|
self.open.put((0, start_node))
|
||||||
while self.open:
|
while self.open:
|
||||||
@ -45,7 +44,6 @@ class Agent:
|
|||||||
print(current_node.x, current_node.y)
|
print(current_node.x, current_node.y)
|
||||||
self.closed.append(current_node)
|
self.closed.append(current_node)
|
||||||
if current_node.x == self.dest.x and current_node.y == self.dest.y:
|
if current_node.x == self.dest.x and current_node.y == self.dest.y:
|
||||||
# pdb.set_trace()
|
|
||||||
while current_node.x != start_node.x and current_node.y != start_node.y:
|
while current_node.x != start_node.x and current_node.y != start_node.y:
|
||||||
self.path.append(current_node)
|
self.path.append(current_node)
|
||||||
current_node = current_node.parent
|
current_node = current_node.parent
|
||||||
|
Loading…
Reference in New Issue
Block a user