From 911d57b415f0fb328cfe0cbae42cb09bd6ebd80b Mon Sep 17 00:00:00 2001 From: Vasyl Horbachenko Date: Tue, 23 Oct 2018 03:08:01 +0300 Subject: [PATCH] fixed FOB generation --- gen/groundobjectsgen.py | 5 +++-- theater/caucasus.py | 7 +++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/gen/groundobjectsgen.py b/gen/groundobjectsgen.py index dfb27b7f..9ec1cb3f 100644 --- a/gen/groundobjectsgen.py +++ b/gen/groundobjectsgen.py @@ -27,9 +27,10 @@ class GroundObjectsGenerator: center, heading = self.conflict.frontline_position(self.conflict.theater, self.conflict.from_cp, self.conflict.to_cp) heading -= 90 - position = self.conflict.find_ground_position(center.point_from_heading(heading, FARP_FRONTLINE_DISTANCE), heading) + initial_position = center.point_from_heading(heading, FARP_FRONTLINE_DISTANCE) + position = self.conflict.find_ground_position(initial_position, heading) if not position: - return + position = initial_position for i, _ in enumerate(range(0, number_of_units, self.FARP_CAPACITY)): position = position.point_from_heading(0, i * 275) diff --git a/theater/caucasus.py b/theater/caucasus.py index 51922926..b6506b0b 100644 --- a/theater/caucasus.py +++ b/theater/caucasus.py @@ -64,10 +64,9 @@ class CaucasusTheater(ConflictTheater): self.add_controlpoint(self.gudauta, connected_to=[self.sochi, self.sukhumi]) self.add_controlpoint(self.sochi, connected_to=[self.gudauta, self.gelendzhik]) - self.add_controlpoint(self.gelendzhik, connected_to=[self.sochi, self.novorossiysk]) - self.add_controlpoint(self.novorossiysk, connected_to=[self.gelendzhik, self.anapa]) - self.add_controlpoint(self.krymsk, connected_to=[self.novorossiysk, self.anapa, self.krasnodar]) - self.add_controlpoint(self.anapa, connected_to=[self.novorossiysk, self.krymsk]) + self.add_controlpoint(self.gelendzhik, connected_to=[self.sochi, ]) + self.add_controlpoint(self.krymsk, connected_to=[self.anapa, self.krasnodar]) + self.add_controlpoint(self.anapa, connected_to=[self.krymsk]) self.add_controlpoint(self.krasnodar, connected_to=[self.krymsk, self.maykop]) self.add_controlpoint(self.carrier_1)