mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Configure target points for F-15E S4+.
We don't need explicit configuration of initial points. The plane automatically configures any steerpoint immediately before a target point as an initial point. Target offset points and aim points have not been implemented because I can't find any information the describes their intent. Fixes https://github.com/dcs-liberation/dcs_liberation/issues/3088.
This commit is contained in:
parent
e25aac774f
commit
014ae5faf5
@ -213,6 +213,7 @@ BAI/ANTISHIP/DEAD/STRIKE/BARCAP/CAS/OCA/AIR-ASSAULT (main) missions
|
|||||||
* **[Flight Planning]** Improved IP selection for targets that are near the center of a threat zone.
|
* **[Flight Planning]** Improved IP selection for targets that are near the center of a threat zone.
|
||||||
* **[Flight Planning]** Loadouts and aircraft properties can now be set per-flight member. Warning: AI flights should not use mixed loadouts.
|
* **[Flight Planning]** Loadouts and aircraft properties can now be set per-flight member. Warning: AI flights should not use mixed loadouts.
|
||||||
* **[Flight Planning]** Laser codes that are pre-assigned to weapons at mission start can now be chosen from a list in the loadout UI. This does not affect the aircraft's TGP, just the weapons. Currently only implemented for the F-15E S4+ and F-16C.
|
* **[Flight Planning]** Laser codes that are pre-assigned to weapons at mission start can now be chosen from a list in the loadout UI. This does not affect the aircraft's TGP, just the weapons. Currently only implemented for the F-15E S4+ and F-16C.
|
||||||
|
* **[Mission Generation]** Configured target and initial points for F-15E S4+.
|
||||||
* **[Modding]** Factions can now specify the ship type to be used for cargo shipping. The Handy Wind will be used by default, but WW2 factions can pick something more appropriate.
|
* **[Modding]** Factions can now specify the ship type to be used for cargo shipping. The Handy Wind will be used by default, but WW2 factions can pick something more appropriate.
|
||||||
* **[UI]** An error will be displayed when invalid fast-forward options are selected rather than beginning a never ending simulation.
|
* **[UI]** An error will be displayed when invalid fast-forward options are selected rather than beginning a never ending simulation.
|
||||||
* **[UI]** Added cheats for instantly repairing and destroying runways.
|
* **[UI]** Added cheats for instantly repairing and destroying runways.
|
||||||
|
|||||||
@ -210,6 +210,8 @@ class AircraftType(UnitType[Type[FlyingType]]):
|
|||||||
task_priorities: dict[FlightType, int]
|
task_priorities: dict[FlightType, int]
|
||||||
laser_code_configs: list[LaserCodeConfig]
|
laser_code_configs: list[LaserCodeConfig]
|
||||||
|
|
||||||
|
use_f15e_waypoint_names: bool
|
||||||
|
|
||||||
_by_name: ClassVar[dict[str, AircraftType]] = {}
|
_by_name: ClassVar[dict[str, AircraftType]] = {}
|
||||||
_by_unit_type: ClassVar[dict[type[FlyingType], list[AircraftType]]] = defaultdict(
|
_by_unit_type: ClassVar[dict[type[FlyingType], list[AircraftType]]] = defaultdict(
|
||||||
list
|
list
|
||||||
@ -516,6 +518,7 @@ class AircraftType(UnitType[Type[FlyingType]]):
|
|||||||
laser_code_configs=[
|
laser_code_configs=[
|
||||||
LaserCodeConfig.from_yaml(d) for d in data.get("laser_codes", [])
|
LaserCodeConfig.from_yaml(d) for d in data.get("laser_codes", [])
|
||||||
],
|
],
|
||||||
|
use_f15e_waypoint_names=data.get("use_f15e_waypoint_names", False),
|
||||||
)
|
)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
|||||||
@ -38,11 +38,14 @@ class PydcsWaypointBuilder:
|
|||||||
self.elapsed_mission_time = elapsed_mission_time
|
self.elapsed_mission_time = elapsed_mission_time
|
||||||
self.mission_data = mission_data
|
self.mission_data = mission_data
|
||||||
|
|
||||||
|
def dcs_name_for_waypoint(self) -> str:
|
||||||
|
return self.waypoint.name
|
||||||
|
|
||||||
def build(self) -> MovingPoint:
|
def build(self) -> MovingPoint:
|
||||||
waypoint = self.group.add_waypoint(
|
waypoint = self.group.add_waypoint(
|
||||||
self.waypoint.position,
|
self.waypoint.position,
|
||||||
self.waypoint.alt.meters,
|
self.waypoint.alt.meters,
|
||||||
name=self.waypoint.name,
|
name=self.dcs_name_for_waypoint(),
|
||||||
)
|
)
|
||||||
|
|
||||||
if self.waypoint.flyover:
|
if self.waypoint.flyover:
|
||||||
|
|||||||
14
game/missiongenerator/aircraft/waypoints/target.py
Normal file
14
game/missiongenerator/aircraft/waypoints/target.py
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
from .pydcswaypointbuilder import PydcsWaypointBuilder
|
||||||
|
|
||||||
|
|
||||||
|
class TargetBuilder(PydcsWaypointBuilder):
|
||||||
|
"""Waypoint builder for target waypoint types.
|
||||||
|
|
||||||
|
This handles both precise target locations (TARGET_POINT) and target areas
|
||||||
|
(TARGET_GROUP_LOC).
|
||||||
|
"""
|
||||||
|
|
||||||
|
def dcs_name_for_waypoint(self) -> str:
|
||||||
|
if self.flight.unit_type.use_f15e_waypoint_names:
|
||||||
|
return f"#T {self.waypoint.name}"
|
||||||
|
return super().dcs_name_for_waypoint()
|
||||||
@ -41,6 +41,7 @@ from .seadsweepingress import SeadSweepIngressBuilder
|
|||||||
from .splitpoint import SplitPointBuilder
|
from .splitpoint import SplitPointBuilder
|
||||||
from .strikeingress import StrikeIngressBuilder
|
from .strikeingress import StrikeIngressBuilder
|
||||||
from .sweepingress import SweepIngressBuilder
|
from .sweepingress import SweepIngressBuilder
|
||||||
|
from .target import TargetBuilder
|
||||||
|
|
||||||
|
|
||||||
class WaypointGenerator:
|
class WaypointGenerator:
|
||||||
@ -121,6 +122,10 @@ class WaypointGenerator:
|
|||||||
|
|
||||||
def builder_for_waypoint(self, waypoint: FlightWaypoint) -> PydcsWaypointBuilder:
|
def builder_for_waypoint(self, waypoint: FlightWaypoint) -> PydcsWaypointBuilder:
|
||||||
builders = {
|
builders = {
|
||||||
|
FlightWaypointType.CARGO_STOP: CargoStopBuilder,
|
||||||
|
FlightWaypointType.DROPOFF_ZONE: LandingZoneBuilder,
|
||||||
|
FlightWaypointType.INGRESS_AIR_ASSAULT: AirAssaultIngressBuilder,
|
||||||
|
FlightWaypointType.INGRESS_ANTI_SHIP: AntiShipIngressBuilder,
|
||||||
FlightWaypointType.INGRESS_BAI: BaiIngressBuilder,
|
FlightWaypointType.INGRESS_BAI: BaiIngressBuilder,
|
||||||
FlightWaypointType.INGRESS_CAS: CasIngressBuilder,
|
FlightWaypointType.INGRESS_CAS: CasIngressBuilder,
|
||||||
FlightWaypointType.INGRESS_DEAD: DeadIngressBuilder,
|
FlightWaypointType.INGRESS_DEAD: DeadIngressBuilder,
|
||||||
@ -131,17 +136,15 @@ class WaypointGenerator:
|
|||||||
FlightWaypointType.INGRESS_STRIKE: StrikeIngressBuilder,
|
FlightWaypointType.INGRESS_STRIKE: StrikeIngressBuilder,
|
||||||
FlightWaypointType.INGRESS_SWEEP: SweepIngressBuilder,
|
FlightWaypointType.INGRESS_SWEEP: SweepIngressBuilder,
|
||||||
FlightWaypointType.JOIN: JoinPointBuilder,
|
FlightWaypointType.JOIN: JoinPointBuilder,
|
||||||
FlightWaypointType.SPLIT: SplitPointBuilder,
|
|
||||||
FlightWaypointType.LANDING_POINT: LandingPointBuilder,
|
FlightWaypointType.LANDING_POINT: LandingPointBuilder,
|
||||||
FlightWaypointType.LOITER: HoldPointBuilder,
|
FlightWaypointType.LOITER: HoldPointBuilder,
|
||||||
FlightWaypointType.PATROL: RaceTrackEndBuilder,
|
FlightWaypointType.PATROL: RaceTrackEndBuilder,
|
||||||
FlightWaypointType.PATROL_TRACK: RaceTrackBuilder,
|
FlightWaypointType.PATROL_TRACK: RaceTrackBuilder,
|
||||||
FlightWaypointType.PICKUP_ZONE: LandingZoneBuilder,
|
FlightWaypointType.PICKUP_ZONE: LandingZoneBuilder,
|
||||||
FlightWaypointType.DROPOFF_ZONE: LandingZoneBuilder,
|
|
||||||
FlightWaypointType.REFUEL: RefuelPointBuilder,
|
FlightWaypointType.REFUEL: RefuelPointBuilder,
|
||||||
FlightWaypointType.CARGO_STOP: CargoStopBuilder,
|
FlightWaypointType.SPLIT: SplitPointBuilder,
|
||||||
FlightWaypointType.INGRESS_AIR_ASSAULT: AirAssaultIngressBuilder,
|
FlightWaypointType.TARGET_GROUP_LOC: TargetBuilder,
|
||||||
FlightWaypointType.INGRESS_ANTI_SHIP: AntiShipIngressBuilder,
|
FlightWaypointType.TARGET_POINT: TargetBuilder,
|
||||||
}
|
}
|
||||||
builder = builders.get(waypoint.waypoint_type, DefaultWaypointBuilder)
|
builder = builders.get(waypoint.waypoint_type, DefaultWaypointBuilder)
|
||||||
return builder(
|
return builder(
|
||||||
|
|||||||
@ -9,6 +9,7 @@ origin: USA
|
|||||||
price: 24
|
price: 24
|
||||||
role: Multirole Strike Fighter
|
role: Multirole Strike Fighter
|
||||||
max_range: 300
|
max_range: 300
|
||||||
|
use_f15e_waypoint_names: true
|
||||||
variants:
|
variants:
|
||||||
F-15E Strike Eagle (Suite 4+): {}
|
F-15E Strike Eagle (Suite 4+): {}
|
||||||
F-15I Ra'am: {}
|
F-15I Ra'am: {}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user