mirror of
https://github.com/dcs-liberation/dcs_liberation.git
synced 2025-11-10 14:22:26 +00:00
SA-5 support 🚀
This commit is contained in:
parent
9456fd77d1
commit
4399e10cef
@ -49,6 +49,7 @@ from gen.sam.sam_sa17 import SA17Generator
|
||||
from gen.sam.sam_sa19 import SA19Generator
|
||||
from gen.sam.sam_sa2 import SA2Generator
|
||||
from gen.sam.sam_sa3 import SA3Generator
|
||||
from gen.sam.sam_sa5 import SA5Generator
|
||||
from gen.sam.sam_sa6 import SA6Generator
|
||||
from gen.sam.sam_sa8 import SA8Generator
|
||||
from gen.sam.sam_sa9 import SA9Generator
|
||||
@ -77,6 +78,7 @@ SAM_MAP: Dict[str, Type[AirDefenseGroupGenerator]] = {
|
||||
"FlakGenerator": FlakGenerator,
|
||||
"SA2Generator": SA2Generator,
|
||||
"SA3Generator": SA3Generator,
|
||||
"SA5Generator": SA5Generator,
|
||||
"SA6Generator": SA6Generator,
|
||||
"SA8Generator": SA8Generator,
|
||||
"SA9Generator": SA9Generator,
|
||||
|
||||
48
gen/sam/sam_sa5.py
Normal file
48
gen/sam/sam_sa5.py
Normal file
@ -0,0 +1,48 @@
|
||||
from dcs.vehicles import AirDefence
|
||||
|
||||
from gen.sam.airdefensegroupgenerator import (
|
||||
AirDefenseRange,
|
||||
AirDefenseGroupGenerator,
|
||||
)
|
||||
|
||||
|
||||
class SA5Generator(AirDefenseGroupGenerator):
|
||||
"""
|
||||
This generate a SA-5 group
|
||||
"""
|
||||
|
||||
name = "SA-5/S-200 Site"
|
||||
|
||||
def generate(self) -> None:
|
||||
self.add_unit(
|
||||
AirDefence.RLS_19J6,
|
||||
"SR",
|
||||
self.position.x,
|
||||
self.position.y,
|
||||
self.heading,
|
||||
)
|
||||
self.add_unit(
|
||||
AirDefence.RPC_5N62V,
|
||||
"TR",
|
||||
self.position.x + 20,
|
||||
self.position.y,
|
||||
self.heading,
|
||||
)
|
||||
|
||||
num_launchers = 6
|
||||
positions = self.get_circular_position(
|
||||
num_launchers, launcher_distance=120, coverage=360
|
||||
)
|
||||
|
||||
for i, position in enumerate(positions):
|
||||
self.add_unit(
|
||||
AirDefence.S_200_Launcher,
|
||||
"LN#" + str(i),
|
||||
position[0],
|
||||
position[1],
|
||||
position[2],
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def range(cls) -> AirDefenseRange:
|
||||
return AirDefenseRange.Long
|
||||
Binary file not shown.
Binary file not shown.
@ -47,6 +47,7 @@
|
||||
"HawkGenerator",
|
||||
"RapierGenerator",
|
||||
"SA2Generator",
|
||||
"SA5Generator",
|
||||
"ZSU57Generator",
|
||||
"ZSU23Generator",
|
||||
"ZU23Generator",
|
||||
|
||||
@ -55,6 +55,7 @@
|
||||
"HawkGenerator",
|
||||
"RapierGenerator",
|
||||
"SA2Generator",
|
||||
"SA5Generator",
|
||||
"SA6Generator",
|
||||
"SA11Generator",
|
||||
"SA15Generator",
|
||||
|
||||
@ -45,6 +45,7 @@
|
||||
"RapierGenerator",
|
||||
"SA2Generator",
|
||||
"SA3Generator",
|
||||
"SA5Generator",
|
||||
"SA6Generator",
|
||||
"SA8Generator",
|
||||
"SA9Generator",
|
||||
|
||||
@ -48,6 +48,7 @@
|
||||
"air_defenses": [
|
||||
"SA2Generator",
|
||||
"SA3Generator",
|
||||
"SA5Generator",
|
||||
"SA6Generator",
|
||||
"SA9Generator",
|
||||
"SA13Generator",
|
||||
|
||||
@ -44,6 +44,7 @@
|
||||
"Paratrooper AKS"
|
||||
],
|
||||
"air_defenses": [
|
||||
"SA5Generator",
|
||||
"SA6Generator",
|
||||
"SA8Generator",
|
||||
"ZSU23Generator",
|
||||
|
||||
@ -53,6 +53,7 @@
|
||||
"ColdWarFlakGenerator",
|
||||
"SA2Generator",
|
||||
"SA3Generator",
|
||||
"SA5Generator",
|
||||
"SA6Generator",
|
||||
"SA8Generator",
|
||||
"SA9Generator",
|
||||
|
||||
@ -57,6 +57,7 @@
|
||||
"ColdWarFlakGenerator",
|
||||
"SA2Generator",
|
||||
"SA3Generator",
|
||||
"SA5Generator",
|
||||
"SA6Generator",
|
||||
"SA8Generator",
|
||||
"SA8Generator",
|
||||
|
||||
@ -58,6 +58,7 @@
|
||||
"ColdWarFlakGenerator",
|
||||
"SA2Generator",
|
||||
"SA3Generator",
|
||||
"SA5Generator",
|
||||
"SA6Generator",
|
||||
"SA8Generator",
|
||||
"SA8Generator",
|
||||
|
||||
@ -43,6 +43,7 @@
|
||||
],
|
||||
"air_defenses": [
|
||||
"SA3Generator",
|
||||
"SA5Generator",
|
||||
"SA6Generator",
|
||||
"SA8Generator",
|
||||
"SA9Generator",
|
||||
@ -70,4 +71,4 @@
|
||||
"navy_generators": [
|
||||
"GrishaGroupGenerator"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
3
resources/units/ground_units/RPC_5N62V.yaml
Normal file
3
resources/units/ground_units/RPC_5N62V.yaml
Normal file
@ -0,0 +1,3 @@
|
||||
price: 18
|
||||
variants:
|
||||
SAM SA-5 S-200 "Square Pair" TR": null
|
||||
3
resources/units/ground_units/S-200_Launcher.yaml
Normal file
3
resources/units/ground_units/S-200_Launcher.yaml
Normal file
@ -0,0 +1,3 @@
|
||||
price: 12
|
||||
variants:
|
||||
SAM SA-5 S-200 "Gammon" LN": null
|
||||
Loading…
x
Reference in New Issue
Block a user