4398 Commits

Author SHA1 Message Date
Raffson
978e3e4de2
Formatting + type annotations 2023-05-18 16:29:20 +02:00
Raffson
da109146c9
Fixing issues after using actual Country in Faction 2023-05-18 16:24:49 +02:00
Raffson
cca45d3729
Fix save-compat issues 2023-05-18 14:37:34 +02:00
Raffson
b14059e134
Fixing tests + mypy issues 2023-05-18 14:12:41 +02:00
Starfire13
cb6a7d4a92
Update Starfire's campaign updates for 10.7. 2023-05-18 14:03:20 +02:00
Dan Albert
51d823a0b2
Add changelog note for pydcs livery scanner crash fix.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2747.
2023-05-18 14:02:39 +02:00
Dan Albert
5cfc9aa518
Add changelog note for TALD overfly fix.
https://github.com/dcs-liberation/dcs_liberation/issues/2781
2023-05-18 14:02:39 +02:00
Dan Albert
0dea18f582
Add changelog note for "recreate as" fix.
https://github.com/dcs-liberation/dcs_liberation/issues/2779
2023-05-18 14:02:39 +02:00
Dan Albert
53df67e641
Add changelog note for fixed recovery tanker tasks.
https://github.com/dcs-liberation/dcs_liberation/issues/2771
2023-05-18 14:02:39 +02:00
Dan Albert
2448ffe337
Add changelog note for improved dead event handling.
https://github.com/dcs-liberation/dcs_liberation/issues/2765
2023-05-18 14:02:38 +02:00
Dan Albert
9ace5bab94
Add changelog note for air wing reset fix.
https://github.com/dcs-liberation/dcs_liberation/issues/2751
2023-05-18 14:02:38 +02:00
Dan Albert
ccf2d11034
Add changelog note for BAI planning fix.
https://github.com/dcs-liberation/dcs_liberation/issues/2618
2023-05-18 14:02:25 +02:00
Dan Albert
190b6c6e7a
Add changelog note for built-in TGP fix. 2023-05-18 14:02:25 +02:00
Dan Albert
573ccb0bc6
Add changelog note for AEW&C planning fix.
https://github.com/dcs-liberation/dcs_liberation/issues/2048
2023-05-18 14:02:25 +02:00
Dan Albert
910fd27c14
Add changelog note for TALD fix.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2780.
2023-05-18 14:02:06 +02:00
Dan Albert
5f65298728
Finish wiring up SAM orientation control.
The UI works beautifully, but that's not worth much if it doesn't
actually change the data...

Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2479.
2023-05-18 14:02:05 +02:00
Raffson
4ca150198e
Delete germany_1944_free.yaml 2023-05-18 14:01:12 +02:00
Raffson
71f6186a88
Reuse Ghosti's NightMission conditions 2023-05-18 13:40:29 +02:00
zhexu14
e3fce5fddc
add unit tests for mission_types function in controlpoint objects (#2870)
This PR adds unit tests that can be planned against control points.
2023-05-18 13:33:49 +02:00
zhexu14
958252515e
Update ADM141 data to include clsids for hornet 2023-05-18 13:33:48 +02:00
Dan Albert
0e139b8640
Make wind speed moddable.
These should probably be overridable per theater and per season, but
even with that we'll want some defaults.

https://github.com/dcs-liberation/dcs_liberation/issues/2862
2023-05-18 13:33:39 +02:00
Dan Albert
8ed843a9cf
Move and split up weather.py.
This is getting out of hand, and I'm about to make it worse.
2023-05-18 13:31:26 +02:00
Dan Albert
080d346517
Rework wind speed Weibull inputs, tune.
The previous method of using a uniform scalar of the MSL wind speed for
higher altitudes didn't offer enough control. In particular, the shape
needs to be quite different to skew low, mid, high.

This patch reworks that system so the parameters of each distribution
are configured per-altitude level. To keep some continuity between
altitudes (on a windy day, all levels should have higher wind speeds on
average), the wind speed of the lower altitude will be added to the
scale value of the higher altitude.

Since it wasn't practical to approximate the previous behavior with the
new system, this also handles the tuning of each. The low altitude
speeds remain mostly unchanged (typically around 5 knots expect for
thunderstorms), but the average speeds for other altitudes went up to
more closely match the previous intent but without the massive
overshoot. At 2000m wind speeds are typically in the 20-25 knot range
now, and 8000m 30-50 knots.

https://www.quora.com/What-is-the-average-wind-speed-at-different-altitudes
has some of the source data, and Quora is the most authoritative source
there is. It claims that cruise altitude winds can get "as high as 150
knots", but doesn't claim anything about the average. I had a
surprisingly difficult time finding good data for cruise altitude air
speeds for non-jet stream paths (though many of our maps are in jet
streams), so I just eyeballed it from
https://turbli.com/wind-during-flights/.

https://github.com/dcs-liberation/dcs_liberation/issues/2861

Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2863.
2023-05-18 13:29:02 +02:00
Dan Albert
73e0cbe182
Use weibull distribution for wind generation.
Wind speeds should not be uniformly distributed. This switches to a
Weibull distribution which allegedly (see the bug) is good enough.
Experimentally that seems true as well, though I know nothing about how
wind works irl. This at least looks like it'll generate reasonable
variation in missions while keeping the 1st through 3rd quartile
behaviors from getting out of hand.

I'm very uncertain about the scaling factor aspect of this. Naively the
wind speeds at different altitudes ought to be somewhat correlated, but
I'm not sure how much, and whether this kind of scaling is at all the
right way to do it. As before, meh, close enough?

Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2861.
2023-05-18 13:29:02 +02:00
Raffson
b750099b16
Add missing tasks in aircraft yamls 2023-05-18 13:14:22 +02:00
Raffson
f00a3fb1d2
pydcs update: refactored livery-scanner 2023-05-16 21:45:27 +02:00
Raffson
1b1090d78f
Fix exception wrt typing 2023-05-16 21:45:26 +02:00
Raffson
34645560bf
Migration changes 2023-05-16 21:45:26 +02:00
Raffson
785beffee0
Cleanup after cherry-picking... 2023-05-14 21:37:24 +02:00
Dan Albert
f9e9c2793a
Allow manual SAM orientation.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2479.
2023-05-14 21:08:29 +02:00
Dan Albert
83916b9fb0
Wrap settings titles. 2023-05-14 21:08:09 +02:00
zhexu14
ac5c13663b
add tests for mission_types for various theather ground objects 2023-05-14 21:08:09 +02:00
ColonelAkirNakesh
e92d6d0c1c
Makes guard tower (house2arm) a AAA unit 2023-05-14 21:08:09 +02:00
Dan Albert
b44249317a
Remove old aircraft selection mode.
New mode seems to be working well.
2023-05-14 21:04:43 +02:00
Starfire13
e8e0452f32
Update B-52H.yaml
Added antiship mission type to B52
2023-05-14 21:04:09 +02:00
Dan Albert
0608089eb0
Use the actual Country type instead of the name.
We want other pieces of country information (in particular the short
names). This cleans up a lot of code anyway.

As an added bonus, this now catches squadrons that used invalid names
which would previously be passed through to pydcs and... then I don't
know what would happen.
2023-05-14 21:04:09 +02:00
Dan Albert
b3e21498fd
Fix broken squadron.
It's "The Netherlands", not "Netherlands".
2023-05-14 20:57:43 +02:00
ColonelAkirNakesh
9c407a6204
Germany 1944 free unit list fixes.
1. Removes Flak18 as these currently require Kdo.G.40. (part of the WW2
Asset Pack) to fire at player. ED-supplied single missions are having
Flak18s w/out WW2 Asset Pack firing at a point in the air.

2. Adds Opel Blitz to frontline for more variety, balance, and some
little bit of historical accuracy. My understanding is late war was more
truck strafing than HVARing Panzers.

3. Adds guard tower to AAA units to have a functioning AAA since Flak18s
don't work.
2023-05-14 20:57:43 +02:00
Dan Albert
9ec879cea0
Move code docs to a readthedocs project.
Ported the existing docs, but the real goal is getting the docs for
campaign version moved here, as well as the manual. RTD will have an
"edit on github" button that'll keep this accessible to players, but
it'll be much easier to keep docs up to date while developing features
if it's part of the code base.
2023-05-14 20:57:29 +02:00
Dan Albert
5c07a2556e
Add option to limit squadron sizes and begin full.
Adding temporarily as an option to make sure it's not a terrible idea,
but the old mode will probably go away.

Fixes https://github.com/dcs-liberation/dcs_liberation/issues/1583.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2808.
2023-05-14 20:56:58 +02:00
Dan Albert
f719e1cfe7
Add an option to prefer primary tasked aircraft.
We're still using mostly the same aircraft selection as we have before
we added squadrons: the closest aircraft is the best choice.

This adds an option to obey the primary task set by the campaign
designer (can be overridden by players), even if the squadron is farther
away than one that is capable of it as a secondary task.

I don't expect this option to live very long. I'm making it optional for
now to give people a chance to test it, but it'll either replace the old
selection strategy or will be removed.

Fixes https://github.com/dcs-liberation/dcs_liberation/issues/1892.
2023-05-14 20:33:55 +02:00
Dan Albert
e95a6bf759
Support replacing squadrons in-place. 2023-05-14 17:37:53 +02:00
Raffson
7bbf5d59e4
Update package-lock.json 2023-05-14 17:31:18 +02:00
zhexu14
790d08fa13
enable AEWC missions on FOBs 2023-05-14 17:30:20 +02:00
Dan Albert
0a4706e6f4
Make patch check informational as well. 2023-05-14 17:28:54 +02:00
Dan Albert
af833f6682
Expand python coverage, use coveragerc. 2023-05-14 17:28:54 +02:00
Dan Albert
6de4df23b2
Make coverage checks informational.
PRs shouldn't be failing because coverage dropped. Not until our tests
aren't terrible, anyway.
2023-05-14 17:28:47 +02:00
Dan Albert
2c9dcd430f
Add a test for the Aircraft component.
Leaflet (or maybe react-leaflet?) isn't very testable, so we can really
only test that mocks were called with the right props for the leaflet
components we expect, but that's still better than nothing.
2023-05-14 17:28:46 +02:00
Dan Albert
71c2eb3567
Test typescript and collect coverage.
We don't actually have any tests yet :(
2023-05-14 17:28:46 +02:00
Dan Albert
c02351fde3
Don't fail PRs that regress coverage.
Most of our code is barely testable and our coverage isn't anything to
brag about.
2023-05-14 17:27:39 +02:00