mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Initial attempt at fixing escorts
This commit is contained in:
@@ -129,6 +129,16 @@ class Package:
|
||||
if not self.flights:
|
||||
self.waypoints = None
|
||||
|
||||
@property
|
||||
def primary_flight(self) -> Optional[Flight]:
|
||||
task = self.primary_task
|
||||
if not task:
|
||||
return None
|
||||
primaries = [x for x in self.flights if x.flight_type == task]
|
||||
if len(primaries) > 0:
|
||||
return primaries[0]
|
||||
return None
|
||||
|
||||
@property
|
||||
def primary_task(self) -> Optional[FlightType]:
|
||||
if not self.flights:
|
||||
|
||||
Reference in New Issue
Block a user