mirror of
https://github.com/dcs-liberation/dcs_liberation.git
synced 2025-11-10 14:22:26 +00:00
Stop projecting threat zones from front lines.
This is an interim improvement since we should probably be pushing the BARCAPs into TARCAP roles when the front line is so close. This does regress flight pathing for anything that should route around the front (to avoid getting shot at by SHORADS and TARCAPs), but for now it's one or the other and this is the one everyone's complaining about.
This commit is contained in:
parent
132ba905c7
commit
e474748f4d
@ -18,6 +18,7 @@ Saves from 2.5 are not compatible with 2.6.
|
|||||||
|
|
||||||
* **[UI]** Engagement ranges are now displayed by default.
|
* **[UI]** Engagement ranges are now displayed by default.
|
||||||
* **[UI]** Engagement range display generalized to work for all patrolling flight plans (BARCAP, TARCAP, and CAS).
|
* **[UI]** Engagement range display generalized to work for all patrolling flight plans (BARCAP, TARCAP, and CAS).
|
||||||
|
* **[Flight Planner]** Front lines no longer project threat zones to avoid pushing BARCAPs back so much. TARCAPs will be forcibly planned but strike packages will not route around front lines even if it is reasonable to do so.
|
||||||
|
|
||||||
## Fixes
|
## Fixes
|
||||||
|
|
||||||
|
|||||||
@ -152,23 +152,6 @@ class ThreatZones:
|
|||||||
threat_zone = point.buffer(threat_range.meters)
|
threat_zone = point.buffer(threat_range.meters)
|
||||||
air_defenses.append(threat_zone)
|
air_defenses.append(threat_zone)
|
||||||
|
|
||||||
for front_line in game.theater.conflicts(player):
|
|
||||||
vector = Conflict.frontline_vector(
|
|
||||||
front_line.control_point_a, front_line.control_point_b, game.theater
|
|
||||||
)
|
|
||||||
|
|
||||||
start = vector[0]
|
|
||||||
end = vector[0].point_from_heading(vector[1], vector[2])
|
|
||||||
|
|
||||||
line = LineString(
|
|
||||||
[
|
|
||||||
ShapelyPoint(start.x, start.y),
|
|
||||||
ShapelyPoint(end.x, end.y),
|
|
||||||
]
|
|
||||||
)
|
|
||||||
doctrine = game.faction_for(player).doctrine
|
|
||||||
air_threats.append(line.buffer(doctrine.cap_engagement_range.meters))
|
|
||||||
|
|
||||||
return cls(
|
return cls(
|
||||||
airbases=unary_union(air_threats), air_defenses=unary_union(air_defenses)
|
airbases=unary_union(air_threats), air_defenses=unary_union(air_defenses)
|
||||||
)
|
)
|
||||||
|
|||||||
@ -589,9 +589,23 @@ class CoalitionMissionPlanner:
|
|||||||
front_line,
|
front_line,
|
||||||
[
|
[
|
||||||
ProposedFlight(FlightType.CAS, 2, self.MAX_CAS_RANGE),
|
ProposedFlight(FlightType.CAS, 2, self.MAX_CAS_RANGE),
|
||||||
ProposedFlight(
|
# This is *not* an escort because front lines don't create a threat
|
||||||
FlightType.TARCAP, 2, self.MAX_CAP_RANGE, EscortType.AirToAir
|
# zone. Generating threat zones from front lines causes the front
|
||||||
),
|
# line to push back BARCAPs as it gets closer to the base. While
|
||||||
|
# front lines do have the same problem of potentially pulling
|
||||||
|
# BARCAPs off bases to engage a front line TARCAP, that's probably
|
||||||
|
# the one time where we do want that.
|
||||||
|
#
|
||||||
|
# TODO: Use intercepts and extra TARCAPs to cover bases near fronts.
|
||||||
|
# We don't have intercept missions yet so this isn't something we
|
||||||
|
# can do today, but we should probably return to having the front
|
||||||
|
# line project a threat zone (so that strike missions will route
|
||||||
|
# around it) and instead *not plan* a BARCAP at bases near the
|
||||||
|
# front, since there isn't a place to put a barrier. Instead, the
|
||||||
|
# aircraft that would have been a BARCAP could be used as additional
|
||||||
|
# interceptors and TARCAPs which will defend the base but won't be
|
||||||
|
# trying to avoid front line contacts.
|
||||||
|
ProposedFlight(FlightType.TARCAP, 2, self.MAX_CAP_RANGE),
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user