mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Ground objects are always generated and destroyable, even when it's not the current mission objective.
Fix : SAM site destruction status is saved correctly. Added most SAM site to generator.
This commit is contained in:
21
gen/sam/sam_rapier.py
Normal file
21
gen/sam/sam_rapier.py
Normal file
@@ -0,0 +1,21 @@
|
||||
import random
|
||||
|
||||
from dcs.vehicles import AirDefence
|
||||
|
||||
from gen.sam.group_generator import AntiAirGroupGenerator
|
||||
|
||||
|
||||
class RapierGenerator(AntiAirGroupGenerator):
|
||||
"""
|
||||
This generate a Rapier Group
|
||||
"""
|
||||
|
||||
def generate(self):
|
||||
self.add_unit(AirDefence.Rapier_FSA_Blindfire_Tracker, "BT", self.position.x, self.position.y, self.heading)
|
||||
self.add_unit(AirDefence.Rapier_FSA_Optical_Tracker, "OT", self.position.x + 20, self.position.y, self.heading)
|
||||
|
||||
num_launchers = random.randint(3, 6)
|
||||
positions = self.get_circular_position(num_launchers, launcher_distance=80, coverage=240)
|
||||
|
||||
for i, position in enumerate(positions):
|
||||
self.add_unit(AirDefence.Rapier_FSA_Launcher, "LN#" + str(i), position[0], position[1], position[2])
|
||||
Reference in New Issue
Block a user