mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Merge remote-tracking branch 'remotes/dcs-retribution/dcs-retribution/dev' into pretense-generator
This commit is contained in:
@@ -45,7 +45,7 @@ from game.dcs.aircrafttype import AircraftType
|
||||
from game.persistency import airwing_dir
|
||||
from game.squadrons import AirWing, Pilot, Squadron
|
||||
from game.squadrons.squadrondef import SquadronDef
|
||||
from game.theater import ControlPoint, ParkingType
|
||||
from game.theater import ControlPoint, ParkingType, Airfield
|
||||
from qt_ui.uiconstants import AIRCRAFT_ICONS, ICONS
|
||||
from qt_ui.widgets.combos.QSquadronLiverySelector import SquadronLiverySelector
|
||||
from qt_ui.widgets.combos.primarytaskselector import PrimaryTaskSelector
|
||||
@@ -127,7 +127,9 @@ class SquadronBaseSelector(QComboBox):
|
||||
self.clear()
|
||||
if aircraft_type:
|
||||
for base in self.bases:
|
||||
if not base.can_operate(aircraft_type):
|
||||
if not base.can_operate(aircraft_type) and not isinstance(
|
||||
base, Airfield
|
||||
):
|
||||
continue
|
||||
self.addItem(base.name, base)
|
||||
self.model().sort(0)
|
||||
|
||||
@@ -215,7 +215,11 @@ class SquadronDestinationComboBox(QComboBox):
|
||||
f"Consider moving these squadrons to different airfield "
|
||||
"to avoid possible air-starts.",
|
||||
)
|
||||
return len(ap.free_parking_slots(dcs_unit_type))
|
||||
return (
|
||||
len(ap.free_parking_slots(dcs_unit_type))
|
||||
+ free_helicopter_slots
|
||||
+ free_ground_spawns
|
||||
)
|
||||
else:
|
||||
parking_type = ParkingType().from_aircraft(
|
||||
next(AircraftType.for_dcs_type(dcs_unit_type)),
|
||||
|
||||
Reference in New Issue
Block a user