Force DEAD strike attack run direction

This commit is contained in:
Raffson 2023-03-10 23:50:45 +01:00
parent e1e1689d23
commit 218e783bb1
No known key found for this signature in database
GPG Key ID: B0402B2C9B764D99
2 changed files with 5 additions and 1 deletions

View File

@ -1,4 +1,5 @@
import logging import logging
import math
from dcs.point import MovingPoint from dcs.point import MovingPoint
from dcs.task import AttackGroup, OptECMUsing, WeaponType, Expend from dcs.task import AttackGroup, OptECMUsing, WeaponType, Expend
@ -30,10 +31,13 @@ class DeadIngressBuilder(PydcsWaypointBuilder):
task = AttackGroup(miz_group.id, weapon_type=WeaponType.Guided) task = AttackGroup(miz_group.id, weapon_type=WeaponType.Guided)
waypoint.tasks.append(task) waypoint.tasks.append(task)
dir = target.position.heading_between_point(waypoint.position)
task = AttackGroup( task = AttackGroup(
miz_group.id, miz_group.id,
weapon_type=WeaponType.Unguided, weapon_type=WeaponType.Unguided,
expend=Expend.All, expend=Expend.All,
direction=math.radians(dir),
) )
waypoint.tasks.append(task) waypoint.tasks.append(task)

View File

@ -30,7 +30,7 @@ platformdirs==2.5.4
pluggy==1.0.0 pluggy==1.0.0
pre-commit==2.20.0 pre-commit==2.20.0
pydantic==1.10.2 pydantic==1.10.2
-e git+https://github.com/dcs-retribution/pydcs@25dc257b0b4da1f50ddfa9c6c5863996bc75472b#egg=pydcs -e git+https://github.com/dcs-retribution/pydcs@d325c620bfb714c035931d9a7291c85c0eaf9257#egg=pydcs
pyinstaller==5.6.2 pyinstaller==5.6.2
pyinstaller-hooks-contrib==2022.13 pyinstaller-hooks-contrib==2022.13
pyparsing==3.0.9 pyparsing==3.0.9