mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Add UI-zone for SEAD Sweep
This commit is contained in:
parent
a7d091c142
commit
7a84181bbc
@ -8,10 +8,12 @@ from .formationattack import (
|
|||||||
FormationAttackFlightPlan,
|
FormationAttackFlightPlan,
|
||||||
FormationAttackLayout,
|
FormationAttackLayout,
|
||||||
)
|
)
|
||||||
|
from .uizonedisplay import UiZoneDisplay, UiZone
|
||||||
from ..flightwaypointtype import FlightWaypointType
|
from ..flightwaypointtype import FlightWaypointType
|
||||||
|
from ...utils import nautical_miles
|
||||||
|
|
||||||
|
|
||||||
class SeadSweepFlightPlan(FormationAttackFlightPlan):
|
class SeadSweepFlightPlan(FormationAttackFlightPlan, UiZoneDisplay):
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def builder_type() -> Type[Builder]:
|
def builder_type() -> Type[Builder]:
|
||||||
return Builder
|
return Builder
|
||||||
@ -19,6 +21,14 @@ class SeadSweepFlightPlan(FormationAttackFlightPlan):
|
|||||||
def default_tot_offset(self) -> timedelta:
|
def default_tot_offset(self) -> timedelta:
|
||||||
return -timedelta(minutes=2)
|
return -timedelta(minutes=2)
|
||||||
|
|
||||||
|
def ui_zone(self) -> UiZone:
|
||||||
|
return UiZone(
|
||||||
|
[self.tot_waypoint.position],
|
||||||
|
nautical_miles(
|
||||||
|
self.flight.coalition.game.settings.sead_sweep_engagement_range_distance
|
||||||
|
),
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
class Builder(FormationAttackBuilder[SeadSweepFlightPlan, FormationAttackLayout]):
|
class Builder(FormationAttackBuilder[SeadSweepFlightPlan, FormationAttackLayout]):
|
||||||
def layout(self) -> FormationAttackLayout:
|
def layout(self) -> FormationAttackLayout:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user