mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Fix AI landing behavior.
The landing waypoints need the airdrome_id field set to actually associate with the airfield. Without this ferry flights will take off and immediately land at their departure airfield.
This commit is contained in:
@@ -687,6 +687,10 @@ class ControlPoint(MissionTarget, ABC):
|
||||
) -> RunwayData:
|
||||
...
|
||||
|
||||
@property
|
||||
def airdrome_id_for_landing(self) -> Optional[int]:
|
||||
return None
|
||||
|
||||
@property
|
||||
def parking_slots(self) -> Iterator[ParkingSlot]:
|
||||
yield from []
|
||||
@@ -904,6 +908,10 @@ class Airfield(ControlPoint):
|
||||
assigner = RunwayAssigner(conditions)
|
||||
return assigner.get_preferred_runway(self.airport)
|
||||
|
||||
@property
|
||||
def airdrome_id_for_landing(self) -> Optional[int]:
|
||||
return self.airport.id
|
||||
|
||||
@property
|
||||
def parking_slots(self) -> Iterator[ParkingSlot]:
|
||||
yield from self.airport.parking_slots
|
||||
|
||||
Reference in New Issue
Block a user