mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
frontline refactoring
`FrontLine` is tightly coupled with `ConflictTheater`. Moved into the same module to prevent circular imports. Moved `ConflictTheater.frontline_data` from class var to instance var to allow save games to have different versions of frontlines.
This commit is contained in:
@@ -355,7 +355,7 @@ class GroundObjectsGenerator:
|
||||
"""
|
||||
FARP_CAPACITY = 4
|
||||
|
||||
def __init__(self, mission: Mission, conflict: Conflict, game,
|
||||
def __init__(self, mission: Mission, conflict: Conflict, game: Game,
|
||||
radio_registry: RadioRegistry, tacan_registry: TacanRegistry):
|
||||
self.m = mission
|
||||
self.conflict = conflict
|
||||
@@ -370,7 +370,7 @@ class GroundObjectsGenerator:
|
||||
center = self.conflict.center
|
||||
heading = self.conflict.heading - 90
|
||||
else:
|
||||
center, heading = self.conflict.frontline_position(self.conflict.from_cp, self.conflict.to_cp)
|
||||
center, heading = self.conflict.frontline_position(self.conflict.from_cp, self.conflict.to_cp, self.game.theater)
|
||||
heading -= 90
|
||||
|
||||
initial_position = center.point_from_heading(heading, FARP_FRONTLINE_DISTANCE)
|
||||
|
||||
Reference in New Issue
Block a user