1284 Commits

Author SHA1 Message Date
RndName
799e01c7b3
Support for DCS 2.7.12.23362 (#2196)
- Add link4 and acls
- Allocate Link4 frequency
-  new unit yamls
2022-05-02 19:08:44 +02:00
RndName
e4f91fd3ba
Fix AAA not placed as frontline unit
- Spawn AAA like SHORAD
- change SA-19 unit class from AAA to SHORAD

fixes #2194
2022-05-02 18:58:57 +02:00
RndName
41d1ae099f Consider priority order in Aircraft selector 2022-04-25 19:24:48 +02:00
RndName
2836a89f91 Update DEAD task priority list
Set SEAD capable planes with higher priority instead of adding them at the end
2022-04-25 19:24:48 +02:00
RndName
f04030858b Allow custom mission types
Instead of giving an error when a mission type which was added to the squadron is not defined in the Ai autoplanner db for the aircraft the user should be able to task the aircraft accordingly.
2022-04-25 19:24:48 +02:00
RndName
5be92cd75e Cleanup threat and detection range calculation
- Moved logic from TGO to TheaterGroup and Unit, cleanup
- Fixed an issue with wrong radar threat zone calculation
- Correctly handle dead and alive units in threat calculation (dead units are no more threats...)
- Fixed wrong air_defenses threat zone used for planning (now uses aa-capable tgos instead of all tgos for the CP)
- Remove the might_have_aa property from TGOs and actually check if there is any aa-capable unit present (this is needed as with the recent tgo refactor all type of TGOs can also have anti air units if they have some defined in the layout)
2022-04-21 21:20:02 +02:00
RndName
c437fa329c
Improve SEAD ingress tasking and target waypoint
* Fix suicide SEAD flights (diving to the SAM)

additional fix for #2152. This sets the Target Waypoint ALT to the Ingress ALT for non player flights. Player flights will have the target waypoint set to 0 AGL so that they can slave weapons or TGP to it.

* Add GroupAttack to SEAD so that they suppress more
2022-04-20 00:19:03 +02:00
RndName
004bcce58e Allow skynet properties override and improve dead unit handling
Now the user can override special skynet properties from the unit.yaml of the main Radar of the sam site. Which unit needs these overrides can be looked up over here: https://github.com/walder/Skynet-IADS/blob/develop/skynet-iads-source/skynet-iads-supported-types.lua

- fixed wrong exclusion of groups with the first unit dead but still able to participate
- added some exception handling in the lua script for groups which skynet is not able to control. preventing scripting errors
2022-04-19 10:41:16 +02:00
RndName
fd7bd28381 Fix incorrect faction loading 2022-04-19 10:41:16 +02:00
RndName
5569f49456 Bump campaign version to 10.2 2022-04-19 10:41:16 +02:00
RndName
5cdfe62e2d Implement advanced skynet functions
- factor out own class for the iadsnetwork within the conflicttheater
- This class will handle all Skynet related things - no specific group_name handling necessary in future
- make iadsbuilding own TGO class because SAM & EWRs are Vehicle Groups. IADS Elements dont have any groups attached.
- added command center, connection node and power source as Ground objects which can be added by the campaign designer
- adjust lua generator to support new iads units
- parse the campaign yaml to get the iads network information
- use the range as fallback if no yaml information was found
- complete rewrite of the skynet lua script
- allow destruction of iads network to be persistent over all rounds
- modified the presetlocation handling: the wrapper PresetLocation for PointWithHeading now stores the original name from the campaign miz to have the ability to process campaign yaml configurations based on the ground unit
- Implementation of the UI representation for the IADS Network
- Give user the option to enable or disable advanced iads
- Extended the layout system: Implement Sub task handling to support PD
2022-04-19 10:41:16 +02:00
RndName
138e48dc2d Refactor luagenerator
- cleaned up the generation
- created special class to handle the serialization
- improved string escaping: Replace OS Path separator with normal slash and allow the usage of a single quote in unit names by changing the delimiter to double quote instead (1797)
- adjusted unit_name generation to prevent scripting errors with unescaped characters
2022-04-19 10:41:16 +02:00
RndName
679dfc3441
Improve Ingress Waypoint Attack tasking
* Improve Ingress WP attack tasking and update pydcs

- Updated the Attack Tasking of SEAD, DEAD, Strike and BAI to match the pydcs changes
- Changed DEAD, BAI and SEAD AttackGroup task to expend=auto. This solves an issue where the AI uses all Ammo on one single target as we defined the expend param to All instead of Auto which is used by default.

* Set Expend=All for SEAD Ingress

This ensures that the AI will only do one Attack Pass and also really suppress the Target what they are expected to do.
2022-04-19 10:21:15 +02:00
RndName
69a5b4f227 Add modulation to RadioFrequency
- This adds the information about the modulation of the RadioFrequency.
- Updated all Radios with the capabale modulation
- Show Modulation on Kneeboard
- Defaulting to AM Modulation as this is also the default used by pydcs.
- Force AM Modulation for JTAC tasking

We currently do not force the modulation in the code anywhere other than JTAC. Pydcs defaults to AM (modulation=0). So this change is more a preparation for upcoming features which allow to use more frequencies like VHF FM or similar.
2022-04-19 10:19:44 +02:00
MetalStormGhost
4b89220a7b
Added separate base images for carriers
Forrestal, Supercarrier (CVN-75), Kuznetsov, Kuznetsov (2017/Supercarrier) and Type 071 Yuzhao.

Resolves #1292
2022-04-14 11:17:09 +02:00
RndName
25d0dcd08e Allow campaign designer to set default economy values
default starting money and income multiplier can be set in campaign.yaml

bumps campaign Version to 10.1
2022-04-10 10:24:25 +02:00
RndName
1d20e6277e
Fix silkworm launcher falsely added to scud groups
Added AntiShipMissile unit class and updated the hy_launcher unit as well as the silkworm layout to differentiate clearly between missile (scud, v1) and antiship (silkworm)

fixes #2159
2022-04-08 21:30:44 +02:00
RndName
1bb7e1bf47 Change SEAD task to Search and Engage for ARM weapon
SEAD flights will have the Search and Engage Group Task instead of the current AttackGroup task when the flight has ARM weapons in the Loadout. This resolves an issue with AI not able to attack a SAM when skynet is used. This is due to the RADAR not emitting and the AI therefore just diving into the SAM.
Non-ARM Loadouts will still use the AttackGroup task. This ensures that for example the ADM-141 TALD used by the F-14s will work correctly
2022-04-02 10:16:11 +02:00
RndName
23ba3215d4 Add SEAD Escort to tasks_by_priority 2022-04-02 10:16:11 +02:00
RndName
ad8fef2fda
Fix detection range calculation if TGO is empty
implement fix like in #1980
solves #2128
2022-04-01 11:54:47 +02:00
RndName
bc76efaea6
Move the tgo value calculation from UI to the tgo 2022-03-30 12:48:58 +02:00
RndName
6de50d1515 Fix JTAC names
- Add additional naming method to naming.py
- JTACs now use the ALPHA_MILITARY. So first JTAC is called JTAC Alpha, 2nd JTAC is called JTAC Bravo and so on

fixes #2120
2022-03-28 20:32:19 +02:00
Benjamin Fischer
e9c5cac20c
Fix can_operate for airfields without runways.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2110.
2022-03-24 17:15:06 -07:00
RndName
1e19afe0e5
Use Heading from Campaign miz for Buildings
Like with most other GroundObjects now the Buildings also will use the Heading defined in the campaign miz and will place and rotate the generated TGO accordingly there.
2022-03-23 18:02:34 +01:00
RndName
bbb08aa1db Add orientation info and allow user to rotate TGO
- Give user information about the heading of a TGO
- Add a button to change the heading to head to conflic
- Change the orientation of a TGO during Buy
- Run the heading to conflict calculation to change the orientation of the newly bought group. It will then head to the center of the conflict
2022-03-23 17:26:47 +01:00
RndName
274f689f70 Fix Heading to conflict calculation 2022-03-23 17:26:47 +01:00
RndName
892bd9f069 Fix ForceGroup merging and PresetGroup handling 2022-03-23 17:26:47 +01:00
RndName
c7270e8654 Fix error during faction loading
ForceGroup loading failed due to wrong unit parsing and prevented factions without naval units to load before the first faction with naval units got loaded (this affected the Allies 1940 and 44 factions)
2022-03-23 17:26:47 +01:00
RndName
f0a3fd1e3a Merge forcegroups with the same task 2022-03-23 17:26:47 +01:00
RndName
9a2fa50b0f Bump Campaign version to 10.0
The new introduced layout system extends the mission generation so that a campaign designer can now define the heading of the ground objects which will be also used later in mission generation to orient the group accordingly. This removes the randomization of the orientation from the generation.

Most campaigns will not need any updates and will work out of the box.
2022-03-23 17:26:47 +01:00
RndName
4ace13c857 Improve the optional unit handling in layouts
added the fill property to the layout groups which allows to specify if a optional layout group should be filled with a faction accessible unit if it was not defined by the preset groups. This is usefull to allow more generalized templates which for example may or may not have a Search Radar without adding one to all layouts (example: Rapier and Roland Sites which use the generic SHORAD layout)

this fixes an issue which prevented optional units like logistics to be added to the forcegroup if they were not defined in the preset group yaml
2022-03-23 17:26:47 +01:00
RndName
437fdd6d12
Support for the AH-64D radios
- Support for the AH-64D radios
- Mention missing Radio preset support for AH-64D
2022-03-23 17:16:24 +01:00
Dan Albert
3af3bd606c Migrate off deprecated shapely APIs. 2022-03-20 16:00:29 -07:00
Dan Albert
6c1e1e1e95 Remove save compat.
There was a necessary break in the previous commit. Clean up any
existing save compat to go with it.
2022-03-20 16:00:29 -07:00
Dan Albert
039ac9ec74 Replace CP integer ID with a UUID.
This allows unique identification across saves. The front-end needs to
be able to differentiate the first carrier in game A and the first
carrier in game B, but because carriers (and other non-airfield CPs) are
assigned IDs sequentially, collisions were to be expected. The front-end
can't tell the difference between a reloaded game and a new turn, so we
need to ensure different IDs across games.

This is a handy cleanup anyway, since callers constructing CPs no longer
need to manually track the CP ID counter.

Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2078.
2022-03-20 16:00:29 -07:00
Dan Albert
ad37dcce44 Fix broken iteration when clearing ATO.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2046.
2022-03-20 13:40:57 -07:00
Dan Albert
2c041081c9 Start sim if needed.
This used to be accidentally performed by the pause function. That's no
longer done, so start if needed.

Fixes https://github.com/dcs-liberation/dcs_liberation/issues/2098.
2022-03-20 00:02:51 -07:00
Dan Albert
78c3da99f7 Don't initialize the simulation on game update.
Fixes https://github.com/dcs-liberation/dcs_liberation/issues/1844.
2022-03-19 13:51:26 -07:00
RndName
01f872c960 Add support for the flyable Apache. 2022-03-18 00:00:02 -07:00
RndName
46694e458d
Fix for incorrect unit_count in layout
- Raise LayoutException if the unit_count in the layout is greater than the available units
- Fix Flak Layout to solve #2043
2022-03-16 22:10:19 +01:00
Dan Albert
769fe12159 Split flight plan layout into a separate class.
During package planning we don't care about the details of the flight
plan, just the layout (to check if the layout is threatened and we need
escorts). Splitting these will allow us to reduce the amount of work
that must be done in each loop of the planning phase, potentially
caching attempted flight plans between loops.
2022-03-11 16:00:48 -08:00
Dan Albert
fa8c0d9660 Clean up flight plan code.
Split the oversized file into one per plan type. This also moves the
layout responsibility out of the oversized FlightPlanBuilder and into
each flight plan type file.
2022-03-09 02:15:07 -08:00
Dan Albert
4993353184 RTB canceled in-progress flights.
The UI won't stop you from aborting a flight that is already home, but
that should also result in it re-completing again on the next tick.

https://github.com/dcs-liberation/dcs_liberation/issues/1680
2022-03-08 01:04:19 -08:00
Dan Albert
7fe73ad2eb Fix description of dead flights.
Completed is technically correct but not very helpful.
2022-03-07 23:39:43 -08:00
Dan Albert
f63a107c11 Account for time elapsed when leaving combat. 2022-03-07 23:23:52 -08:00
Dan Albert
e36c62b30e Identify aircraft types based on their mission.
It would probably be more accurate to have the icon based on the
aircraft type and use the modifier to indicate the mission, but this
will do for now (I also might have that backwards, I can't find the
guidance because it's in STANAG 1241 which isn't free).

I also increased the icon size a bit in the UI because the longest icon
text ("SEAD") was hard to read.
2022-03-07 21:45:33 -08:00
Dan Albert
73a8ec02b2 Speed up game tick by caching TGO threat regions.
Still more could be done here by caching the merged poly at the theater
level, but this goes a long way.

Aircraft commit regions are already cached (in the FlightState), so
those are already fairly fast. The combined A2A commit boundary could
also potentially be cached at the theater level.
2022-03-07 21:19:04 -08:00
Dan Albert
453f6ac74a Include positions of dead aircraft for the UI. 2022-03-07 19:43:06 -08:00
Dan Albert
895a4eb0dc Make flight death chance not impossible.
The odds of random.random() returning exactly 1.0 are basically nil, and
that was the only way a non-solo flight could lose this.
2022-03-07 19:35:19 -08:00
Dan Albert
005090fbcd Support display of dead flights. 2022-03-07 19:34:51 -08:00