Show convoys on the map.

This commit is contained in:
Dan Albert
2021-04-19 20:37:15 -07:00
parent cabbd234af
commit 2a5b37b9ad
3 changed files with 100 additions and 33 deletions

View File

@@ -711,6 +711,12 @@ class ControlPoint(MissionTarget, ABC):
def has_active_frontline(self) -> bool:
return any(not c.is_friendly(self.captured) for c in self.connected_points)
def front_is_active(self, other: ControlPoint) -> bool:
if other not in self.connected_points:
raise ValueError
return self.captured != other.captured
class Airfield(ControlPoint):
def __init__(

View File

@@ -42,6 +42,9 @@ class RoadTransferOrder(TransferOrder):
supply_route = SupplyRoute.for_control_point(self.position)
return supply_route.shortest_path_between(self.position, self.destination)
def next_stop(self) -> ControlPoint:
return self.path()[0]
class PendingTransfers:
def __init__(self) -> None: