Fix: expected_end of enroute waypoints should be empty

This commit is contained in:
LmeSzinc 2023-11-18 00:12:52 +08:00
parent b542c2a656
commit bace33056c

View File

@ -379,6 +379,8 @@ class MapControl(Combat, AimDetectorMixin):
""" """
logger.hr('Clear item', level=1) logger.hr('Clear item', level=1)
waypoints = ensure_waypoints(waypoints) waypoints = ensure_waypoints(waypoints)
for point in waypoints[:-1]:
point.expected_end = []
end_point = waypoints[-1] end_point = waypoints[-1]
end_point.expected_end.append('item') end_point.expected_end.append('item')
@ -394,6 +396,8 @@ class MapControl(Combat, AimDetectorMixin):
""" """
logger.hr('Clear enemy', level=1) logger.hr('Clear enemy', level=1)
waypoints = ensure_waypoints(waypoints) waypoints = ensure_waypoints(waypoints)
for point in waypoints[:-1]:
point.expected_end = []
end_point = waypoints[-1] end_point = waypoints[-1]
end_point.expected_end.append('enemy') end_point.expected_end.append('enemy')