mirror of
https://github.com/dcs-liberation/dcs_liberation.git
synced 2025-11-10 14:22:26 +00:00
Remove unneeded LandRefuel from Airlift
This commit is contained in:
parent
4531fc7f37
commit
123db516ad
@ -129,16 +129,6 @@ class Builder(IBuilder[AirliftFlightPlan, AirliftLayout]):
|
|||||||
altitude_is_agl,
|
altitude_is_agl,
|
||||||
)
|
)
|
||||||
|
|
||||||
if self.flight.client_count > 0:
|
|
||||||
# Normal Landing Waypoint
|
|
||||||
arrival = builder.land(self.flight.arrival)
|
|
||||||
else:
|
|
||||||
# The AI Needs another landing&refuel point to actually fly back to the original
|
|
||||||
# base. Otherwise the Cargo drop will be the new Landing Waypoint and the
|
|
||||||
# AI will end its mission there instead of flying back.
|
|
||||||
# https://forum.dcs.world/topic/211775-landing-to-refuel-and-rearm-the-landingrefuar-waypoint/
|
|
||||||
arrival = builder.land_refuel(self.flight.arrival, True)
|
|
||||||
|
|
||||||
return AirliftLayout(
|
return AirliftLayout(
|
||||||
departure=builder.takeoff(self.flight.departure),
|
departure=builder.takeoff(self.flight.departure),
|
||||||
nav_to_pickup=nav_to_pickup,
|
nav_to_pickup=nav_to_pickup,
|
||||||
@ -158,7 +148,7 @@ class Builder(IBuilder[AirliftFlightPlan, AirliftLayout]):
|
|||||||
altitude,
|
altitude,
|
||||||
altitude_is_agl,
|
altitude_is_agl,
|
||||||
),
|
),
|
||||||
arrival=arrival,
|
arrival=builder.land(self.flight.arrival),
|
||||||
divert=builder.divert(self.flight.divert),
|
divert=builder.divert(self.flight.divert),
|
||||||
bullseye=builder.bullseye(),
|
bullseye=builder.bullseye(),
|
||||||
)
|
)
|
||||||
|
|||||||
@ -500,38 +500,6 @@ class WaypointBuilder:
|
|||||||
pretty_name="Target area",
|
pretty_name="Target area",
|
||||||
)
|
)
|
||||||
|
|
||||||
@staticmethod
|
|
||||||
def land_refuel(
|
|
||||||
control_point: ControlPoint, is_destination: bool = False
|
|
||||||
) -> FlightWaypoint:
|
|
||||||
"""Creates a land refuel waypoint.
|
|
||||||
|
|
||||||
Args:
|
|
||||||
control_point: The airbase to refuel.
|
|
||||||
is_destination: Due to an DCS Bug we need to set the last landing waypoint also as LandingReFuAr
|
|
||||||
"""
|
|
||||||
if is_destination:
|
|
||||||
return FlightWaypoint(
|
|
||||||
"LANDING",
|
|
||||||
FlightWaypointType.LAND_REFUEL,
|
|
||||||
control_point.position,
|
|
||||||
meters(0),
|
|
||||||
"RADIO",
|
|
||||||
description=f"Land at {control_point}",
|
|
||||||
pretty_name="Landing",
|
|
||||||
control_point=control_point,
|
|
||||||
)
|
|
||||||
return FlightWaypoint(
|
|
||||||
"REFUEL",
|
|
||||||
FlightWaypointType.LAND_REFUEL,
|
|
||||||
control_point.position,
|
|
||||||
meters(0),
|
|
||||||
"RADIO",
|
|
||||||
description=f"Refuel at {control_point}",
|
|
||||||
pretty_name="Refuel",
|
|
||||||
control_point=control_point,
|
|
||||||
)
|
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def cargo_pickup(pick_up: MissionTarget, is_helo: bool) -> FlightWaypoint:
|
def cargo_pickup(pick_up: MissionTarget, is_helo: bool) -> FlightWaypoint:
|
||||||
"""Creates a cargo pickup waypoint.
|
"""Creates a cargo pickup waypoint.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user