This PR recovers combat instances from the flight state when
initializing aircraft simulation. Flight states are serialized into a
game save but the state of the aircraft simulation is not. When
deserializing a game, the aircraft simulation would otherwise lose track
of the combat instances, leading the simulation never exiting combat in
some scenarios e.g. when at the mission IP.
Short circuits selecting control points to retreat aircraft to when the
control point being captured has a damaged runway.
Fixes#3434.
I'm not sure how to test this locally though, so I have no idea if it
works.
Adds NASAM launcher B and C to the list of units that can be placed in a
campaign template to define a MERAD spawn location.
This is needed to maintain compatibility with the new versions of my
campaigns.
This PR
- Addresses #1511 by setting the tanker on-station time to the desired
mission duration + 30 minutes
- Elaborate on what the desired mission duration setting does in the
Settings UI.
This PR addresses #2778 by:
- Updating the logic for how redeployment of front line units works to
handle "out of order" captures e.g. for control points A->B->C, where A
starts friendly and B, C starts as enemy-controlled, the player captures
C first, typically using air assault.
- Updating the cheat logic so that capturing CPs using cheats behaves
the same way as capturing CPs normally.
… DCS reports multiple hits
This PR fixes a bug introduced when tracking OCA/Aircraft kills that
results in double counting when DCS reports multiple hits, typically
when guns are used.
This PR addresses #3337 by:
- Updating the UI to identify that a destroyed carrier/LHA as "Sunk"
- Fall back on targeting other groups in the NavalControlPoint (e.g.
escorts if present) if the carrier/LHA is sunk.
This PR partially addresses #3313 by:
- Tracking DCS hit events and storing the unit hit point updates in
state.json
- Adding logic to kill aircraft when the hit points is reduced to 1, as
opposed to the DCS logic of hit points to 0. This behavior allows
Liberation to track deaths to parked aircraft, which are uncontrolled
and seem to have different damage logic in DCS.
- Tracking damage to TheaterGroundObjects across turns and killing the
unit when the unit's hitpoints reduces to 1 or lower.
Intention is to build on this PR by also tracking front line objects and
statics (buildings). However, larger refactoring is required and so
splitting those into a separate PR.
F/A-18E and F/A-18F are added to their factions, Growler is currently in
its respective factions but was released in 2009, this will be changed
if needed.
This PR:
- Introduces a new member of UnitType, hit_points, which is an abstract
representation of the durability of a unit, and loads it in from the
YAML files in the various subclasses (Ship, Ground etc).
- Adds scripts for populating/updating the unit YAML files with hit
point data from DCS. This script also gets the data for static objects,
but I'll leave the plugging in of static object data into Liberation for
another PR.
- Updates the unit YAML files by running the above scripts.
I did toy with the idea of adding this data to the unit definitions in
pydcs via an export from DCS, but it would be a more involved change,
since the current pydcs export script runs in the Hooks Lua environment
in DCS and AFAICT the hit points (via Unit.getLife()) is run in the
mission scripting environment.
This PR:
- Refactors the doctrine class to have a bit more structure, in
anticipation of adding more elements to Doctrine.
- Moves previously hard coded helo-specific altitudes into the Doctrine
class, aligning a bunch of altitudes ~200ft in the process.
- Refactors ingress_altitude to combat_altitude to clarify that the
altitude is applied to multiple waypoint types, not just the ingress
altitude.
This PR 1) introduces a cruise_speed parameter to the AircraftType class
and uses it as an override for default TOT/Ground Speed calculations and
2) sets this for the AH64.
The reason for this change is that air starts with the Apache at a speed
>130kt seems to completely break the FCR, even if you subsequently slow
down. In the development branch, Liberation sets the Apache to travel at
168kt, so any player air starting won't be able to use their FCR and it
wouldn't be readily apparent as to why.
In the longer run this parameter may also be useful for other aircraft
e.g. to override the cruise speed to the most efficient etc.
This PR makes sure that the Payload tab of the Edit Flight window shows
the correct property values (with `default_overrides` applied in the
aircraft YAML). It looks like the issue only affects an obscure
parameter on F14s (INS reference alignment stored) so may not have been
noticed until now.
This PR refactors the Doctrine class to load from YAML files in the
resources folder instead of being hardcoded as a step towards making
doctrines moddable (Issue #829).
I haven't added anything to the changelog as a couple of things should
get cleaned up first:
- As far as I can tell, the flags in the Doctrine class (cap, cas, sead
etc.) aren't used anywhere. Need to test further, and if they're truly
not used, will remove them.
- Probably need to update the Wiki
One of the newer versions got a lot more strict. It now only expects
dicts that match the model, or objects of the model. Previously it also
accepted objects which had the same properties as the model. Convert a
few more LatLngs to LeafletPoints.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/3279.
A lot of the dependency versions we have pinned don't have wheels for
Python 3.12. Update almost all of them so we can upgrade Python.
The few that weren't upgraded here are black and mypy, since those will
be a bit invasive, and Pillow, which has an API change I don't want to
deal with right now (I've got a commit on another machine that has
already done the migration, so I'll do it later).
This is enabled by default because I can't think of a time where it's
ever been more fun to watch the AI run out of fuel after cycling between
afterburner and speedbrake for twenty minutes.
This is only lightly tested (I verified that the task shows up
appropriately in the ME when set, not when unset, and never for
players), since the interesting part of the implementation is up to ED.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/3201.