FARP spawn for helis on frontline cas; updated ground object placements

This commit is contained in:
Vasyl Horbachenko
2018-09-11 03:12:33 +03:00
parent ca521e7e51
commit d31876b65e
8 changed files with 97 additions and 54 deletions

View File

@@ -5,6 +5,7 @@ from dcs.mission import *
DISTANCE_FACTOR = 0.5, 1
EXTRA_AA_MIN_DISTANCE = 35000
EXTRA_AA_MAX_DISTANCE = 150000
EXTRA_AA_POSITION_FROM_CP = 550
@@ -58,7 +59,9 @@ class ExtraAAConflictGenerator:
if cp.position.distance_to_point(self.conflict.from_cp.position) < EXTRA_AA_MIN_DISTANCE:
continue
print("generated extra aa for {}".format(cp))
if cp.position.distance_to_point(self.conflict.position) > EXTRA_AA_MAX_DISTANCE:
continue
country_name = cp.captured and self.player_name or self.enemy_name
position = cp.position.point_from_heading(0, EXTRA_AA_POSITION_FROM_CP)