mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Merge branch 'theater-refactor' into develop
This commit is contained in:
@@ -38,6 +38,7 @@ from gen.sam.sam_zu23_ural import ZU23UralGenerator
|
||||
from gen.sam.sam_zu23_ural_insurgent import ZU23UralInsurgentGenerator
|
||||
from gen.sam.freya_ewr import FreyaGenerator
|
||||
from theater import TheaterGroundObject
|
||||
from theater.theatergroundobject import SamGroundObject
|
||||
|
||||
SAM_MAP = {
|
||||
"HawkGenerator": HawkGenerator,
|
||||
@@ -129,13 +130,13 @@ def generate_anti_air_group(game: Game, ground_object: TheaterGroundObject,
|
||||
possible_sams_generators = get_faction_possible_sams_generator(faction)
|
||||
if len(possible_sams_generators) > 0:
|
||||
sam_generator_class = random.choice(possible_sams_generators)
|
||||
generator = sam_generator_class(game, ground_object, db.FACTIONS[faction])
|
||||
generator = sam_generator_class(game, ground_object)
|
||||
generator.generate()
|
||||
return generator.get_generated_group()
|
||||
return None
|
||||
|
||||
|
||||
def generate_shorad_group(game: Game, ground_object: TheaterGroundObject,
|
||||
def generate_shorad_group(game: Game, ground_object: SamGroundObject,
|
||||
faction_name: str) -> Optional[VehicleGroup]:
|
||||
faction = db.FACTIONS[faction_name]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user