mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Never generate empty ship groups.
Fixes https://github.com/Khopa/dcs_liberation/issues/391
This commit is contained in:
parent
e4cba8d19f
commit
c833078e71
@ -24,6 +24,7 @@ Saves from 2.3 are not compatible with 2.4.
|
||||
* **[Factions]** AI would never buy artillery units for the frontline - fixed
|
||||
* **[Factions]** Removed the F-111 unit from the NATO desert storm faction. (Recruiting it would cause crashes in DCS, since it is not a valid unit)
|
||||
* **[Units]** Fixed SPG_Stryker_M1128_MGS not being in db
|
||||
* **[Mission Generator]** Empty navy groups will no longer be generated
|
||||
|
||||
# 2.3.2
|
||||
|
||||
|
||||
@ -32,6 +32,9 @@ class ChineseNavyGroupGenerator(ShipGroupGenerator):
|
||||
else:
|
||||
include_cc = False
|
||||
|
||||
if not any([include_frigate, include_dd, include_cc]):
|
||||
include_frigate = True
|
||||
|
||||
if include_frigate:
|
||||
self.add_unit(Type_054A_Frigate, "FF1", self.position.x + 1200, self.position.y + 900, self.heading)
|
||||
self.add_unit(Type_054A_Frigate, "FF2", self.position.x + 1200, self.position.y - 900, self.heading)
|
||||
|
||||
@ -35,6 +35,9 @@ class RussianNavyGroupGenerator(ShipGroupGenerator):
|
||||
else:
|
||||
include_cc = False
|
||||
|
||||
if not any([include_frigate, include_dd, include_cc]):
|
||||
include_frigate = True
|
||||
|
||||
if include_frigate:
|
||||
frigate_type = random.choice([FFL_1124_4_Grisha, FSG_1241_1MP_Molniya])
|
||||
self.add_unit(frigate_type, "FF1", self.position.x + 1200, self.position.y + 900, self.heading)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user