mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Avoid random squadrons in config using livery overrides
Avoids choosing random squadrons during air wing configuration so that livery overrides takes precedence by default for a given aircraft type, unless the campaign file specifies a specific squadron. Users can still add a squadron manually which will automatically set the correct livery if they use a squadron preset. Resolves #52
This commit is contained in:
parent
09807b25a8
commit
650b06d7c8
@ -94,8 +94,9 @@ class DefaultSquadronAssigner:
|
||||
if aircraft not in self.coalition.faction.aircrafts:
|
||||
return None
|
||||
|
||||
lo = self.coalition.faction.liveries_overrides
|
||||
squadron_def = self.find_squadron_for_airframe(aircraft, task, control_point)
|
||||
if squadron_def is not None:
|
||||
if squadron_def is not None and lo.get(aircraft) is None:
|
||||
return squadron_def
|
||||
|
||||
# No premade squadron available for this aircraft that meets the requirements,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user