Add combat job with safe target filtering
This commit is contained in:
1 parent
2ecaa9a30a
commit
1b9f973db3
12 files changed
+486
-7
No files matched your search
+2
-2
@@ -668,7 +668,7 @@ class World:
|
||||
result.append(utils.padd(tree, offset))
|
||||
return result
|
||||
|
||||
def path_to_place(self, start, place):
|
||||
def path_to_place(self, start, place, timeout=path.DEFAULT_PATH_TIMEOUT):
|
||||
policies = self._active_work_policies()
|
||||
for policy in policies:
|
||||
if not self._inside_sign_policy(place, policy):
|
||||
@@ -677,7 +677,7 @@ class World:
|
||||
policy['position']), flush=True)
|
||||
return None
|
||||
|
||||
maze_solver = path.Pathfinder(self.g)
|
||||
maze_solver = path.Pathfinder(self.g, timeout=timeout)
|
||||
try:
|
||||
solution = maze_solver.astar(start, place)
|
||||
if not solution:
|
||||
|
||||
Reference in new issue
Block a user