This commit is contained in:
Jager72 2024-05-09 14:56:43 +02:00
parent 03f12139e7
commit adc7d7287c

View File

@ -224,7 +224,6 @@ class Agent:
queue = [] queue = []
heapq.heappush(queue, (0,(start_state, [], 0))) heapq.heappush(queue, (0,(start_state, [], 0)))
while queue: while queue:
queue.sort(key=self.calculate_priority)
_, que = heapq.heappop(queue) _, que = heapq.heappop(queue)
state, actions, gscore = que state, actions, gscore = que
self.xPOM, self.yPOM, self.directionPOM = state self.xPOM, self.yPOM, self.directionPOM = state