mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Clean up available parking code a bit.
Moved more into the `ControlPoint`.
This commit is contained in:
@@ -235,7 +235,7 @@ class ControlPoint(MissionTarget):
|
||||
return result
|
||||
|
||||
@property
|
||||
def available_aircraft_slots(self):
|
||||
def total_aircraft_parking(self):
|
||||
"""
|
||||
:return: The maximum number of aircraft that can be stored in this control point
|
||||
"""
|
||||
@@ -385,6 +385,10 @@ class ControlPoint(MissionTarget):
|
||||
total += self.pending_unit_deliveries.units[unit_bought]
|
||||
return total
|
||||
|
||||
@property
|
||||
def unclaimed_parking(self) -> int:
|
||||
return self.total_aircraft_parking - self.expected_aircraft_next_turn
|
||||
|
||||
|
||||
class OffMapSpawn(ControlPoint):
|
||||
def __init__(self, id: int, name: str, position: Point):
|
||||
@@ -400,5 +404,5 @@ class OffMapSpawn(ControlPoint):
|
||||
yield from []
|
||||
|
||||
@property
|
||||
def available_aircraft_slots(self) -> int:
|
||||
def total_aircraft_parking(self) -> int:
|
||||
return 1000
|
||||
|
||||
Reference in New Issue
Block a user