summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pathfinding.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pathfinding.py b/pathfinding.py
index 076213c..b250523 100644
--- a/pathfinding.py
+++ b/pathfinding.py
@@ -121,7 +121,7 @@ class PathfindingTesterStrategy:
if self.path:
relx, rely = self.path[0].point[0]-self.c.player.center.x, self.path[0].point[1]-self.c.player.center.y
- if relx*relx + rely*rely < 10**2:
+ if relx*relx + rely*rely < (2*grid_density)**2:
self.path=self.path[1:]
if self.path: