Compare commits
64 Commits
2.0.11
...
2.1.1-alph
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d213fa1b91 | ||
|
|
4b2804427e | ||
|
|
d707a59a71 | ||
|
|
923358b364 | ||
|
|
1d0c0ac19c | ||
|
|
7c97ecddac | ||
|
|
bcae51cc92 | ||
|
|
18896a69cf | ||
|
|
4c310d268d | ||
|
|
70babd9c32 | ||
|
|
15d0edce2e | ||
|
|
d7ab1774ac | ||
|
|
42d9607b0d | ||
|
|
bf82474fd7 | ||
|
|
64211275cc | ||
|
|
cf8060f7ff | ||
|
|
cee1d01d9a | ||
|
|
536d763a8e | ||
|
|
6d27b6ce41 | ||
|
|
0d05655e94 | ||
|
|
9cf697d72c | ||
|
|
f0f818c524 | ||
|
|
d2a3448819 | ||
|
|
1a25b15bce | ||
|
|
83808a63ed | ||
|
|
515d1d0dee | ||
|
|
2d47df96b6 | ||
|
|
ad4d71316f | ||
|
|
40932c9e84 | ||
|
|
59bee5f23e | ||
|
|
e6f00febea | ||
|
|
6ea694bc7e | ||
|
|
8f7a8edde4 | ||
|
|
11c7107152 | ||
|
|
d18a9f376f | ||
|
|
6ba95d8c70 | ||
|
|
1c00418d64 | ||
|
|
602e7fb530 | ||
|
|
e6a0a1d4a4 | ||
|
|
136cf143bd | ||
|
|
5afa2a23f6 | ||
|
|
513c81b508 | ||
|
|
45af66e000 | ||
|
|
b38f6c39e4 | ||
|
|
036874fbf0 | ||
|
|
9f3b49a7f5 | ||
|
|
9c35156db9 | ||
|
|
ab2edc6e59 | ||
|
|
9af278217c | ||
|
|
13dbc9c0fe | ||
|
|
14f7fbe794 | ||
|
|
a60e6aa860 | ||
|
|
220e72322c | ||
|
|
1a100dc54b | ||
|
|
04b95c986d | ||
|
|
8f6bb90945 | ||
|
|
50e78bd069 | ||
|
|
ce60e1a8f8 | ||
|
|
fb7ed19f7a | ||
|
|
970888b5ca | ||
|
|
8c934654ba | ||
|
|
ad3dc70cfd | ||
|
|
ae5949bc7f | ||
|
|
c7c563e68c |
107
.github/workflows/release.yml
vendored
Normal file
@@ -0,0 +1,107 @@
|
|||||||
|
name: Release Pipeline
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags: [ '*' ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build:
|
||||||
|
runs-on: windows-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
submodules: true
|
||||||
|
|
||||||
|
- name: Set up Python 3.8
|
||||||
|
uses: actions/setup-python@v2
|
||||||
|
with:
|
||||||
|
python-version: 3.8
|
||||||
|
|
||||||
|
- name: Install environment
|
||||||
|
run: |
|
||||||
|
py -m venv ./venv
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
./venv/scripts/activate
|
||||||
|
pip install -r requirements.txt
|
||||||
|
# For some reason the shiboken2.abi3.dll is not found properly, so I copy it instead
|
||||||
|
Copy-Item .\venv\Lib\site-packages\shiboken2\shiboken2.abi3.dll .\venv\Lib\site-packages\PySide2\ -Force
|
||||||
|
|
||||||
|
- name: Build binaries
|
||||||
|
run: |
|
||||||
|
./venv/scripts/activate
|
||||||
|
$env:PYTHONPATH=".;./pydcs"
|
||||||
|
pyinstaller pyinstaller.spec
|
||||||
|
|
||||||
|
- name: Create Installer
|
||||||
|
env:
|
||||||
|
TAG_NAME: ${{ github.ref }}
|
||||||
|
run: |
|
||||||
|
$version = ($env:TAG_NAME -split "/") | Select-Object -Last 1
|
||||||
|
(Get-Content .\installer\dcs_liberation.iss) -replace "{{version}}",$version | Out-File .\build\installer.iss
|
||||||
|
cd .\installer
|
||||||
|
iscc.exe ..\build\installer.iss
|
||||||
|
cd ..
|
||||||
|
Copy-Item .\changelog.md .\dist
|
||||||
|
|
||||||
|
- uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: dcs_liberation
|
||||||
|
path: dist/
|
||||||
|
|
||||||
|
release:
|
||||||
|
needs: [ build ]
|
||||||
|
runs-on: windows-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/download-artifact@v2
|
||||||
|
with:
|
||||||
|
name: dcs_liberation
|
||||||
|
|
||||||
|
- name: "Get Version"
|
||||||
|
id: version
|
||||||
|
env:
|
||||||
|
TAG_NAME: ${{ github.ref }}
|
||||||
|
run: |
|
||||||
|
Get-ChildItem -Recurse -Depth 1
|
||||||
|
$version = ($env:TAG_NAME -split "/") | Select-Object -Last 1
|
||||||
|
$prerelease = ("2.1.1-alpha3" -match '[^\.\d]').ToString().ToLower()
|
||||||
|
Write-Host $version
|
||||||
|
Write-Host $prerelease
|
||||||
|
Write-Output "::set-output name=number::$version"
|
||||||
|
Write-Output "::set-output name=prerelease::$prerelease"
|
||||||
|
$changelog = Get-Content .\changelog.md
|
||||||
|
$last_change = ($changelog | Select-String -Pattern "^#\s" | Select-Object -Skip 1 -First 1).LineNumber - 2
|
||||||
|
($changelog | Select-Object -First $last_change) -join "`n" | Out-File .\releasenotes.md
|
||||||
|
Compress-Archive -Path .\dcs_liberation -DestinationPath "dcs_liberation.$version.zip" -Compression Optimal
|
||||||
|
|
||||||
|
- uses: actions/create-release@v1
|
||||||
|
id: create_release
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
tag_name: ${{ github.ref }}
|
||||||
|
release_name: ${{ github.ref }}
|
||||||
|
body_path: releasenotes.md
|
||||||
|
draft: false
|
||||||
|
prerelease: ${{ steps.version.outputs.prerelease }}
|
||||||
|
|
||||||
|
- uses: actions/upload-release-asset@v1
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||||||
|
asset_path: ./dcs_liberation.exe
|
||||||
|
asset_name: dcs_liberation.${{ steps.version.outputs.number }}.exe
|
||||||
|
asset_content_type: application/exe
|
||||||
|
|
||||||
|
- uses: actions/upload-release-asset@v1
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||||||
|
asset_path: ./dcs_liberation.${{ steps.version.outputs.number }}.zip
|
||||||
|
asset_name: dcs_liberation.${{ steps.version.outputs.number }}.zip
|
||||||
|
asset_content_type: application/zip
|
||||||
|
|
||||||
4
.gitmodules
vendored
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
[submodule "pydcs"]
|
||||||
|
path = pydcs
|
||||||
|
url = https://github.com/pydcs/dcs
|
||||||
|
branch = master
|
||||||
15
README.md
@@ -1,7 +1,10 @@
|
|||||||

|

|
||||||
|
|
||||||
|
[](https://www.paypal.com/paypalme/KhopaDCSL)
|
||||||
|
[](https://patreon.com/khopa)
|
||||||
|
|
||||||
[](https://github.com/Khopa/dcs_liberation/releases)
|
[](https://github.com/Khopa/dcs_liberation/releases)
|
||||||
[](https://www.paypal.com/paypalme/KhopaDCSL)
|
|
||||||
[](https://discord.gg/bKrtrkJ)
|
[](https://discord.gg/bKrtrkJ)
|
||||||
|
|
||||||
[](https://github.com/Khopa/dcs_liberation)
|
[](https://github.com/Khopa/dcs_liberation)
|
||||||
@@ -20,13 +23,7 @@ Latest release is available here : https://github.com/Khopa/dcs_liberation/relea
|
|||||||
|
|
||||||
## Resources
|
## Resources
|
||||||
|
|
||||||
* [Getting Started](https://github.com/Khopa/dcs_liberation/wiki/Getting-started)
|
Tutorials, contributors and developer's guides are available in the project's [Wiki](https://github.com/Khopa/dcs_liberation/wiki/)
|
||||||
|
|
||||||
* [Tutorials](https://github.com/Khopa/dcs_liberation/wiki/Tutorial-01-:-UI)
|
|
||||||
|
|
||||||
* [Developer/Contributor Guide]()(TODO)
|
|
||||||
|
|
||||||
* [Hosting DCS Liberation generated missions on a dedicated server]()(TODO)
|
|
||||||
|
|
||||||
## Special Thanks
|
## Special Thanks
|
||||||
|
|
||||||
@@ -36,4 +33,4 @@ Then, DCS Liberation uses [pydcs](http://github.com/pydcs/dcs) for mission gener
|
|||||||
It also uses the popular [Mist](https://github.com/mrSkortch/MissionScriptingTools) lua framework for mission scripting.
|
It also uses the popular [Mist](https://github.com/mrSkortch/MissionScriptingTools) lua framework for mission scripting.
|
||||||
And for the JTAC feature, DCS Liberation embed Ciribob's JTAC Autolase [script](https://github.com/ciribob/DCS-JTACAutoLaze).
|
And for the JTAC feature, DCS Liberation embed Ciribob's JTAC Autolase [script](https://github.com/ciribob/DCS-JTACAutoLaze).
|
||||||
|
|
||||||
Please also show some support to these projects !
|
Please also show some support to these projects !
|
||||||
|
|||||||
46
changelog.md
@@ -1,3 +1,47 @@
|
|||||||
|
# 2.1.1
|
||||||
|
|
||||||
|
## Features/Improvements :
|
||||||
|
* **[Other]** Added an installer option (thanks to contributor parithon)
|
||||||
|
* **[Cheat Menu]** Added possibility to replace destroyed SAM and base defenses units for the player (Click on a SAM site to fix it)
|
||||||
|
* **[Cheat Menu]** Added recon images for buildings on strike targets, click on a Strike target to get detailled informations
|
||||||
|
* **[Units/Factions]** Added F-16C to USA 1990
|
||||||
|
* **[Units/Factions]** Added MQ-9 Reaper as CAS unit for USA 2005
|
||||||
|
* **[Units/Factions]** Added Mig-21, Mig-23, SA-342L to Syria 2011
|
||||||
|
* **[Cheat Menu]** Added buttons to remove money
|
||||||
|
|
||||||
|
## Fixed issues :
|
||||||
|
* **[UI/UX]** Spelling issues (Thanks to Github contributor steveveepee)
|
||||||
|
* **[Campaign Generator]** LHA was placed on land in Syrian Civil War campaign
|
||||||
|
* **[Campaign Generator]** Fixed inverted configuration for Syria full map
|
||||||
|
* **[Campaign Generator]** Syria "Inherent Resolve" campaign, added Incirlik Air Base
|
||||||
|
* **[Mission Generator]** AH-1W was not used by AI to generate CAS mission by default
|
||||||
|
* **[Mission Generator]** Fixed F-16C targeting pod not being added to payload
|
||||||
|
* **[Mission Generator]** AH-64A and AH-64D payloads fix.
|
||||||
|
|
||||||
|
# 2.1.0
|
||||||
|
|
||||||
|
## Features/Improvements :
|
||||||
|
|
||||||
|
* **[Campaign Generator]** Added Syria map
|
||||||
|
* **[Campaign Generator]** Added 5 campaigns for the Syria map
|
||||||
|
* **[Campaign Generator]** Added 2 small scale campaign for Persian Gulf map
|
||||||
|
* **[Units/Factions]** Added factions for Syria map : Syria 2011, Arab Armies 1982, 1973, 1968, 1948, Israel 1982, 1973, 1948
|
||||||
|
* **[Base Menu]** Budget is visible in recruitment menu. (Thanks to Github contributor root0fall)
|
||||||
|
* **[Misc]** Added error message in mission when the state file can not be written
|
||||||
|
* **[Units/Factions]** China, Pakistan, UAE will now use the new WingLoong drone as JTAC instead of the MQ-9 Reaper
|
||||||
|
* **[Units/Factions]** Minor changes to Syria 2011 and Turkey 2005 factions
|
||||||
|
* **[UI]** Version number is shown in about dialog
|
||||||
|
|
||||||
|
## Fixed issues :
|
||||||
|
|
||||||
|
* **[Mission Generator]** Caucasus terrain improvement on exclusions zone (added forests between Vaziani and Beslan to exclusion zones)
|
||||||
|
* **[Mission Generator]** The first unit of every base defenses group could not be controlled with Combined Arms.
|
||||||
|
* **[Mission Generator]** Reduced generated helicopter altitude for CAS missions
|
||||||
|
* **[Mission Generator]** F-16C default CAS payload was asymmetric, fixed.
|
||||||
|
* **[Mission Generator]** AH-1W couldn't be bought, and added default payloads.
|
||||||
|
* **[UI/UX]** Fixed Mi-28N missing thumbnail
|
||||||
|
* **[UI/UX]** Fixed list of flights not refreshing when changing the mission departure (T+).
|
||||||
|
|
||||||
# 2.0.11
|
# 2.0.11
|
||||||
|
|
||||||
## Features/Improvements :
|
## Features/Improvements :
|
||||||
@@ -42,7 +86,7 @@
|
|||||||
* **[Mission Generator]** The briefing will now contain the carrier ATC frequency
|
* **[Mission Generator]** The briefing will now contain the carrier ATC frequency
|
||||||
* **[Mission Generator]** The briefing contains a small situation update.
|
* **[Mission Generator]** The briefing contains a small situation update.
|
||||||
* **[Mission Generator]** Previously destroyed units are visible in the mission. (And added a performance settings to disable this behaviour)
|
* **[Mission Generator]** Previously destroyed units are visible in the mission. (And added a performance settings to disable this behaviour)
|
||||||
* **[Mission Generator]** Basic JTAC on Frontlines
|
* **[Mission Generator]*c* Basic JTAC on Frontlines
|
||||||
* **[Campaign Generator]** Added Tarawa in caucasus campaigns
|
* **[Campaign Generator]** Added Tarawa in caucasus campaigns
|
||||||
* **[Campaign Generator]** Tuned the various existing campaign parameters
|
* **[Campaign Generator]** Tuned the various existing campaign parameters
|
||||||
* **[Campaign Generator]** Added small campaign : "Russia" on Caucasus Theater
|
* **[Campaign Generator]** Added small campaign : "Russia" on Caucasus Theater
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
import inspect
|
import inspect
|
||||||
import dcs
|
from pydcs import dcs
|
||||||
|
|
||||||
DEFAULT_AVAILABLE_BUILDINGS = ['fuel', 'ammo', 'comms', 'oil', 'ware', 'farp', 'fob', 'power', 'factory', 'derrick', 'aa']
|
DEFAULT_AVAILABLE_BUILDINGS = ['fuel', 'ammo', 'comms', 'oil', 'ware', 'farp', 'fob', 'power', 'factory', 'derrick', 'aa']
|
||||||
|
|
||||||
WW2_GERMANY_BUILDINGS = ['fuel', 'factory', 'ww2bunker', 'ww2bunker', 'ww2bunker', 'allycamp', 'allycamp', 'aa']
|
WW2_GERMANY_BUILDINGS = ['fuel', 'factory', 'ww2bunker', 'ww2bunker', 'ww2bunker', 'allycamp', 'allycamp', 'aa']
|
||||||
WW2_ALLIES_BUILDINGS = ['fuel', 'factory', 'allycamp', 'allycamp', 'allycamp', 'allycamp', 'allycamp', 'aa']
|
WW2_ALLIES_BUILDINGS = ['fuel', 'factory', 'allycamp', 'allycamp', 'allycamp', 'allycamp', 'allycamp', 'aa']
|
||||||
|
|
||||||
FORTIFICATION_BUILDINGS = ['Siegfried Line', 'Concertina Wire', 'Czech hedgehogs 1', 'Czech hedgehogs 2',
|
FORTIFICATION_BUILDINGS = ['Siegfried Line', 'Concertina wire', 'Concertina Wire', 'Czech hedgehogs 1', 'Czech hedgehogs 2',
|
||||||
'Dragonteeth 1', 'Dragonteeth 2', 'Dragonteeth 3', 'Dragonteeth 4', 'Dragonteeth 5',
|
'Dragonteeth 1', 'Dragonteeth 2', 'Dragonteeth 3', 'Dragonteeth 4', 'Dragonteeth 5',
|
||||||
'Haystack 1', 'Haystack 2', 'Haystack 3', 'Haystack 4', 'Hemmkurvenvenhindernis',
|
'Haystack 1', 'Haystack 2', 'Haystack 3', 'Haystack 4', 'Hemmkurvenvenhindernis',
|
||||||
'Log posts 1', 'Log posts 2', 'Log posts 3', 'Log ramps 1', 'Log ramps 2', 'Log ramps 3',
|
'Log posts 1', 'Log posts 2', 'Log posts 3', 'Log ramps 1', 'Log ramps 2', 'Log ramps 3',
|
||||||
|
|||||||
166
game/db.py
@@ -27,6 +27,8 @@ from game.factions.germany_1990 import Germany_1990
|
|||||||
from game.factions.insurgent import Insurgent
|
from game.factions.insurgent import Insurgent
|
||||||
from game.factions.insurgent_modded import Insurgent_modded
|
from game.factions.insurgent_modded import Insurgent_modded
|
||||||
from game.factions.iran_2015 import Iran_2015
|
from game.factions.iran_2015 import Iran_2015
|
||||||
|
from game.factions.israel_1948 import Israel_1948
|
||||||
|
from game.factions.israel_1973 import Israel_1973, Israel_1973_NO_WW2_UNITS, Israel_1982
|
||||||
from game.factions.israel_2000 import Israel_2000
|
from game.factions.israel_2000 import Israel_2000
|
||||||
from game.factions.italy_1990 import Italy_1990
|
from game.factions.italy_1990 import Italy_1990
|
||||||
from game.factions.italy_1990_mb339 import Italy_1990_MB339
|
from game.factions.italy_1990_mb339 import Italy_1990_MB339
|
||||||
@@ -45,6 +47,7 @@ from game.factions.russia_1990 import Russia_1990
|
|||||||
from game.factions.russia_2010 import Russia_2010
|
from game.factions.russia_2010 import Russia_2010
|
||||||
from game.factions.spain_1990 import Spain_1990
|
from game.factions.spain_1990 import Spain_1990
|
||||||
from game.factions.sweden_1990 import Sweden_1990
|
from game.factions.sweden_1990 import Sweden_1990
|
||||||
|
from game.factions.syria import Syria_2011, Syria_1967, Syria_1967_WW2_Weapons, Syria_1973, Arab_Armies_1948, Syria_1982
|
||||||
from game.factions.turkey_2005 import Turkey_2005
|
from game.factions.turkey_2005 import Turkey_2005
|
||||||
from game.factions.uae_2005 import UAE_2005
|
from game.factions.uae_2005 import UAE_2005
|
||||||
from game.factions.uk_1944 import UK_1944
|
from game.factions.uk_1944 import UK_1944
|
||||||
@@ -140,6 +143,7 @@ PRICES = {
|
|||||||
MiG_29A: 18,
|
MiG_29A: 18,
|
||||||
MiG_29S: 20,
|
MiG_29S: 20,
|
||||||
MiG_29G: 18,
|
MiG_29G: 18,
|
||||||
|
MiG_25PD: 20,
|
||||||
MiG_31: 30,
|
MiG_31: 30,
|
||||||
J_11A: 26,
|
J_11A: 26,
|
||||||
JF_17: 20,
|
JF_17: 20,
|
||||||
@@ -171,6 +175,7 @@ PRICES = {
|
|||||||
F_15C: 22,
|
F_15C: 22,
|
||||||
F_15E: 24,
|
F_15E: 24,
|
||||||
F_16C_50: 20,
|
F_16C_50: 20,
|
||||||
|
F_16A: 14,
|
||||||
F_14B: 24,
|
F_14B: 24,
|
||||||
Tornado_IDS: 20,
|
Tornado_IDS: 20,
|
||||||
Tornado_GR4: 20,
|
Tornado_GR4: 20,
|
||||||
@@ -208,18 +213,18 @@ PRICES = {
|
|||||||
B_1B: 50,
|
B_1B: 50,
|
||||||
|
|
||||||
# special
|
# special
|
||||||
IL_76MD: 13,
|
IL_76MD: 30,
|
||||||
An_26B: 13,
|
An_26B: 25,
|
||||||
An_30M: 13,
|
An_30M: 25,
|
||||||
Yak_40: 13,
|
Yak_40: 25,
|
||||||
S_3B_Tanker: 13,
|
S_3B_Tanker: 20,
|
||||||
IL_78M: 13,
|
IL_78M: 25,
|
||||||
KC_135: 13,
|
KC_135: 25,
|
||||||
KC130: 13,
|
KC130: 25,
|
||||||
|
|
||||||
A_50: 8,
|
A_50: 50,
|
||||||
E_3A: 8,
|
E_3A: 50,
|
||||||
C_130: 8,
|
C_130: 25,
|
||||||
|
|
||||||
# WW2
|
# WW2
|
||||||
P_51D_30_NA: 18,
|
P_51D_30_NA: 18,
|
||||||
@@ -227,6 +232,11 @@ PRICES = {
|
|||||||
P_47D_30: 18,
|
P_47D_30: 18,
|
||||||
B_17G: 30,
|
B_17G: 30,
|
||||||
|
|
||||||
|
# Drones
|
||||||
|
MQ_9_Reaper: 12,
|
||||||
|
RQ_1A_Predator: 6,
|
||||||
|
WingLoong_I: 6,
|
||||||
|
|
||||||
# Modded
|
# Modded
|
||||||
Rafale_M: 26,
|
Rafale_M: 26,
|
||||||
Rafale_A_S: 26,
|
Rafale_A_S: 26,
|
||||||
@@ -285,23 +295,6 @@ PRICES = {
|
|||||||
|
|
||||||
Unarmed.Transport_M818: 3,
|
Unarmed.Transport_M818: 3,
|
||||||
|
|
||||||
AirDefence.AAA_Vulcan_M163: 5,
|
|
||||||
AirDefence.SAM_Linebacker_M6: 10,
|
|
||||||
|
|
||||||
AirDefence.AAA_ZU_23_Closed: 2,
|
|
||||||
AirDefence.SPAAA_ZSU_23_4_Shilka: 4,
|
|
||||||
AirDefence.SAM_SA_9_Strela_1_9P31: 8,
|
|
||||||
AirDefence.SAM_SA_19_Tunguska_2S6: 15,
|
|
||||||
AirDefence.SAM_SA_6_Kub_LN_2P25: 22,
|
|
||||||
AirDefence.SAM_SA_8_Osa_9A33: 12,
|
|
||||||
AirDefence.SAM_SA_3_S_125_LN_5P73: 20,
|
|
||||||
AirDefence.SAM_SA_2_LN_SM_90: 15,
|
|
||||||
AirDefence.SAM_SA_11_Buk_LN_9A310M1: 25,
|
|
||||||
AirDefence.SAM_Hawk_PCP: 20,
|
|
||||||
AirDefence.SAM_Patriot_LN_M901: 60,
|
|
||||||
AirDefence.SAM_SA_10_S_300PS_LN_5P85C: 60,
|
|
||||||
AirDefence.SAM_Chaparral_M48: 10,
|
|
||||||
|
|
||||||
# WW2
|
# WW2
|
||||||
Armor.MT_Pz_Kpfw_V_Panther_Ausf_G:24,
|
Armor.MT_Pz_Kpfw_V_Panther_Ausf_G:24,
|
||||||
Armor.MT_Pz_Kpfw_IV_Ausf_H:16,
|
Armor.MT_Pz_Kpfw_IV_Ausf_H:16,
|
||||||
@@ -322,9 +315,6 @@ PRICES = {
|
|||||||
Armor.LAC_M8_Greyhound: 8,
|
Armor.LAC_M8_Greyhound: 8,
|
||||||
Armor.TD_M10_GMC: 14,
|
Armor.TD_M10_GMC: 14,
|
||||||
Armor.StuG_III_Ausf__G: 12,
|
Armor.StuG_III_Ausf__G: 12,
|
||||||
AirDefence.AAA_Bofors_40mm: 8,
|
|
||||||
AirDefence.AAA_8_8cm_Flak_36: 8,
|
|
||||||
AirDefence.AAA_8_8cm_Flak_18: 12,
|
|
||||||
Artillery.M12_GMC: 10,
|
Artillery.M12_GMC: 10,
|
||||||
Artillery.Sturmpanzer_IV_Brummbär: 10,
|
Artillery.Sturmpanzer_IV_Brummbär: 10,
|
||||||
|
|
||||||
@@ -338,6 +328,79 @@ PRICES = {
|
|||||||
Dry_cargo_ship_Ivanov: 10,
|
Dry_cargo_ship_Ivanov: 10,
|
||||||
Tanker_Elnya_160: 10,
|
Tanker_Elnya_160: 10,
|
||||||
|
|
||||||
|
# Air Defence units
|
||||||
|
AirDefence.SAM_SA_19_Tunguska_2S6: 30,
|
||||||
|
AirDefence.SAM_SA_6_Kub_LN_2P25: 20,
|
||||||
|
AirDefence.SAM_SA_3_S_125_LN_5P73: 6,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_LN_5P85C: 22,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_LN_5P85D: 22,
|
||||||
|
AirDefence.SAM_SA_11_Buk_LN_9A310M1: 30,
|
||||||
|
AirDefence.SAM_SA_8_Osa_9A33: 28,
|
||||||
|
AirDefence.SAM_SA_15_Tor_9A331: 40,
|
||||||
|
AirDefence.SAM_SA_13_Strela_10M3_9A35M3: 24,
|
||||||
|
AirDefence.SAM_SA_9_Strela_1_9P31: 16,
|
||||||
|
AirDefence.SAM_SA_11_Buk_CC_9S470M1: 25,
|
||||||
|
AirDefence.SAM_SA_8_Osa_LD_9T217: 22,
|
||||||
|
AirDefence.SAM_Patriot_AMG_AN_MRC_137: 35,
|
||||||
|
AirDefence.SAM_Patriot_ECS_AN_MSQ_104: 30,
|
||||||
|
AirDefence.SPAAA_Gepard: 24,
|
||||||
|
AirDefence.SAM_Hawk_PCP: 14,
|
||||||
|
AirDefence.AAA_Vulcan_M163: 12,
|
||||||
|
AirDefence.SAM_Hawk_LN_M192: 8,
|
||||||
|
AirDefence.SAM_Chaparral_M48: 16,
|
||||||
|
AirDefence.SAM_Linebacker_M6: 18,
|
||||||
|
AirDefence.SAM_Patriot_LN_M901: 15,
|
||||||
|
AirDefence.SAM_Avenger_M1097: 20,
|
||||||
|
AirDefence.SAM_Patriot_EPP_III: 15,
|
||||||
|
AirDefence.SAM_Patriot_ICC: 18,
|
||||||
|
AirDefence.SAM_Roland_ADS: 12,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_CP_54K6: 18,
|
||||||
|
AirDefence.Stinger_MANPADS: 6,
|
||||||
|
AirDefence.SAM_Stinger_comm_dsr: 4,
|
||||||
|
AirDefence.SAM_Stinger_comm: 4,
|
||||||
|
AirDefence.SPAAA_ZSU_23_4_Shilka: 12,
|
||||||
|
AirDefence.AAA_ZU_23_Closed: 6,
|
||||||
|
AirDefence.AAA_ZU_23_Emplacement: 6,
|
||||||
|
AirDefence.AAA_ZU_23_on_Ural_375: 8,
|
||||||
|
AirDefence.AAA_ZU_23_Insurgent_Closed: 6,
|
||||||
|
AirDefence.AAA_ZU_23_Insurgent_on_Ural_375: 8,
|
||||||
|
AirDefence.AAA_ZU_23_Insurgent: 6,
|
||||||
|
AirDefence.SAM_SA_18_Igla_MANPADS: 10,
|
||||||
|
AirDefence.SAM_SA_18_Igla_comm: 8,
|
||||||
|
AirDefence.SAM_SA_18_Igla_S_MANPADS: 12,
|
||||||
|
AirDefence.SAM_SA_18_Igla_S_comm: 8,
|
||||||
|
AirDefence.EWR_1L13: 30,
|
||||||
|
AirDefence.SAM_SA_6_Kub_STR_9S91: 22,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_TR_30N6: 24,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_SR_5N66M: 30,
|
||||||
|
AirDefence.EWR_55G6: 30,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_SR_64H6E: 30,
|
||||||
|
AirDefence.SAM_SA_11_Buk_SR_9S18M1: 28,
|
||||||
|
AirDefence.CP_9S80M1_Sborka: 10,
|
||||||
|
AirDefence.SAM_Hawk_TR_AN_MPQ_46: 14,
|
||||||
|
AirDefence.SAM_Hawk_SR_AN_MPQ_50: 18,
|
||||||
|
AirDefence.SAM_Patriot_STR_AN_MPQ_53: 22,
|
||||||
|
AirDefence.SAM_Hawk_CWAR_AN_MPQ_55: 20,
|
||||||
|
AirDefence.SAM_SR_P_19: 14,
|
||||||
|
AirDefence.SAM_Roland_EWR: 16,
|
||||||
|
AirDefence.SAM_SA_3_S_125_TR_SNR: 14,
|
||||||
|
AirDefence.SAM_SA_2_LN_SM_90: 8,
|
||||||
|
AirDefence.SAM_SA_2_TR_SNR_75_Fan_Song: 12,
|
||||||
|
AirDefence.Rapier_FSA_Launcher: 6,
|
||||||
|
AirDefence.Rapier_FSA_Optical_Tracker: 12,
|
||||||
|
AirDefence.Rapier_FSA_Blindfire_Tracker: 16,
|
||||||
|
AirDefence.HQ_7_Self_Propelled_LN: 20,
|
||||||
|
AirDefence.HQ_7_Self_Propelled_STR: 24,
|
||||||
|
AirDefence.AAA_8_8cm_Flak_18: 6,
|
||||||
|
AirDefence.AAA_Flak_38: 6,
|
||||||
|
AirDefence.AAA_8_8cm_Flak_36: 8,
|
||||||
|
AirDefence.AAA_8_8cm_Flak_37: 10,
|
||||||
|
AirDefence.AAA_Flak_Vierling_38:6,
|
||||||
|
AirDefence.AAA_Kdo_G_40: 8,
|
||||||
|
AirDefence.Flak_Searchlight_37: 4,
|
||||||
|
AirDefence.Maschinensatz_33: 10,
|
||||||
|
AirDefence.AAA_8_8cm_Flak_41: 12,
|
||||||
|
AirDefence.AAA_Bofors_40mm: 8,
|
||||||
|
|
||||||
# FRENCH PACK MOD
|
# FRENCH PACK MOD
|
||||||
frenchpack.AMX_10RCR: 10,
|
frenchpack.AMX_10RCR: 10,
|
||||||
@@ -390,17 +453,19 @@ Following tasks are present:
|
|||||||
UNIT_BY_TASK = {
|
UNIT_BY_TASK = {
|
||||||
CAP: [
|
CAP: [
|
||||||
F_5E_3,
|
F_5E_3,
|
||||||
MiG_23MLD,
|
|
||||||
Su_27,
|
Su_27,
|
||||||
Su_33,
|
Su_33,
|
||||||
MiG_19P,
|
MiG_19P,
|
||||||
MiG_21Bis,
|
MiG_21Bis,
|
||||||
|
MiG_23MLD,
|
||||||
|
MiG_25PD,
|
||||||
MiG_29A,
|
MiG_29A,
|
||||||
MiG_29S,
|
MiG_29S,
|
||||||
MiG_31,
|
MiG_31,
|
||||||
FA_18C_hornet,
|
FA_18C_hornet,
|
||||||
F_15C,
|
F_15C,
|
||||||
F_14B,
|
F_14B,
|
||||||
|
F_16A,
|
||||||
F_16C_50,
|
F_16C_50,
|
||||||
M_2000C,
|
M_2000C,
|
||||||
Mirage_2000_5,
|
Mirage_2000_5,
|
||||||
@@ -457,7 +522,11 @@ UNIT_BY_TASK = {
|
|||||||
Ju_88A4,
|
Ju_88A4,
|
||||||
B_17G,
|
B_17G,
|
||||||
MB_339PAN,
|
MB_339PAN,
|
||||||
Rafale_A_S
|
Rafale_A_S,
|
||||||
|
WingLoong_I,
|
||||||
|
MQ_9_Reaper,
|
||||||
|
RQ_1A_Predator,
|
||||||
|
AH_1W
|
||||||
],
|
],
|
||||||
Transport: [
|
Transport: [
|
||||||
IL_76MD,
|
IL_76MD,
|
||||||
@@ -767,6 +836,16 @@ FACTIONS = {
|
|||||||
"Italy 1990 (With MB339)": Italy_1990_MB339,
|
"Italy 1990 (With MB339)": Italy_1990_MB339,
|
||||||
|
|
||||||
"Israel 2000": Israel_2000,
|
"Israel 2000": Israel_2000,
|
||||||
|
"Israel 1982": Israel_1982,
|
||||||
|
"Israel 1973 (WW2 Pack)": Israel_1973,
|
||||||
|
"Israel 1973": Israel_1973_NO_WW2_UNITS,
|
||||||
|
"Israel 1948": Israel_1948,
|
||||||
|
|
||||||
|
"Arab Armies 1982": Syria_1982,
|
||||||
|
"Arab Armies 1973": Syria_1973,
|
||||||
|
"Arab Armies 1967 (WW2 Pack)": Syria_1967_WW2_Weapons,
|
||||||
|
"Arab Armies 1967": Syria_1967,
|
||||||
|
"Arab League 1948": Arab_Armies_1948,
|
||||||
|
|
||||||
"China 2010": China_2010,
|
"China 2010": China_2010,
|
||||||
|
|
||||||
@@ -788,6 +867,9 @@ FACTIONS = {
|
|||||||
|
|
||||||
"Libya 2011": Libya_2011,
|
"Libya 2011": Libya_2011,
|
||||||
|
|
||||||
|
"Syria 2011": Syria_2011,
|
||||||
|
|
||||||
|
|
||||||
"Pakistan 2015": Pakistan_2015,
|
"Pakistan 2015": Pakistan_2015,
|
||||||
|
|
||||||
"Iran 2015": Iran_2015,
|
"Iran 2015": Iran_2015,
|
||||||
@@ -925,10 +1007,13 @@ PLANE_PAYLOAD_OVERRIDES = {
|
|||||||
Rafale_M: COMMON_OVERRIDE,
|
Rafale_M: COMMON_OVERRIDE,
|
||||||
Rafale_A_S: COMMON_OVERRIDE,
|
Rafale_A_S: COMMON_OVERRIDE,
|
||||||
OH_58D: COMMON_OVERRIDE,
|
OH_58D: COMMON_OVERRIDE,
|
||||||
|
F_16A: COMMON_OVERRIDE,
|
||||||
AH_64D:{
|
MQ_9_Reaper: COMMON_OVERRIDE,
|
||||||
CAS: "AGM-114K*16"
|
RQ_1A_Predator: COMMON_OVERRIDE,
|
||||||
},
|
WingLoong_I: COMMON_OVERRIDE,
|
||||||
|
AH_1W: COMMON_OVERRIDE,
|
||||||
|
AH_64D: COMMON_OVERRIDE,
|
||||||
|
AH_64A: COMMON_OVERRIDE,
|
||||||
|
|
||||||
Su_25TM: {
|
Su_25TM: {
|
||||||
SEAD: "Kh-31P*2_Kh-25ML*4_R-73*2_L-081_MPS410",
|
SEAD: "Kh-31P*2_Kh-25ML*4_R-73*2_L-081_MPS410",
|
||||||
@@ -982,7 +1067,11 @@ TIME_PERIODS = {
|
|||||||
"Modern - Summer [2010]": datetime(2010, 6, 1),
|
"Modern - Summer [2010]": datetime(2010, 6, 1),
|
||||||
"Modern - Fall [2010]": datetime(2010, 10, 1),
|
"Modern - Fall [2010]": datetime(2010, 10, 1),
|
||||||
"Georgian War [2008]": datetime(2008, 8, 7),
|
"Georgian War [2008]": datetime(2008, 8, 7),
|
||||||
"Syrian War [2011]": datetime(2011, 8, 7),
|
"Syrian War [2011]": datetime(2011, 3, 15),
|
||||||
|
"6 days war [1967]": datetime(1967, 6, 5),
|
||||||
|
"Yom Kippour War [1973]": datetime(1973, 10, 6),
|
||||||
|
"Lebanon War [1982]": datetime(1982, 6, 6),
|
||||||
|
"Arab-Israeli War [1948]": datetime(1948, 5, 15),
|
||||||
}
|
}
|
||||||
|
|
||||||
REWARDS = {
|
REWARDS = {
|
||||||
@@ -1030,6 +1119,7 @@ LHA_CAPABLE = [
|
|||||||
SA342Mistral
|
SA342Mistral
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
"""
|
"""
|
||||||
---------- END OF CONFIGURATION SECTION
|
---------- END OF CONFIGURATION SECTION
|
||||||
"""
|
"""
|
||||||
|
|||||||
@@ -178,9 +178,12 @@ class Event:
|
|||||||
for i, ground_object in enumerate(cp.ground_objects):
|
for i, ground_object in enumerate(cp.ground_objects):
|
||||||
if ground_object.dcs_identifier in ["AA", "CARRIER", "LHA"]:
|
if ground_object.dcs_identifier in ["AA", "CARRIER", "LHA"]:
|
||||||
for g in ground_object.groups:
|
for g in ground_object.groups:
|
||||||
|
if not hasattr(g, "units_losts"):
|
||||||
|
g.units_losts = []
|
||||||
for u in g.units:
|
for u in g.units:
|
||||||
if u.name == destroyed_ground_unit_name:
|
if u.name == destroyed_ground_unit_name:
|
||||||
g.units.remove(u)
|
g.units.remove(u)
|
||||||
|
g.units_losts.append(u)
|
||||||
destroyed_units = destroyed_units + 1
|
destroyed_units = destroyed_units + 1
|
||||||
info.text = u.type
|
info.text = u.type
|
||||||
ucount = sum([len(g.units) for g in ground_object.groups])
|
ucount = sum([len(g.units) for g in ground_object.groups])
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ China_2010 = {
|
|||||||
A_50,
|
A_50,
|
||||||
|
|
||||||
Mi_8MT,
|
Mi_8MT,
|
||||||
|
Mi_28N,
|
||||||
|
|
||||||
AirDefence.SAM_SA_10_S_300PS_LN_5P85C, # Standing as HQ-9+
|
AirDefence.SAM_SA_10_S_300PS_LN_5P85C, # Standing as HQ-9+
|
||||||
AirDefence.SAM_SA_6_Kub_LN_2P25,
|
AirDefence.SAM_SA_6_Kub_LN_2P25,
|
||||||
@@ -73,5 +74,7 @@ China_2010 = {
|
|||||||
"002 Shandong",
|
"002 Shandong",
|
||||||
], "boat":[
|
], "boat":[
|
||||||
"Type54GroupGenerator"
|
"Type54GroupGenerator"
|
||||||
], "has_jtac": True
|
],
|
||||||
|
"has_jtac": True,
|
||||||
|
"jtac_unit": WingLoong_I
|
||||||
}
|
}
|
||||||
@@ -32,7 +32,9 @@ Germany_1944 = {
|
|||||||
|
|
||||||
Infantry.Infantry_Mauser_98,
|
Infantry.Infantry_Mauser_98,
|
||||||
AirDefence.AAA_8_8cm_Flak_36,
|
AirDefence.AAA_8_8cm_Flak_36,
|
||||||
],
|
],"requirements":{
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
},
|
||||||
"shorad": [
|
"shorad": [
|
||||||
AirDefence.AAA_8_8cm_Flak_36,
|
AirDefence.AAA_8_8cm_Flak_36,
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -25,7 +25,9 @@ Germany_1944_Easy = {
|
|||||||
|
|
||||||
Infantry.Infantry_Mauser_98,
|
Infantry.Infantry_Mauser_98,
|
||||||
AirDefence.AAA_8_8cm_Flak_36,
|
AirDefence.AAA_8_8cm_Flak_36,
|
||||||
],
|
],"requirements":{
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
},
|
||||||
"shorad":[
|
"shorad":[
|
||||||
AirDefence.AAA_8_8cm_Flak_36,
|
AirDefence.AAA_8_8cm_Flak_36,
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -12,11 +12,13 @@ Insurgent = {
|
|||||||
AirDefence.AAA_ZU_23_Insurgent_on_Ural_375,
|
AirDefence.AAA_ZU_23_Insurgent_on_Ural_375,
|
||||||
|
|
||||||
Armor.APC_Cobra,
|
Armor.APC_Cobra,
|
||||||
|
Armor.APC_MTLB,
|
||||||
|
Armor.ARV_BRDM_2,
|
||||||
|
|
||||||
Unarmed.Transport_Ural_375,
|
Unarmed.Transport_Ural_375,
|
||||||
Unarmed.Transport_UAZ_469,
|
Unarmed.Transport_UAZ_469,
|
||||||
Infantry.Soldier_AK,
|
|
||||||
Infantry.Infantry_Soldier_Insurgents,
|
Infantry.Infantry_Soldier_Insurgents,
|
||||||
|
Infantry.Soldier_RPG,
|
||||||
|
|
||||||
Bulk_cargo_ship_Yakushev,
|
Bulk_cargo_ship_Yakushev,
|
||||||
Dry_cargo_ship_Ivanov,
|
Dry_cargo_ship_Ivanov,
|
||||||
|
|||||||
33
game/factions/israel_1948.py
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
from dcs.planes import *
|
||||||
|
from dcs.ships import *
|
||||||
|
from dcs.vehicles import *
|
||||||
|
|
||||||
|
Israel_1948 = {
|
||||||
|
"country": "Israel",
|
||||||
|
"side": "blue",
|
||||||
|
"units":[
|
||||||
|
SpitfireLFMkIXCW,
|
||||||
|
SpitfireLFMkIX,
|
||||||
|
P_51D,
|
||||||
|
P_51D_30_NA,
|
||||||
|
Bf_109K_4, # Standing as Avia S-199
|
||||||
|
B_17G,
|
||||||
|
|
||||||
|
Armor.MT_M4A4_Sherman_Firefly,
|
||||||
|
Armor.APC_M2A1,
|
||||||
|
Armor.MT_M4_Sherman,
|
||||||
|
Armor.LAC_M8_Greyhound,
|
||||||
|
|
||||||
|
Unarmed.Transport_M818,
|
||||||
|
Infantry.Infantry_SMLE_No_4_Mk_1,
|
||||||
|
|
||||||
|
AirDefence.AAA_Bofors_40mm,
|
||||||
|
Armed_speedboat,
|
||||||
|
],"requirements":{
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
},
|
||||||
|
"shorad": [
|
||||||
|
AirDefence.AAA_Bofors_40mm
|
||||||
|
], "boat": [
|
||||||
|
], "has_jtac": False
|
||||||
|
}
|
||||||
112
game/factions/israel_1973.py
Normal file
@@ -0,0 +1,112 @@
|
|||||||
|
from dcs.helicopters import *
|
||||||
|
from dcs.planes import *
|
||||||
|
from dcs.ships import *
|
||||||
|
from dcs.vehicles import *
|
||||||
|
|
||||||
|
from pydcs_extensions.a4ec.a4ec import A_4E_C
|
||||||
|
|
||||||
|
Israel_1973 = {
|
||||||
|
"country": "Israel",
|
||||||
|
"side": "blue",
|
||||||
|
"units":[
|
||||||
|
F_4E,
|
||||||
|
A_4E_C,
|
||||||
|
|
||||||
|
KC_135,
|
||||||
|
KC130,
|
||||||
|
C_130,
|
||||||
|
E_3A,
|
||||||
|
|
||||||
|
UH_1H,
|
||||||
|
|
||||||
|
Armor.MT_M4A4_Sherman_Firefly,
|
||||||
|
Armor.APC_M2A1,
|
||||||
|
Armor.MBT_M60A3_Patton,
|
||||||
|
Armor.APC_M113,
|
||||||
|
|
||||||
|
Unarmed.Transport_M818,
|
||||||
|
Infantry.Infantry_M4,
|
||||||
|
|
||||||
|
AirDefence.SAM_Hawk_PCP,
|
||||||
|
AirDefence.AAA_Bofors_40mm,
|
||||||
|
AirDefence.SAM_Chaparral_M48,
|
||||||
|
|
||||||
|
Armed_speedboat,
|
||||||
|
], "requirements": {
|
||||||
|
"Community A-4E": "https://heclak.github.io/community-a4e-c/",
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
}, "shorad": [
|
||||||
|
AirDefence.SAM_Chaparral_M48,
|
||||||
|
AirDefence.AAA_Bofors_40mm
|
||||||
|
], "boat": [
|
||||||
|
], "has_jtac": True
|
||||||
|
}
|
||||||
|
|
||||||
|
Israel_1973_NO_WW2_UNITS = {
|
||||||
|
"country": "Israel",
|
||||||
|
"side": "blue",
|
||||||
|
"units":[
|
||||||
|
F_4E,
|
||||||
|
A_4E_C,
|
||||||
|
|
||||||
|
KC_135,
|
||||||
|
KC130,
|
||||||
|
C_130,
|
||||||
|
E_3A,
|
||||||
|
|
||||||
|
UH_1H,
|
||||||
|
|
||||||
|
Armor.MBT_M60A3_Patton,
|
||||||
|
Armor.APC_M113,
|
||||||
|
|
||||||
|
Unarmed.Transport_M818,
|
||||||
|
Infantry.Infantry_M4,
|
||||||
|
|
||||||
|
AirDefence.SAM_Hawk_PCP,
|
||||||
|
AirDefence.SAM_Chaparral_M48,
|
||||||
|
|
||||||
|
Armed_speedboat,
|
||||||
|
], "requirements": {
|
||||||
|
"Community A-4E": "https://heclak.github.io/community-a4e-c/",
|
||||||
|
}, "shorad": [
|
||||||
|
AirDefence.SAM_Chaparral_M48,
|
||||||
|
], "boat": [
|
||||||
|
], "has_jtac": True
|
||||||
|
}
|
||||||
|
|
||||||
|
Israel_1982 = {
|
||||||
|
"country": "Israel",
|
||||||
|
"side": "blue",
|
||||||
|
"units":[
|
||||||
|
F_4E,
|
||||||
|
A_4E_C,
|
||||||
|
F_15C,
|
||||||
|
F_16A,
|
||||||
|
F_16C_50,
|
||||||
|
|
||||||
|
KC_135,
|
||||||
|
KC130,
|
||||||
|
C_130,
|
||||||
|
E_3A,
|
||||||
|
|
||||||
|
UH_1H,
|
||||||
|
AH_1W,
|
||||||
|
|
||||||
|
Armor.APC_M113,
|
||||||
|
Armor.MBT_M60A3_Patton,
|
||||||
|
Armor.MBT_Merkava_Mk__4,
|
||||||
|
|
||||||
|
Unarmed.Transport_M818,
|
||||||
|
Infantry.Infantry_M4,
|
||||||
|
|
||||||
|
AirDefence.SAM_Hawk_PCP,
|
||||||
|
AirDefence.SAM_Chaparral_M48,
|
||||||
|
|
||||||
|
Armed_speedboat,
|
||||||
|
], "requirements": {
|
||||||
|
"Community A-4E": "https://heclak.github.io/community-a4e-c/",
|
||||||
|
}, "shorad": [
|
||||||
|
AirDefence.SAM_Chaparral_M48,
|
||||||
|
], "boat": [
|
||||||
|
], "has_jtac": True
|
||||||
|
}
|
||||||
@@ -9,6 +9,7 @@ Israel_2000 = {
|
|||||||
"units":[
|
"units":[
|
||||||
F_16C_50,
|
F_16C_50,
|
||||||
F_15C,
|
F_15C,
|
||||||
|
F_15E,
|
||||||
F_4E,
|
F_4E,
|
||||||
|
|
||||||
KC_135,
|
KC_135,
|
||||||
@@ -21,6 +22,10 @@ Israel_2000 = {
|
|||||||
|
|
||||||
Armor.MBT_Merkava_Mk__4,
|
Armor.MBT_Merkava_Mk__4,
|
||||||
Armor.APC_M113,
|
Armor.APC_M113,
|
||||||
|
Armor.APC_M1043_HMMWV_Armament,
|
||||||
|
Armor.ATGM_M1045_HMMWV_TOW,
|
||||||
|
Artillery.SPH_M109_Paladin,
|
||||||
|
Artillery.MLRS_M270,
|
||||||
|
|
||||||
Unarmed.Transport_M818,
|
Unarmed.Transport_M818,
|
||||||
Infantry.Infantry_M4,
|
Infantry.Infantry_M4,
|
||||||
|
|||||||
@@ -36,5 +36,7 @@ Pakistan_2015 = {
|
|||||||
AirDefence.AAA_ZU_23_Closed
|
AirDefence.AAA_ZU_23_Closed
|
||||||
], "boat": [
|
], "boat": [
|
||||||
"Type54GroupGenerator", "OliverHazardPerryGroupGenerator"
|
"Type54GroupGenerator", "OliverHazardPerryGroupGenerator"
|
||||||
], "has_jtac": True
|
],
|
||||||
|
"has_jtac": True,
|
||||||
|
"jtac_unit": WingLoong_I
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ Russia_1990 = {
|
|||||||
|
|
||||||
Su_24M,
|
Su_24M,
|
||||||
Su_25,
|
Su_25,
|
||||||
|
Ka_50,
|
||||||
|
|
||||||
IL_76MD,
|
IL_76MD,
|
||||||
IL_78M,
|
IL_78M,
|
||||||
|
|||||||
267
game/factions/syria.py
Normal file
@@ -0,0 +1,267 @@
|
|||||||
|
from dcs.helicopters import *
|
||||||
|
from dcs.planes import *
|
||||||
|
from dcs.vehicles import *
|
||||||
|
|
||||||
|
Syria_2011 = {
|
||||||
|
"country": "Syria",
|
||||||
|
"side": "red",
|
||||||
|
"units": [
|
||||||
|
|
||||||
|
MiG_21Bis,
|
||||||
|
MiG_23MLD,
|
||||||
|
MiG_25PD,
|
||||||
|
MiG_29S,
|
||||||
|
|
||||||
|
Su_17M4,
|
||||||
|
Su_24M,
|
||||||
|
|
||||||
|
L_39ZA,
|
||||||
|
|
||||||
|
Mi_24V,
|
||||||
|
Mi_8MT,
|
||||||
|
SA342M,
|
||||||
|
SA342L,
|
||||||
|
|
||||||
|
IL_76MD,
|
||||||
|
IL_78M,
|
||||||
|
An_26B,
|
||||||
|
An_30M,
|
||||||
|
Yak_40,
|
||||||
|
A_50,
|
||||||
|
|
||||||
|
AirDefence.SAM_SA_6_Kub_LN_2P25,
|
||||||
|
AirDefence.SAM_SA_3_S_125_LN_5P73,
|
||||||
|
AirDefence.SAM_SA_2_LN_SM_90,
|
||||||
|
AirDefence.SAM_SA_8_Osa_9A33,
|
||||||
|
AirDefence.SAM_SA_11_Buk_LN_9A310M1,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_LN_5P85C,
|
||||||
|
|
||||||
|
Armor.IFV_BMP_1,
|
||||||
|
Armor.IFV_BMP_2,
|
||||||
|
Armor.APC_BTR_80,
|
||||||
|
Armor.ARV_BRDM_2,
|
||||||
|
Armor.APC_MTLB,
|
||||||
|
Armor.APC_Cobra,
|
||||||
|
Armor.MBT_T_55,
|
||||||
|
Armor.MBT_T_72B,
|
||||||
|
Armor.MBT_T_90,
|
||||||
|
Artillery.MLRS_BM_21_Grad,
|
||||||
|
Artillery.MLRS_9K57_Uragan_BM_27,
|
||||||
|
Artillery.SPH_2S1_Gvozdika,
|
||||||
|
Artillery.SPH_2S9_Nona,
|
||||||
|
|
||||||
|
Unarmed.Transport_Ural_375,
|
||||||
|
Unarmed.Transport_UAZ_469,
|
||||||
|
|
||||||
|
Infantry.Paratrooper_RPG_16,
|
||||||
|
Infantry.Soldier_AK
|
||||||
|
|
||||||
|
],
|
||||||
|
"shorad": [
|
||||||
|
AirDefence.SAM_SA_8_Osa_9A33,
|
||||||
|
AirDefence.SAM_SA_13_Strela_10M3_9A35M3,
|
||||||
|
AirDefence.SAM_SA_9_Strela_1_9P31,
|
||||||
|
AirDefence.SAM_SA_19_Tunguska_2S6,
|
||||||
|
AirDefence.AAA_ZU_23_on_Ural_375,
|
||||||
|
], "boat": [
|
||||||
|
"GrishaGroupGenerator", "MolniyaGroupGenerator"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
Syria_1973 = {
|
||||||
|
"country": "Syria",
|
||||||
|
"side": "red",
|
||||||
|
"units": [
|
||||||
|
|
||||||
|
MiG_21Bis,
|
||||||
|
MiG_19P,
|
||||||
|
MiG_15bis, # Standing as Mig-17
|
||||||
|
|
||||||
|
Su_17M4, # Standing as Su-7
|
||||||
|
Mi_8MT,
|
||||||
|
|
||||||
|
IL_76MD,
|
||||||
|
IL_78M,
|
||||||
|
An_26B,
|
||||||
|
An_30M,
|
||||||
|
Yak_40,
|
||||||
|
|
||||||
|
AirDefence.SAM_SA_6_Kub_LN_2P25,
|
||||||
|
AirDefence.SAM_SA_3_S_125_LN_5P73,
|
||||||
|
AirDefence.SAM_SA_2_LN_SM_90,
|
||||||
|
|
||||||
|
Armor.IFV_BMP_1,
|
||||||
|
Armor.APC_MTLB,
|
||||||
|
Armor.MBT_T_55,
|
||||||
|
Artillery.MLRS_BM_21_Grad,
|
||||||
|
|
||||||
|
Unarmed.Transport_Ural_375,
|
||||||
|
Unarmed.Transport_UAZ_469,
|
||||||
|
|
||||||
|
Infantry.Paratrooper_RPG_16,
|
||||||
|
Infantry.Soldier_AK
|
||||||
|
|
||||||
|
],
|
||||||
|
"shorad": [
|
||||||
|
AirDefence.AAA_ZU_23_on_Ural_375,
|
||||||
|
], "boat": [
|
||||||
|
"GrishaGroupGenerator"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Syria_1982 = {
|
||||||
|
"country": "Syria",
|
||||||
|
"side": "red",
|
||||||
|
"units": [
|
||||||
|
|
||||||
|
MiG_21Bis,
|
||||||
|
MiG_23MLD,
|
||||||
|
MiG_25PD,
|
||||||
|
MiG_19P,
|
||||||
|
|
||||||
|
Su_17M4, # Standing as Su-7
|
||||||
|
Mi_8MT,
|
||||||
|
|
||||||
|
IL_76MD,
|
||||||
|
IL_78M,
|
||||||
|
An_26B,
|
||||||
|
An_30M,
|
||||||
|
Yak_40,
|
||||||
|
|
||||||
|
AirDefence.SAM_SA_6_Kub_LN_2P25,
|
||||||
|
AirDefence.SAM_SA_3_S_125_LN_5P73,
|
||||||
|
AirDefence.SAM_SA_2_LN_SM_90,
|
||||||
|
|
||||||
|
Armor.IFV_BMP_1,
|
||||||
|
Armor.APC_MTLB,
|
||||||
|
Armor.MBT_T_55,
|
||||||
|
Armor.MBT_T_72B,
|
||||||
|
Artillery.MLRS_BM_21_Grad,
|
||||||
|
|
||||||
|
Unarmed.Transport_Ural_375,
|
||||||
|
Unarmed.Transport_UAZ_469,
|
||||||
|
|
||||||
|
Infantry.Paratrooper_RPG_16,
|
||||||
|
Infantry.Soldier_AK
|
||||||
|
|
||||||
|
],
|
||||||
|
"shorad": [
|
||||||
|
AirDefence.AAA_ZU_23_on_Ural_375,
|
||||||
|
], "boat": [
|
||||||
|
"GrishaGroupGenerator"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Syria_1967 = {
|
||||||
|
"country": "Syria",
|
||||||
|
"side": "red",
|
||||||
|
"units": [
|
||||||
|
|
||||||
|
MiG_21Bis,
|
||||||
|
MiG_19P,
|
||||||
|
MiG_15bis, # Standing as Mig-17
|
||||||
|
|
||||||
|
Su_17M4, # Standing as Su-7
|
||||||
|
Mi_8MT,
|
||||||
|
|
||||||
|
IL_76MD,
|
||||||
|
IL_78M,
|
||||||
|
An_26B,
|
||||||
|
An_30M,
|
||||||
|
Yak_40,
|
||||||
|
|
||||||
|
AirDefence.SAM_SA_2_LN_SM_90,
|
||||||
|
|
||||||
|
Armor.ARV_BRDM_2,
|
||||||
|
Armor.MBT_T_55,
|
||||||
|
Artillery.MLRS_BM_21_Grad,
|
||||||
|
|
||||||
|
Unarmed.Transport_Ural_375,
|
||||||
|
Unarmed.Transport_UAZ_469,
|
||||||
|
|
||||||
|
Infantry.Paratrooper_RPG_16,
|
||||||
|
Infantry.Soldier_AK
|
||||||
|
|
||||||
|
],
|
||||||
|
"shorad": [
|
||||||
|
AirDefence.AAA_ZU_23_on_Ural_375,
|
||||||
|
], "boat": [
|
||||||
|
"GrishaGroupGenerator"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
Syria_1967_WW2_Weapons = {
|
||||||
|
"country": "Syria",
|
||||||
|
"side": "red",
|
||||||
|
"units": [
|
||||||
|
|
||||||
|
MiG_21Bis,
|
||||||
|
MiG_19P,
|
||||||
|
MiG_15bis, # Standing as Mig-17
|
||||||
|
|
||||||
|
Su_17M4, # Standing as Su-7
|
||||||
|
Mi_8MT,
|
||||||
|
|
||||||
|
IL_76MD,
|
||||||
|
IL_78M,
|
||||||
|
An_26B,
|
||||||
|
An_30M,
|
||||||
|
Yak_40,
|
||||||
|
|
||||||
|
AirDefence.SAM_SA_2_LN_SM_90,
|
||||||
|
|
||||||
|
Armor.ARV_BRDM_2,
|
||||||
|
Armor.MBT_T_55,
|
||||||
|
Armor.MT_Pz_Kpfw_IV_Ausf_H,
|
||||||
|
Armor.StuG_III_Ausf__G,
|
||||||
|
Armor.TD_Jagdpanzer_IV,
|
||||||
|
Artillery.MLRS_BM_21_Grad,
|
||||||
|
|
||||||
|
Unarmed.Transport_Ural_375,
|
||||||
|
Unarmed.Transport_UAZ_469,
|
||||||
|
|
||||||
|
Infantry.Soldier_RPG,
|
||||||
|
Infantry.Soldier_AK
|
||||||
|
|
||||||
|
], "requirements": {
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
},
|
||||||
|
"shorad": [
|
||||||
|
AirDefence.AAA_ZU_23_on_Ural_375,
|
||||||
|
], "boat": [
|
||||||
|
"GrishaGroupGenerator"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
Arab_Armies_1948 = {
|
||||||
|
"country": "Syria",
|
||||||
|
"side": "red",
|
||||||
|
"units": [
|
||||||
|
SpitfireLFMkIX,
|
||||||
|
SpitfireLFMkIXCW,
|
||||||
|
|
||||||
|
AirDefence.SAM_SA_2_LN_SM_90,
|
||||||
|
|
||||||
|
Armor.MT_M4_Sherman,
|
||||||
|
Armor.MT_Pz_Kpfw_IV_Ausf_H,
|
||||||
|
Armor.APC_Sd_Kfz_251,
|
||||||
|
Armor.IFV_Sd_Kfz_234_2_Puma,
|
||||||
|
|
||||||
|
Unarmed.Transport_Ural_375,
|
||||||
|
Unarmed.Transport_UAZ_469,
|
||||||
|
|
||||||
|
Infantry.Infantry_SMLE_No_4_Mk_1,
|
||||||
|
|
||||||
|
AirDefence.AAA_8_8cm_Flak_36,
|
||||||
|
|
||||||
|
], "requirements": {
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
},
|
||||||
|
"shorad": [
|
||||||
|
AirDefence.AAA_8_8cm_Flak_36,
|
||||||
|
], "boat": [
|
||||||
|
"GrishaGroupGenerator"
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -16,7 +16,6 @@ Turkey_2005 = {
|
|||||||
E_3A,
|
E_3A,
|
||||||
|
|
||||||
UH_1H,
|
UH_1H,
|
||||||
OH_58D,
|
|
||||||
AH_1W,
|
AH_1W,
|
||||||
|
|
||||||
Armor.MBT_Leopard_2,
|
Armor.MBT_Leopard_2,
|
||||||
|
|||||||
@@ -32,5 +32,7 @@ UAE_2005 = {
|
|||||||
Armed_speedboat,
|
Armed_speedboat,
|
||||||
], "boat":[
|
], "boat":[
|
||||||
"OliverHazardPerryGroupGenerator"
|
"OliverHazardPerryGroupGenerator"
|
||||||
], "has_jtac": True
|
],
|
||||||
|
"has_jtac": True,
|
||||||
|
"jtac_unit": WingLoong_I
|
||||||
}
|
}
|
||||||
@@ -34,7 +34,9 @@ UK_1944 = {
|
|||||||
AirDefence.AAA_Bofors_40mm,
|
AirDefence.AAA_Bofors_40mm,
|
||||||
], "shorad":[
|
], "shorad":[
|
||||||
AirDefence.AAA_Bofors_40mm,
|
AirDefence.AAA_Bofors_40mm,
|
||||||
],
|
],"requirements":{
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
},
|
||||||
"objects": WW2_ALLIES_BUILDINGS,
|
"objects": WW2_ALLIES_BUILDINGS,
|
||||||
"doctrine": WWII_DOCTRINE,
|
"doctrine": WWII_DOCTRINE,
|
||||||
"boat": ["WW2LSTGroupGenerator"],
|
"boat": ["WW2LSTGroupGenerator"],
|
||||||
|
|||||||
@@ -32,7 +32,9 @@ USA_1944 = {
|
|||||||
AirDefence.AAA_Bofors_40mm,
|
AirDefence.AAA_Bofors_40mm,
|
||||||
], "shorad":[
|
], "shorad":[
|
||||||
AirDefence.AAA_Bofors_40mm,
|
AirDefence.AAA_Bofors_40mm,
|
||||||
],
|
],"requirements":{
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
},
|
||||||
"objects": WW2_ALLIES_BUILDINGS,
|
"objects": WW2_ALLIES_BUILDINGS,
|
||||||
"doctrine": WWII_DOCTRINE,
|
"doctrine": WWII_DOCTRINE,
|
||||||
"boat": ["WW2LSTGroupGenerator"],
|
"boat": ["WW2LSTGroupGenerator"],
|
||||||
@@ -74,7 +76,9 @@ ALLIES_1944 = {
|
|||||||
AirDefence.AAA_Bofors_40mm,
|
AirDefence.AAA_Bofors_40mm,
|
||||||
], "shorad":[
|
], "shorad":[
|
||||||
AirDefence.AAA_Bofors_40mm,
|
AirDefence.AAA_Bofors_40mm,
|
||||||
],
|
],"requirements":{
|
||||||
|
"WW2 Asset Pack": "https://www.digitalcombatsimulator.com/en/products/other/wwii_assets_pack/",
|
||||||
|
},
|
||||||
"objects": WW2_ALLIES_BUILDINGS,
|
"objects": WW2_ALLIES_BUILDINGS,
|
||||||
"doctrine": WWII_DOCTRINE,
|
"doctrine": WWII_DOCTRINE,
|
||||||
"boat": ["WW2LSTGroupGenerator"],
|
"boat": ["WW2LSTGroupGenerator"],
|
||||||
|
|||||||
@@ -11,12 +11,11 @@ USA_1990 = {
|
|||||||
F_15E,
|
F_15E,
|
||||||
F_14B,
|
F_14B,
|
||||||
FA_18C_hornet,
|
FA_18C_hornet,
|
||||||
|
F_16C_50,
|
||||||
|
|
||||||
A_10A,
|
A_10A,
|
||||||
AV8BNA,
|
AV8BNA,
|
||||||
|
|
||||||
B_1B,
|
|
||||||
|
|
||||||
KC_135,
|
KC_135,
|
||||||
KC130,
|
KC130,
|
||||||
C_130,
|
C_130,
|
||||||
@@ -24,7 +23,6 @@ USA_1990 = {
|
|||||||
|
|
||||||
UH_1H,
|
UH_1H,
|
||||||
AH_64A,
|
AH_64A,
|
||||||
OH_58D,
|
|
||||||
|
|
||||||
Armor.MBT_M1A2_Abrams,
|
Armor.MBT_M1A2_Abrams,
|
||||||
Armor.IFV_LAV_25,
|
Armor.IFV_LAV_25,
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ USA_2005 = {
|
|||||||
F_16C_50,
|
F_16C_50,
|
||||||
A_10C,
|
A_10C,
|
||||||
AV8BNA,
|
AV8BNA,
|
||||||
|
MQ_9_Reaper,
|
||||||
|
|
||||||
KC_135,
|
KC_135,
|
||||||
KC130,
|
KC130,
|
||||||
@@ -22,7 +23,6 @@ USA_2005 = {
|
|||||||
|
|
||||||
UH_1H,
|
UH_1H,
|
||||||
AH_64D,
|
AH_64D,
|
||||||
OH_58D,
|
|
||||||
|
|
||||||
Armor.MBT_M1A2_Abrams,
|
Armor.MBT_M1A2_Abrams,
|
||||||
Armor.ATGM_M1134_Stryker,
|
Armor.ATGM_M1134_Stryker,
|
||||||
|
|||||||
@@ -316,10 +316,10 @@ class AircraftConflictGenerator:
|
|||||||
detection_zone = self.m.triggers.add_triggerzone(flight.from_cp.position, radius=25000, hidden=False, name="ITZ")
|
detection_zone = self.m.triggers.add_triggerzone(flight.from_cp.position, radius=25000, hidden=False, name="ITZ")
|
||||||
if flight.from_cp.captured:
|
if flight.from_cp.captured:
|
||||||
activation_trigger.add_condition(PartOfCoalitionInZone(self.game.get_enemy_color(), detection_zone.id)) # TODO : support unit type in part of coalition
|
activation_trigger.add_condition(PartOfCoalitionInZone(self.game.get_enemy_color(), detection_zone.id)) # TODO : support unit type in part of coalition
|
||||||
activation_trigger.add_action(MessageToAll(String("WARNING : Enemy aircrafts have been detected in the vicinity of " + flight.from_cp.name + ". Interceptors are taking off."), 20))
|
activation_trigger.add_action(MessageToAll(String("WARNING : Enemy aircraft have been detected in the vicinity of " + flight.from_cp.name + ". Interceptors are taking off."), 20))
|
||||||
else:
|
else:
|
||||||
activation_trigger.add_condition(PartOfCoalitionInZone(self.game.get_player_color(), detection_zone.id))
|
activation_trigger.add_condition(PartOfCoalitionInZone(self.game.get_player_color(), detection_zone.id))
|
||||||
activation_trigger.add_action(MessageToAll(String("WARNING : We have detected that enemy aircrafts are scrambling for an interception on " + flight.from_cp.name + " airbase."), 20))
|
activation_trigger.add_action(MessageToAll(String("WARNING : We have detected that enemy aircraft are scrambling for an interception on " + flight.from_cp.name + " airbase."), 20))
|
||||||
|
|
||||||
def generate_planned_flight(self, cp, country, flight:Flight):
|
def generate_planned_flight(self, cp, country, flight:Flight):
|
||||||
try:
|
try:
|
||||||
@@ -516,6 +516,10 @@ class AircraftConflictGenerator:
|
|||||||
group.points[0].tasks.append(OptRestrictJettison(True))
|
group.points[0].tasks.append(OptRestrictJettison(True))
|
||||||
|
|
||||||
for point in flight.points:
|
for point in flight.points:
|
||||||
group.add_waypoint(Point(point.x,point.y), point.alt)
|
group.add_waypoint(Point(point.x, point.y), point.alt)
|
||||||
|
|
||||||
|
|
||||||
|
def setup_radio_preset(self, flight, group):
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -101,9 +101,14 @@ class GroundConflictGenerator:
|
|||||||
if "has_jtac" in self.game.player_faction and self.game.player_faction["has_jtac"] and self.game.settings.include_jtac_if_available:
|
if "has_jtac" in self.game.player_faction and self.game.player_faction["has_jtac"] and self.game.settings.include_jtac_if_available:
|
||||||
n = "JTAC" + str(self.conflict.from_cp.id) + str(self.conflict.to_cp.id)
|
n = "JTAC" + str(self.conflict.from_cp.id) + str(self.conflict.to_cp.id)
|
||||||
code = 1688 - len(self.game.jtacs)
|
code = 1688 - len(self.game.jtacs)
|
||||||
|
|
||||||
|
utype = MQ_9_Reaper
|
||||||
|
if "jtac_unit" in self.game.player_faction:
|
||||||
|
utype = self.game.player_faction["jtac_unit"]
|
||||||
|
|
||||||
jtac = self.mission.flight_group(country=self.mission.country(self.game.player_country),
|
jtac = self.mission.flight_group(country=self.mission.country(self.game.player_country),
|
||||||
name=n,
|
name=n,
|
||||||
aircraft_type=MQ_9_Reaper,
|
aircraft_type=utype,
|
||||||
position=position[0],
|
position=position[0],
|
||||||
airport=None,
|
airport=None,
|
||||||
altitude=5000)
|
altitude=5000)
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import logging
|
import logging
|
||||||
import typing
|
import typing
|
||||||
import pdb
|
import pdb
|
||||||
import dcs
|
from pydcs import dcs
|
||||||
|
|
||||||
from random import randint
|
from random import randint
|
||||||
from dcs import Mission
|
from dcs import Mission
|
||||||
|
|||||||
@@ -7,7 +7,8 @@ from game.data.doctrine import MODERN_DOCTRINE
|
|||||||
from game.data.radar_db import UNITS_WITH_RADAR
|
from game.data.radar_db import UNITS_WITH_RADAR
|
||||||
from game.utils import meter_to_feet, nm_to_meter
|
from game.utils import meter_to_feet, nm_to_meter
|
||||||
from gen import Conflict
|
from gen import Conflict
|
||||||
from gen.flights.ai_flight_planner_db import INTERCEPT_CAPABLE, CAP_CAPABLE, CAS_CAPABLE, SEAD_CAPABLE, STRIKE_CAPABLE
|
from gen.flights.ai_flight_planner_db import INTERCEPT_CAPABLE, CAP_CAPABLE, CAS_CAPABLE, SEAD_CAPABLE, STRIKE_CAPABLE, \
|
||||||
|
DRONES
|
||||||
from gen.flights.flight import Flight, FlightType, FlightWaypoint, FlightWaypointType
|
from gen.flights.flight import Flight, FlightType, FlightWaypoint, FlightWaypointType
|
||||||
|
|
||||||
|
|
||||||
@@ -245,8 +246,13 @@ class FlightPlanner:
|
|||||||
except IndexError:
|
except IndexError:
|
||||||
break
|
break
|
||||||
|
|
||||||
inventory[unit] = inventory[unit] - 2
|
if unit in DRONES:
|
||||||
flight = Flight(unit, 2, self.from_cp, FlightType.STRIKE)
|
count = 1
|
||||||
|
else:
|
||||||
|
count = 2
|
||||||
|
|
||||||
|
inventory[unit] = inventory[unit] - count
|
||||||
|
flight = Flight(unit, count, self.from_cp, FlightType.STRIKE)
|
||||||
|
|
||||||
flight.points = []
|
flight.points = []
|
||||||
flight.scheduled_in = offset + i*random.randint(self.doctrine["STRIKE_EVERY_X_MINUTES"] - 5, self.doctrine["STRIKE_EVERY_X_MINUTES"] + 5)
|
flight.scheduled_in = offset + i*random.randint(self.doctrine["STRIKE_EVERY_X_MINUTES"] - 5, self.doctrine["STRIKE_EVERY_X_MINUTES"] + 5)
|
||||||
@@ -607,7 +613,8 @@ class FlightPlanner:
|
|||||||
:param flight: Flight to setup
|
:param flight: Flight to setup
|
||||||
:param location: Location of the CAS targets
|
:param location: Location of the CAS targets
|
||||||
"""
|
"""
|
||||||
|
is_helo = hasattr(flight.unit_type, "helicopter") and flight.unit_type.helicopter
|
||||||
|
cap_alt = 1000
|
||||||
flight.points = []
|
flight.points = []
|
||||||
flight.flight_type = FlightType.CAS
|
flight.flight_type = FlightType.CAS
|
||||||
|
|
||||||
@@ -616,9 +623,12 @@ class FlightPlanner:
|
|||||||
egress = ingress.point_from_heading(heading, distance)
|
egress = ingress.point_from_heading(heading, distance)
|
||||||
|
|
||||||
ascend = self.generate_ascend_point(flight.from_cp)
|
ascend = self.generate_ascend_point(flight.from_cp)
|
||||||
|
if is_helo:
|
||||||
|
cap_alt = 500
|
||||||
|
ascend.alt = 500
|
||||||
flight.points.append(ascend)
|
flight.points.append(ascend)
|
||||||
|
|
||||||
ingress_point = FlightWaypoint(ingress.x, ingress.y, 1000)
|
ingress_point = FlightWaypoint(ingress.x, ingress.y, cap_alt)
|
||||||
ingress_point.alt_type = "RADIO"
|
ingress_point.alt_type = "RADIO"
|
||||||
ingress_point.name = "INGRESS"
|
ingress_point.name = "INGRESS"
|
||||||
ingress_point.pretty_name = "INGRESS"
|
ingress_point.pretty_name = "INGRESS"
|
||||||
@@ -626,7 +636,7 @@ class FlightPlanner:
|
|||||||
ingress_point.waypoint_type = FlightWaypointType.INGRESS_CAS
|
ingress_point.waypoint_type = FlightWaypointType.INGRESS_CAS
|
||||||
flight.points.append(ingress_point)
|
flight.points.append(ingress_point)
|
||||||
|
|
||||||
center_point = FlightWaypoint(center.x, center.y, 1000)
|
center_point = FlightWaypoint(center.x, center.y, cap_alt)
|
||||||
center_point.alt_type = "RADIO"
|
center_point.alt_type = "RADIO"
|
||||||
center_point.description = "Provide CAS"
|
center_point.description = "Provide CAS"
|
||||||
center_point.name = "CAS"
|
center_point.name = "CAS"
|
||||||
@@ -634,7 +644,7 @@ class FlightPlanner:
|
|||||||
center_point.waypoint_type = FlightWaypointType.CAS
|
center_point.waypoint_type = FlightWaypointType.CAS
|
||||||
flight.points.append(center_point)
|
flight.points.append(center_point)
|
||||||
|
|
||||||
egress_point = FlightWaypoint(egress.x, egress.y, 1000)
|
egress_point = FlightWaypoint(egress.x, egress.y, cap_alt)
|
||||||
egress_point.alt_type = "RADIO"
|
egress_point.alt_type = "RADIO"
|
||||||
egress_point.description = "Egress from CAS area"
|
egress_point.description = "Egress from CAS area"
|
||||||
egress_point.name = "EGRESS"
|
egress_point.name = "EGRESS"
|
||||||
@@ -643,6 +653,8 @@ class FlightPlanner:
|
|||||||
flight.points.append(egress_point)
|
flight.points.append(egress_point)
|
||||||
|
|
||||||
descend = self.generate_descend_point(flight.from_cp)
|
descend = self.generate_descend_point(flight.from_cp)
|
||||||
|
if is_helo:
|
||||||
|
descend.alt = 300
|
||||||
flight.points.append(descend)
|
flight.points.append(descend)
|
||||||
|
|
||||||
rtb = self.generate_rtb_waypoint(flight.from_cp)
|
rtb = self.generate_rtb_waypoint(flight.from_cp)
|
||||||
|
|||||||
@@ -31,6 +31,7 @@ CAP_CAPABLE = [
|
|||||||
MiG_19P,
|
MiG_19P,
|
||||||
MiG_21Bis,
|
MiG_21Bis,
|
||||||
MiG_23MLD,
|
MiG_23MLD,
|
||||||
|
MiG_25PD,
|
||||||
MiG_29A,
|
MiG_29A,
|
||||||
MiG_29G,
|
MiG_29G,
|
||||||
MiG_29S,
|
MiG_29S,
|
||||||
@@ -51,6 +52,7 @@ CAP_CAPABLE = [
|
|||||||
F_14B,
|
F_14B,
|
||||||
F_15C,
|
F_15C,
|
||||||
F_15E,
|
F_15E,
|
||||||
|
F_16A,
|
||||||
F_16C_50,
|
F_16C_50,
|
||||||
FA_18C_hornet,
|
FA_18C_hornet,
|
||||||
|
|
||||||
@@ -72,7 +74,7 @@ CAP_CAPABLE = [
|
|||||||
Rafale_M,
|
Rafale_M,
|
||||||
]
|
]
|
||||||
|
|
||||||
# USed for CAS (Close air support) and BAI (Battlefield Interdiction)
|
# Used for CAS (Close air support) and BAI (Battlefield Interdiction)
|
||||||
CAS_CAPABLE = [
|
CAS_CAPABLE = [
|
||||||
|
|
||||||
MiG_15bis,
|
MiG_15bis,
|
||||||
@@ -100,6 +102,7 @@ CAS_CAPABLE = [
|
|||||||
F_5E_3,
|
F_5E_3,
|
||||||
F_14B,
|
F_14B,
|
||||||
F_15E,
|
F_15E,
|
||||||
|
F_16A,
|
||||||
F_16C_50,
|
F_16C_50,
|
||||||
FA_18C_hornet,
|
FA_18C_hornet,
|
||||||
|
|
||||||
@@ -114,6 +117,8 @@ CAS_CAPABLE = [
|
|||||||
|
|
||||||
AH_64A,
|
AH_64A,
|
||||||
AH_64D,
|
AH_64D,
|
||||||
|
AH_1W,
|
||||||
|
|
||||||
|
|
||||||
UH_1H,
|
UH_1H,
|
||||||
|
|
||||||
@@ -135,7 +140,11 @@ CAS_CAPABLE = [
|
|||||||
FW_190A8,
|
FW_190A8,
|
||||||
|
|
||||||
A_4E_C,
|
A_4E_C,
|
||||||
Rafale_A_S
|
Rafale_A_S,
|
||||||
|
|
||||||
|
WingLoong_I,
|
||||||
|
MQ_9_Reaper,
|
||||||
|
RQ_1A_Predator
|
||||||
]
|
]
|
||||||
|
|
||||||
# Aircraft used for SEAD / DEAD tasks
|
# Aircraft used for SEAD / DEAD tasks
|
||||||
@@ -184,6 +193,7 @@ STRIKE_CAPABLE = [
|
|||||||
F_5E_3,
|
F_5E_3,
|
||||||
F_14B,
|
F_14B,
|
||||||
F_15E,
|
F_15E,
|
||||||
|
F_16A,
|
||||||
F_16C_50,
|
F_16C_50,
|
||||||
FA_18C_hornet,
|
FA_18C_hornet,
|
||||||
|
|
||||||
@@ -216,10 +226,17 @@ ANTISHIP_CAPABLE = [
|
|||||||
F_15E,
|
F_15E,
|
||||||
AV8BNA,
|
AV8BNA,
|
||||||
JF_17,
|
JF_17,
|
||||||
|
F_16A,
|
||||||
F_16C_50,
|
F_16C_50,
|
||||||
A_10C,
|
A_10C,
|
||||||
A_10A,
|
A_10A,
|
||||||
|
|
||||||
Ju_88A4,
|
Ju_88A4,
|
||||||
Rafale_A_S
|
Rafale_A_S
|
||||||
]
|
]
|
||||||
|
|
||||||
|
DRONES = [
|
||||||
|
MQ_9_Reaper,
|
||||||
|
RQ_1A_Predator,
|
||||||
|
WingLoong_I
|
||||||
|
]
|
||||||
|
|||||||
4
gen/flights/radio_generator.py
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
from dcs.unitgroup import FlyingGroup
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -66,6 +66,7 @@ class GroundObjectsGenerator:
|
|||||||
if not ground_object.sea_object:
|
if not ground_object.sea_object:
|
||||||
vg = self.m.vehicle_group(side, g.name, utype, position=g.position, heading=g.units[0].heading)
|
vg = self.m.vehicle_group(side, g.name, utype, position=g.position, heading=g.units[0].heading)
|
||||||
vg.units[0].name = self.m.string(g.units[0].name)
|
vg.units[0].name = self.m.string(g.units[0].name)
|
||||||
|
vg.units[0].player_can_drive = True
|
||||||
for i, u in enumerate(g.units):
|
for i, u in enumerate(g.units):
|
||||||
if i > 0:
|
if i > 0:
|
||||||
vehicle = Vehicle(self.m.next_unit_id(), self.m.string(u.name), u.type)
|
vehicle = Vehicle(self.m.next_unit_id(), self.m.string(u.name), u.type)
|
||||||
|
|||||||
@@ -65,6 +65,40 @@ SAM_MAP = {
|
|||||||
AirDefence.HQ_7_Self_Propelled_LN: HQ7Generator
|
AirDefence.HQ_7_Self_Propelled_LN: HQ7Generator
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SAM_PRICES = {
|
||||||
|
AirDefence.SAM_Hawk_PCP: 35,
|
||||||
|
AirDefence.AAA_ZU_23_Emplacement: 10,
|
||||||
|
AirDefence.AAA_ZU_23_Closed: 10,
|
||||||
|
AirDefence.AAA_ZU_23_on_Ural_375: 10,
|
||||||
|
AirDefence.AAA_ZU_23_Insurgent_on_Ural_375: 10,
|
||||||
|
AirDefence.AAA_ZU_23_Insurgent_Closed: 10,
|
||||||
|
AirDefence.AAA_ZU_23_Insurgent: 10,
|
||||||
|
AirDefence.SPAAA_ZSU_23_4_Shilka: 10,
|
||||||
|
AirDefence.AAA_Vulcan_M163: 15,
|
||||||
|
AirDefence.SAM_Linebacker_M6: 20,
|
||||||
|
AirDefence.Rapier_FSA_Launcher: 20,
|
||||||
|
AirDefence.SAM_Avenger_M1097: 22,
|
||||||
|
AirDefence.SPAAA_Gepard: 24,
|
||||||
|
AirDefence.SAM_Roland_ADS: 40,
|
||||||
|
AirDefence.SAM_Patriot_LN_M901: 85,
|
||||||
|
AirDefence.SAM_Patriot_EPP_III: 85,
|
||||||
|
AirDefence.SAM_Chaparral_M48: 25,
|
||||||
|
AirDefence.AAA_Bofors_40mm: 15,
|
||||||
|
AirDefence.AAA_8_8cm_Flak_36: 15,
|
||||||
|
AirDefence.SAM_SA_2_LN_SM_90: 30,
|
||||||
|
AirDefence.SAM_SA_3_S_125_LN_5P73: 35,
|
||||||
|
AirDefence.SAM_SA_6_Kub_LN_2P25: 45,
|
||||||
|
AirDefence.SAM_SA_8_Osa_9A33: 30,
|
||||||
|
AirDefence.SAM_SA_9_Strela_1_9P31: 25,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_LN_5P85C: 80,
|
||||||
|
AirDefence.SAM_SA_10_S_300PS_CP_54K6: 80,
|
||||||
|
AirDefence.SAM_SA_11_Buk_LN_9A310M1: 60,
|
||||||
|
AirDefence.SAM_SA_13_Strela_10M3_9A35M3: 30,
|
||||||
|
AirDefence.SAM_SA_15_Tor_9A331: 40,
|
||||||
|
AirDefence.SAM_SA_19_Tunguska_2S6: 35,
|
||||||
|
AirDefence.HQ_7_Self_Propelled_LN: 35
|
||||||
|
}
|
||||||
|
|
||||||
def generate_anti_air_group(game, parent_cp, ground_object, faction:str):
|
def generate_anti_air_group(game, parent_cp, ground_object, faction:str):
|
||||||
"""
|
"""
|
||||||
This generate a SAM group
|
This generate a SAM group
|
||||||
|
|||||||
BIN
installer/ISCC.exe
Normal file
51
installer/dcs_liberation.iss
Normal file
@@ -0,0 +1,51 @@
|
|||||||
|
; Script generated by the Inno Setup Script Wizard.
|
||||||
|
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
|
||||||
|
|
||||||
|
#define MyAppName "DCS Liberation"
|
||||||
|
#define MyAppVersion "{{version}}"
|
||||||
|
#define MyAppPublisher "Khopa"
|
||||||
|
#define MyAppURL "https://github.com/Khopa/dcs_liberation/wiki"
|
||||||
|
#define MyAppExeName "liberation_main.exe"
|
||||||
|
|
||||||
|
[Setup]
|
||||||
|
; NOTE: The value of AppId uniquely identifies this application. Do not use the same AppId value in installers for other applications.
|
||||||
|
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
|
||||||
|
AppId={{6753B352-D281-42CB-9AFA-5E93EB90AA5A}
|
||||||
|
AppName={#MyAppName}
|
||||||
|
AppVersion={#MyAppVersion}
|
||||||
|
;AppVerName={#MyAppName} {#MyAppVersion}
|
||||||
|
AppPublisher={#MyAppPublisher}
|
||||||
|
AppPublisherURL={#MyAppURL}
|
||||||
|
AppSupportURL={#MyAppURL}
|
||||||
|
AppUpdatesURL={#MyAppURL}
|
||||||
|
DefaultDirName={autopf}\{#MyAppName}
|
||||||
|
DefaultGroupName={#MyAppName}
|
||||||
|
AllowNoIcons=yes
|
||||||
|
; Remove the following line to run in administrative install mode (install for all users.)
|
||||||
|
PrivilegesRequired=lowest
|
||||||
|
PrivilegesRequiredOverridesAllowed=dialog
|
||||||
|
OutputDir=..\dist
|
||||||
|
OutputBaseFilename=dcs_liberation
|
||||||
|
SetupIconFile=..\resources\icon.ico
|
||||||
|
UninstallDisplayIcon={app}\liberation_main.exe
|
||||||
|
Compression=lzma
|
||||||
|
SolidCompression=yes
|
||||||
|
WizardStyle=modern
|
||||||
|
|
||||||
|
[Languages]
|
||||||
|
Name: "english"; MessagesFile: "compiler:Default.isl"
|
||||||
|
|
||||||
|
[Tasks]
|
||||||
|
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
|
||||||
|
|
||||||
|
[Files]
|
||||||
|
Source: "..\dist\dcs_liberation\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs
|
||||||
|
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
|
||||||
|
|
||||||
|
[Icons]
|
||||||
|
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
|
||||||
|
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon
|
||||||
|
|
||||||
|
[Run]
|
||||||
|
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent
|
||||||
|
|
||||||
1
pydcs
Submodule
@@ -1,14 +1,10 @@
|
|||||||
from userdata import logging_config
|
from userdata import logging_config
|
||||||
|
|
||||||
# Logging setup
|
|
||||||
VERSION_STRING = "2.0.10"
|
|
||||||
logging_config.init_logging(VERSION_STRING)
|
|
||||||
|
|
||||||
import logging
|
import logging
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
import dcs
|
from pydcs import dcs
|
||||||
from PySide2 import QtWidgets
|
from PySide2 import QtWidgets
|
||||||
from PySide2.QtGui import QPixmap
|
from PySide2.QtGui import QPixmap
|
||||||
from PySide2.QtWidgets import QApplication, QSplashScreen
|
from PySide2.QtWidgets import QApplication, QSplashScreen
|
||||||
@@ -19,6 +15,9 @@ from qt_ui.windows.QLiberationWindow import QLiberationWindow
|
|||||||
from qt_ui.windows.preferences.QLiberationFirstStartWindow import QLiberationFirstStartWindow
|
from qt_ui.windows.preferences.QLiberationFirstStartWindow import QLiberationFirstStartWindow
|
||||||
from userdata import liberation_install, persistency, liberation_theme
|
from userdata import liberation_install, persistency, liberation_theme
|
||||||
|
|
||||||
|
# Logging setup
|
||||||
|
logging_config.init_logging(uiconstants.VERSION_STRING)
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
|
||||||
os.environ["QT_AUTO_SCREEN_SCALE_FACTOR"] = "1" # Potential fix for 4K screens
|
os.environ["QT_AUTO_SCREEN_SCALE_FACTOR"] = "1" # Potential fix for 4K screens
|
||||||
|
|||||||
@@ -8,6 +8,8 @@ from game.event import UnitsDeliveryEvent, FrontlineAttackEvent
|
|||||||
from theater.theatergroundobject import CATEGORY_MAP
|
from theater.theatergroundobject import CATEGORY_MAP
|
||||||
from userdata.liberation_theme import get_theme_icons
|
from userdata.liberation_theme import get_theme_icons
|
||||||
|
|
||||||
|
VERSION_STRING = "2.1.0"
|
||||||
|
|
||||||
URLS : Dict[str, str] = {
|
URLS : Dict[str, str] = {
|
||||||
"Manual": "https://github.com/khopa/dcs_liberation/wiki",
|
"Manual": "https://github.com/khopa/dcs_liberation/wiki",
|
||||||
"Repository": "https://github.com/khopa/dcs_liberation",
|
"Repository": "https://github.com/khopa/dcs_liberation",
|
||||||
@@ -69,7 +71,7 @@ COLORS: Dict[str, QColor] = {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
CP_SIZE = 24
|
CP_SIZE = 12
|
||||||
|
|
||||||
AIRCRAFT_ICONS: Dict[str, QPixmap] = {}
|
AIRCRAFT_ICONS: Dict[str, QPixmap] = {}
|
||||||
VEHICLES_ICONS: Dict[str, QPixmap] = {}
|
VEHICLES_ICONS: Dict[str, QPixmap] = {}
|
||||||
@@ -86,6 +88,7 @@ def load_icons():
|
|||||||
ICONS["Terrain_Nevada"] = QPixmap("./resources/ui/terrain_nevada.gif")
|
ICONS["Terrain_Nevada"] = QPixmap("./resources/ui/terrain_nevada.gif")
|
||||||
ICONS["Terrain_Normandy"] = QPixmap("./resources/ui/terrain_normandy.gif")
|
ICONS["Terrain_Normandy"] = QPixmap("./resources/ui/terrain_normandy.gif")
|
||||||
ICONS["Terrain_Channel"] = QPixmap("./resources/ui/terrain_channel.gif")
|
ICONS["Terrain_Channel"] = QPixmap("./resources/ui/terrain_channel.gif")
|
||||||
|
ICONS["Terrain_Syria"] = QPixmap("./resources/ui/terrain_syria.gif")
|
||||||
|
|
||||||
ICONS["Dawn"] = QPixmap("./resources/ui/daytime/dawn.png")
|
ICONS["Dawn"] = QPixmap("./resources/ui/daytime/dawn.png")
|
||||||
ICONS["Day"] = QPixmap("./resources/ui/daytime/day.png")
|
ICONS["Day"] = QPixmap("./resources/ui/daytime/day.png")
|
||||||
|
|||||||
@@ -143,7 +143,7 @@ class QLiberationMap(QGraphicsView):
|
|||||||
go_pos = self._transform_point(ground_object.position)
|
go_pos = self._transform_point(ground_object.position)
|
||||||
if not ground_object.airbase_group:
|
if not ground_object.airbase_group:
|
||||||
buildings = self.game.theater.find_ground_objects_by_obj_name(ground_object.obj_name)
|
buildings = self.game.theater.find_ground_objects_by_obj_name(ground_object.obj_name)
|
||||||
scene.addItem(QMapGroundObject(self, go_pos[0], go_pos[1], 12, 12, cp, ground_object, buildings))
|
scene.addItem(QMapGroundObject(self, go_pos[0], go_pos[1], 14, 12, cp, ground_object, self.game, buildings))
|
||||||
|
|
||||||
if ground_object.category == "aa" and self.get_display_rule("sam"):
|
if ground_object.category == "aa" and self.get_display_rule("sam"):
|
||||||
max_range = 0
|
max_range = 0
|
||||||
|
|||||||
@@ -1,19 +1,22 @@
|
|||||||
from PySide2.QtCore import QPoint, QRect, QPointF, Qt
|
from PySide2.QtCore import QPoint, QRect, QPointF, Qt
|
||||||
from PySide2.QtGui import QPainter
|
from PySide2.QtGui import QPainter, QBrush
|
||||||
from PySide2.QtWidgets import QGraphicsRectItem, QGraphicsItem, QGraphicsSceneHoverEvent, QGraphicsSceneMouseEvent
|
from PySide2.QtWidgets import QGraphicsRectItem, QGraphicsItem, QGraphicsSceneHoverEvent, QGraphicsSceneMouseEvent
|
||||||
|
|
||||||
import qt_ui.uiconstants as CONST
|
import qt_ui.uiconstants as CONST
|
||||||
from game import db
|
from game import db, Game
|
||||||
|
from game.data.building_data import FORTIFICATION_BUILDINGS
|
||||||
|
from qt_ui.windows.groundobject.QGroundObjectMenu import QGroundObjectMenu
|
||||||
from theater import TheaterGroundObject, ControlPoint
|
from theater import TheaterGroundObject, ControlPoint
|
||||||
|
|
||||||
|
|
||||||
class QMapGroundObject(QGraphicsRectItem):
|
class QMapGroundObject(QGraphicsRectItem):
|
||||||
|
|
||||||
def __init__(self, parent, x: float, y: float, w: float, h: float, cp: ControlPoint, model: TheaterGroundObject, buildings=[]):
|
def __init__(self, parent, x: float, y: float, w: float, h: float, cp: ControlPoint, model: TheaterGroundObject, game:Game, buildings=[]):
|
||||||
super(QMapGroundObject, self).__init__(x, y, w, h)
|
super(QMapGroundObject, self).__init__(x, y, w, h)
|
||||||
self.model = model
|
self.model = model
|
||||||
self.cp = cp
|
self.cp = cp
|
||||||
self.parent = parent
|
self.parent = parent
|
||||||
|
self.game = game
|
||||||
self.setAcceptHoverEvents(True)
|
self.setAcceptHoverEvents(True)
|
||||||
self.setZValue(2)
|
self.setZValue(2)
|
||||||
self.buildings = buildings
|
self.buildings = buildings
|
||||||
@@ -39,6 +42,8 @@ class QMapGroundObject(QGraphicsRectItem):
|
|||||||
tooltip = tooltip + str(building.dcs_identifier) + "\n"
|
tooltip = tooltip + str(building.dcs_identifier) + "\n"
|
||||||
self.setToolTip(tooltip[:-1])
|
self.setToolTip(tooltip[:-1])
|
||||||
|
|
||||||
|
def mousePressEvent(self, event:QGraphicsSceneMouseEvent):
|
||||||
|
self.openEditionMenu()
|
||||||
|
|
||||||
def paint(self, painter, option, widget=None):
|
def paint(self, painter, option, widget=None):
|
||||||
#super(QMapControlPoint, self).paint(painter, option, widget)
|
#super(QMapControlPoint, self).paint(painter, option, widget)
|
||||||
@@ -53,14 +58,49 @@ class QMapGroundObject(QGraphicsRectItem):
|
|||||||
if cat == "aa" and self.model.sea_object:
|
if cat == "aa" and self.model.sea_object:
|
||||||
cat = "ship"
|
cat = "ship"
|
||||||
|
|
||||||
if not self.model.is_dead and not self.cp.captured:
|
rect = QRect(option.rect.x()+2,option.rect.y(),option.rect.width()-2,option.rect.height())
|
||||||
painter.drawPixmap(option.rect, CONST.ICONS[cat + enemyIcons])
|
|
||||||
elif not self.model.is_dead:
|
is_dead = self.model.is_dead
|
||||||
painter.drawPixmap(option.rect, CONST.ICONS[cat + playerIcons])
|
for building in self.buildings:
|
||||||
|
if not building.is_dead:
|
||||||
|
is_dead = False
|
||||||
|
break
|
||||||
|
|
||||||
|
if not is_dead and not self.cp.captured:
|
||||||
|
painter.drawPixmap(rect, CONST.ICONS[cat + enemyIcons])
|
||||||
|
elif not is_dead:
|
||||||
|
painter.drawPixmap(rect, CONST.ICONS[cat + playerIcons])
|
||||||
else:
|
else:
|
||||||
painter.drawPixmap(option.rect, CONST.ICONS["destroyed"])
|
painter.drawPixmap(rect, CONST.ICONS["destroyed"])
|
||||||
|
|
||||||
|
self.drawHealthGauge(painter, option)
|
||||||
painter.restore()
|
painter.restore()
|
||||||
|
|
||||||
|
def drawHealthGauge(self, painter, option):
|
||||||
|
units_alive = 0
|
||||||
|
units_dead = 0
|
||||||
|
|
||||||
|
if len(self.model.groups) == 0:
|
||||||
|
for building in self.buildings:
|
||||||
|
if building.dcs_identifier in FORTIFICATION_BUILDINGS:
|
||||||
|
continue
|
||||||
|
if building.is_dead:
|
||||||
|
units_dead += 1
|
||||||
|
else:
|
||||||
|
units_alive += 1
|
||||||
|
|
||||||
|
for g in self.model.groups:
|
||||||
|
units_alive += len(g.units)
|
||||||
|
if hasattr(g, "units_losts"):
|
||||||
|
units_dead += len(g.units_losts)
|
||||||
|
|
||||||
|
if units_dead + units_alive > 0:
|
||||||
|
ratio = float(units_alive)/(float(units_dead) + float(units_alive))
|
||||||
|
bar_height = ratio * option.rect.height()
|
||||||
|
painter.fillRect(option.rect.x(), option.rect.y(), 2, option.rect.height(), QBrush(CONST.COLORS["dark_red"]))
|
||||||
|
painter.fillRect(option.rect.x(), option.rect.y(), 2, bar_height, QBrush(CONST.COLORS["green"]))
|
||||||
|
|
||||||
|
|
||||||
def hoverEnterEvent(self, event: QGraphicsSceneHoverEvent):
|
def hoverEnterEvent(self, event: QGraphicsSceneHoverEvent):
|
||||||
self.update()
|
self.update()
|
||||||
self.setCursor(Qt.PointingHandCursor)
|
self.setCursor(Qt.PointingHandCursor)
|
||||||
@@ -72,3 +112,7 @@ class QMapGroundObject(QGraphicsRectItem):
|
|||||||
def hoverLeaveEvent(self, event: QGraphicsSceneHoverEvent):
|
def hoverLeaveEvent(self, event: QGraphicsSceneHoverEvent):
|
||||||
self.update()
|
self.update()
|
||||||
|
|
||||||
|
def openEditionMenu(self):
|
||||||
|
self.editionMenu = QGroundObjectMenu(self.window(), self.model, self.buildings, self.cp, self.game)
|
||||||
|
self.editionMenu.show()
|
||||||
|
|
||||||
|
|||||||
@@ -12,10 +12,9 @@ from game import Game
|
|||||||
from qt_ui.uiconstants import URLS
|
from qt_ui.uiconstants import URLS
|
||||||
from qt_ui.widgets.QTopPanel import QTopPanel
|
from qt_ui.widgets.QTopPanel import QTopPanel
|
||||||
from qt_ui.widgets.map.QLiberationMap import QLiberationMap
|
from qt_ui.widgets.map.QLiberationMap import QLiberationMap
|
||||||
from qt_ui.windows.preferences import QLiberationPreferences
|
|
||||||
from qt_ui.windows.GameUpdateSignal import GameUpdateSignal, DebriefingSignal
|
from qt_ui.windows.GameUpdateSignal import GameUpdateSignal, DebriefingSignal
|
||||||
from qt_ui.windows.QDebriefingWindow import QDebriefingWindow
|
from qt_ui.windows.QDebriefingWindow import QDebriefingWindow
|
||||||
from qt_ui.windows.QNewGameWizard import NewGameWizard
|
from qt_ui.windows.newgame.QNewGameWizard import NewGameWizard
|
||||||
from qt_ui.windows.infos.QInfoPanel import QInfoPanel
|
from qt_ui.windows.infos.QInfoPanel import QInfoPanel
|
||||||
from qt_ui.windows.preferences.QLiberationPreferencesWindow import QLiberationPreferencesWindow
|
from qt_ui.windows.preferences.QLiberationPreferencesWindow import QLiberationPreferencesWindow
|
||||||
from userdata import persistency
|
from userdata import persistency
|
||||||
@@ -212,17 +211,16 @@ class QLiberationWindow(QMainWindow):
|
|||||||
self.info_panel.setGame(game)
|
self.info_panel.setGame(game)
|
||||||
|
|
||||||
def showAboutDialog(self):
|
def showAboutDialog(self):
|
||||||
text = "<h3>DCS Liberation</h3>" + \
|
text = "<h3>DCS Liberation " + CONST.VERSION_STRING + "</h3>" + \
|
||||||
"<b>Source code :</b> https://github.com/khopa/dcs_liberation" + \
|
"<b>Source code :</b> https://github.com/khopa/dcs_liberation" + \
|
||||||
"<h4>Authors</h4>" + \
|
"<h4>Authors</h4>" + \
|
||||||
"<p>DCS Liberation was originally developed by <b>shdwp</b>, DCS Liberation 2.0 is a partial rewrite based on this work by <b>Khopa</b>." \
|
"<p>DCS Liberation was originally developed by <b>shdwp</b>, DCS Liberation 2.0 is a partial rewrite based on this work by <b>Khopa</b>." \
|
||||||
"<h4>Contributors</h4>" + \
|
"<h4>Contributors</h4>" + \
|
||||||
"shdwp, Khopa, Wrycu, calvinmorrow, JohanAberg, Deus" + \
|
"shdwp, Khopa, Wrycu, calvinmorrow, JohanAberg, Deus, root0fall, Captain Cody" + \
|
||||||
"<h4>Special Thanks :</h4>" \
|
"<h4>Special Thanks :</h4>" \
|
||||||
"<b>rp-</b> <i>for the pydcs framework</i><br/>"\
|
"<b>rp-</b> <i>for the pydcs framework</i><br/>"\
|
||||||
"<b>Grimes (mrSkortch)</b> & <b>Speed</b> <i>for the MIST framework</i><br/>"\
|
"<b>Grimes (mrSkortch)</b> & <b>Speed</b> <i>for the MIST framework</i><br/>"\
|
||||||
"<b>Ciribob </b> <i>for the JTACAutoLase.lua script</i><br/>"
|
"<b>Ciribob </b> <i>for the JTACAutoLase.lua script</i><br/>"
|
||||||
|
|
||||||
about = QMessageBox()
|
about = QMessageBox()
|
||||||
about.setWindowTitle("About DCS Liberation")
|
about.setWindowTitle("About DCS Liberation")
|
||||||
about.setIcon(QMessageBox.Icon.Information)
|
about.setIcon(QMessageBox.Icon.Information)
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ class QWaitingForMissionResultWindow(QDialog):
|
|||||||
updateBox.setLayout(updateLayout)
|
updateBox.setLayout(updateLayout)
|
||||||
self.debriefing = debriefing
|
self.debriefing = debriefing
|
||||||
|
|
||||||
updateLayout.addWidget(QLabel("<b>Aircrafts destroyed</b>"), 0, 0)
|
updateLayout.addWidget(QLabel("<b>Aircraft destroyed</b>"), 0, 0)
|
||||||
updateLayout.addWidget(QLabel(str(len(debriefing.killed_aircrafts))), 0, 1)
|
updateLayout.addWidget(QLabel(str(len(debriefing.killed_aircrafts))), 0, 1)
|
||||||
|
|
||||||
updateLayout.addWidget(QLabel("<b>Ground units destroyed</b>"), 1, 0)
|
updateLayout.addWidget(QLabel("<b>Ground units destroyed</b>"), 1, 0)
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ from game.event import ControlPointType
|
|||||||
from qt_ui.uiconstants import EVENT_ICONS
|
from qt_ui.uiconstants import EVENT_ICONS
|
||||||
from qt_ui.windows.GameUpdateSignal import GameUpdateSignal
|
from qt_ui.windows.GameUpdateSignal import GameUpdateSignal
|
||||||
from qt_ui.windows.basemenu.QBaseMenuTabs import QBaseMenuTabs
|
from qt_ui.windows.basemenu.QBaseMenuTabs import QBaseMenuTabs
|
||||||
|
from qt_ui.windows.basemenu.QRecruitBehaviour import QRecruitBehaviour
|
||||||
from theater import ControlPoint
|
from theater import ControlPoint
|
||||||
|
|
||||||
|
|
||||||
@@ -19,6 +20,7 @@ class QBaseMenu2(QDialog):
|
|||||||
self.cp = cp
|
self.cp = cp
|
||||||
self.game = game
|
self.game = game
|
||||||
self.is_carrier = self.cp.cptype in [ControlPointType.AIRCRAFT_CARRIER_GROUP, ControlPointType.LHA_GROUP]
|
self.is_carrier = self.cp.cptype in [ControlPointType.AIRCRAFT_CARRIER_GROUP, ControlPointType.LHA_GROUP]
|
||||||
|
self.objectName = "menuDialogue"
|
||||||
|
|
||||||
# Widgets
|
# Widgets
|
||||||
self.qbase_menu_tab = QBaseMenuTabs(cp, game)
|
self.qbase_menu_tab = QBaseMenuTabs(cp, game)
|
||||||
@@ -58,7 +60,6 @@ class QBaseMenu2(QDialog):
|
|||||||
title.setProperty("style", "base-title")
|
title.setProperty("style", "base-title")
|
||||||
unitsPower = QLabel("{} / {} / Runway : {}".format(self.cp.base.total_planes, self.cp.base.total_armor,
|
unitsPower = QLabel("{} / {} / Runway : {}".format(self.cp.base.total_planes, self.cp.base.total_armor,
|
||||||
"Available" if self.cp.has_runway() else "Unavailable"))
|
"Available" if self.cp.has_runway() else "Unavailable"))
|
||||||
|
|
||||||
self.topLayout.addWidget(title)
|
self.topLayout.addWidget(title)
|
||||||
self.topLayout.addWidget(unitsPower)
|
self.topLayout.addWidget(unitsPower)
|
||||||
self.topLayout.setAlignment(Qt.AlignTop)
|
self.topLayout.setAlignment(Qt.AlignTop)
|
||||||
@@ -69,7 +70,11 @@ class QBaseMenu2(QDialog):
|
|||||||
self.mainLayout.addWidget(header, 0, 0)
|
self.mainLayout.addWidget(header, 0, 0)
|
||||||
self.mainLayout.addWidget(self.topLayoutWidget, 1, 0)
|
self.mainLayout.addWidget(self.topLayoutWidget, 1, 0)
|
||||||
self.mainLayout.addWidget(self.qbase_menu_tab, 2, 0)
|
self.mainLayout.addWidget(self.qbase_menu_tab, 2, 0)
|
||||||
|
totalBudget = QLabel(QRecruitBehaviour.BUDGET_FORMAT.format(self.game.budget))
|
||||||
|
totalBudget.setObjectName("budgetField")
|
||||||
|
totalBudget.setAlignment(Qt.AlignRight | Qt.AlignBottom)
|
||||||
|
totalBudget.setProperty("style", "budget-label")
|
||||||
|
self.mainLayout.addWidget(totalBudget)
|
||||||
self.setLayout(self.mainLayout)
|
self.setLayout(self.mainLayout)
|
||||||
|
|
||||||
def closeEvent(self, closeEvent:QCloseEvent):
|
def closeEvent(self, closeEvent:QCloseEvent):
|
||||||
@@ -81,4 +86,4 @@ class QBaseMenu2(QDialog):
|
|||||||
elif self.cp.cptype == ControlPointType.LHA_GROUP:
|
elif self.cp.cptype == ControlPointType.LHA_GROUP:
|
||||||
return "./resources/ui/lha.png"
|
return "./resources/ui/lha.png"
|
||||||
else:
|
else:
|
||||||
return "./resources/ui/airbase.png"
|
return "./resources/ui/airbase.png"
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ from dcs.unittype import UnitType
|
|||||||
from theater import db
|
from theater import db
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class QRecruitBehaviour:
|
class QRecruitBehaviour:
|
||||||
|
|
||||||
game = None
|
game = None
|
||||||
@@ -12,10 +13,12 @@ class QRecruitBehaviour:
|
|||||||
deliveryEvent = None
|
deliveryEvent = None
|
||||||
existing_units_labels = None
|
existing_units_labels = None
|
||||||
bought_amount_labels = None
|
bought_amount_labels = None
|
||||||
|
BUDGET_FORMAT = "Available Budget: <b>${}M</b>"
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.bought_amount_labels = {}
|
self.bought_amount_labels = {}
|
||||||
self.existing_units_labels = {}
|
self.existing_units_labels = {}
|
||||||
|
self.update_available_budget()
|
||||||
|
|
||||||
def add_purchase_row(self, unit_type, layout, row):
|
def add_purchase_row(self, unit_type, layout, row):
|
||||||
|
|
||||||
@@ -91,12 +94,22 @@ class QRecruitBehaviour:
|
|||||||
self.cp.base.total_units_of_type(unit_type)
|
self.cp.base.total_units_of_type(unit_type)
|
||||||
))
|
))
|
||||||
|
|
||||||
|
def update_available_budget(self):
|
||||||
|
parent = self.parent()
|
||||||
|
while parent.objectName != "menuDialogue":
|
||||||
|
parent = parent.parent()
|
||||||
|
for child in parent.children():
|
||||||
|
if child.objectName() == "budgetField":
|
||||||
|
child.setText(QRecruitBehaviour.BUDGET_FORMAT.format(self.game.budget))
|
||||||
|
|
||||||
def buy(self, unit_type):
|
def buy(self, unit_type):
|
||||||
|
|
||||||
price = db.PRICES[unit_type]
|
price = db.PRICES[unit_type]
|
||||||
if self.game.budget >= price:
|
if self.game.budget >= price:
|
||||||
self.deliveryEvent.deliver({unit_type: 1})
|
self.deliveryEvent.deliver({unit_type: 1})
|
||||||
self.game.budget -= price
|
self.game.budget -= price
|
||||||
self._update_count_label(unit_type)
|
self._update_count_label(unit_type)
|
||||||
|
self.update_available_budget()
|
||||||
|
|
||||||
def sell(self, unit_type):
|
def sell(self, unit_type):
|
||||||
if self.deliveryEvent.units.get(unit_type, 0) > 0:
|
if self.deliveryEvent.units.get(unit_type, 0) > 0:
|
||||||
@@ -111,3 +124,4 @@ class QRecruitBehaviour:
|
|||||||
self.cp.base.commit_losses({unit_type: 1})
|
self.cp.base.commit_losses({unit_type: 1})
|
||||||
|
|
||||||
self._update_count_label(unit_type)
|
self._update_count_label(unit_type)
|
||||||
|
self.update_available_budget()
|
||||||
|
|||||||
@@ -1,16 +1,22 @@
|
|||||||
from PySide2.QtWidgets import QGridLayout, QLabel, QGroupBox
|
from PySide2.QtWidgets import QGridLayout, QLabel, QGroupBox, QPushButton
|
||||||
|
|
||||||
from qt_ui.uiconstants import VEHICLES_ICONS
|
from qt_ui.uiconstants import VEHICLES_ICONS
|
||||||
|
from qt_ui.windows.groundobject.QGroundObjectMenu import QGroundObjectMenu
|
||||||
from theater import ControlPoint, TheaterGroundObject
|
from theater import ControlPoint, TheaterGroundObject
|
||||||
|
|
||||||
|
|
||||||
class QBaseDefenseGroupInfo(QGroupBox):
|
class QBaseDefenseGroupInfo(QGroupBox):
|
||||||
|
|
||||||
def __init__(self, cp:ControlPoint, ground_object: TheaterGroundObject):
|
def __init__(self, cp:ControlPoint, ground_object: TheaterGroundObject, game):
|
||||||
super(QBaseDefenseGroupInfo, self).__init__("Group : " + ground_object.obj_name)
|
super(QBaseDefenseGroupInfo, self).__init__("Group : " + ground_object.obj_name)
|
||||||
self.ground_object = ground_object
|
self.ground_object = ground_object
|
||||||
|
self.cp = cp
|
||||||
|
self.game = game
|
||||||
|
self.buildings = game.theater.find_ground_objects_by_obj_name(self.ground_object.obj_name)
|
||||||
self.init_ui()
|
self.init_ui()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def init_ui(self):
|
def init_ui(self):
|
||||||
unit_dict = {}
|
unit_dict = {}
|
||||||
layout = QGridLayout()
|
layout = QGridLayout()
|
||||||
@@ -29,8 +35,18 @@ class QBaseDefenseGroupInfo(QGroupBox):
|
|||||||
# icon.setText("<b>" + k[:6] + "</b>")
|
# icon.setText("<b>" + k[:6] + "</b>")
|
||||||
#icon.setProperty("style", "icon-plane")
|
#icon.setProperty("style", "icon-plane")
|
||||||
#layout.addWidget(icon, i, 0)
|
#layout.addWidget(icon, i, 0)
|
||||||
layout.addWidget(QLabel(str(v) + " x " + "<strong>" + k + "</strong>"), i, 1)
|
layout.addWidget(QLabel(str(v) + " x " + "<strong>" + k + "</strong>"), i, 0)
|
||||||
i = i + 1
|
i = i + 1
|
||||||
|
|
||||||
|
manage_button = QPushButton("Manage")
|
||||||
|
manage_button.setProperty("style", "btn-success")
|
||||||
|
manage_button.setMaximumWidth(180)
|
||||||
|
manage_button.clicked.connect(self.onManage)
|
||||||
|
layout.addWidget(manage_button, i+1, 0)
|
||||||
self.setLayout(layout)
|
self.setLayout(layout)
|
||||||
|
|
||||||
|
def onManage(self):
|
||||||
|
self.editionMenu = QGroundObjectMenu(self.window(), self.ground_object, self.buildings, self.cp, self.game)
|
||||||
|
self.editionMenu.show()
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -15,6 +15,6 @@ class QBaseDefensesHQ(QFrame):
|
|||||||
def init_ui(self):
|
def init_ui(self):
|
||||||
airport = self.game.theater.terrain.airport_by_id(self.cp.id)
|
airport = self.game.theater.terrain.airport_by_id(self.cp.id)
|
||||||
layout = QGridLayout()
|
layout = QGridLayout()
|
||||||
layout.addWidget(QBaseInformation(self.cp, airport))
|
layout.addWidget(QBaseInformation(self.cp, airport, self.game))
|
||||||
self.setLayout(layout)
|
self.setLayout(layout)
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
from PySide2.QtWidgets import QGridLayout, QLabel, QGroupBox, QVBoxLayout, QFrame
|
from PySide2.QtGui import Qt
|
||||||
|
from PySide2.QtWidgets import QGridLayout, QLabel, QGroupBox, QVBoxLayout, QFrame, QWidget, QScrollArea
|
||||||
|
|
||||||
from game import db
|
from game import db
|
||||||
from qt_ui.uiconstants import AIRCRAFT_ICONS, VEHICLES_ICONS
|
from qt_ui.uiconstants import AIRCRAFT_ICONS, VEHICLES_ICONS
|
||||||
@@ -8,17 +9,34 @@ from theater import ControlPoint, Airport
|
|||||||
|
|
||||||
class QBaseInformation(QFrame):
|
class QBaseInformation(QFrame):
|
||||||
|
|
||||||
def __init__(self, cp:ControlPoint, airport:Airport):
|
def __init__(self, cp:ControlPoint, airport:Airport, game):
|
||||||
super(QBaseInformation, self).__init__()
|
super(QBaseInformation, self).__init__()
|
||||||
self.cp = cp
|
self.cp = cp
|
||||||
self.airport = airport
|
self.airport = airport
|
||||||
|
self.game = game
|
||||||
self.setMinimumWidth(500)
|
self.setMinimumWidth(500)
|
||||||
self.init_ui()
|
self.init_ui()
|
||||||
|
|
||||||
def init_ui(self):
|
def init_ui(self):
|
||||||
self.layout = QVBoxLayout()
|
self.mainLayout = QVBoxLayout()
|
||||||
|
|
||||||
|
scroll_content = QWidget()
|
||||||
|
task_box_layout = QGridLayout()
|
||||||
|
scroll_content.setLayout(task_box_layout)
|
||||||
|
row = 0
|
||||||
|
|
||||||
for g in self.cp.ground_objects:
|
for g in self.cp.ground_objects:
|
||||||
if g.airbase_group:
|
if g.airbase_group:
|
||||||
group_info = QBaseDefenseGroupInfo(self.cp, g)
|
group_info = QBaseDefenseGroupInfo(self.cp, g, self.game)
|
||||||
self.layout.addWidget(group_info)
|
task_box_layout.addWidget(group_info)
|
||||||
self.setLayout(self.layout)
|
|
||||||
|
scroll_content.setLayout(task_box_layout)
|
||||||
|
scroll = QScrollArea()
|
||||||
|
scroll.setHorizontalScrollBarPolicy(Qt.ScrollBarAlwaysOff)
|
||||||
|
scroll.setVerticalScrollBarPolicy(Qt.ScrollBarAlwaysOn)
|
||||||
|
scroll.setWidgetResizable(True)
|
||||||
|
scroll.setWidget(scroll_content)
|
||||||
|
|
||||||
|
self.mainLayout.addWidget(scroll)
|
||||||
|
|
||||||
|
self.setLayout(self.mainLayout)
|
||||||
33
qt_ui/windows/groundobject/QBuildingInfo.py
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
import os
|
||||||
|
|
||||||
|
from PySide2.QtGui import QPixmap
|
||||||
|
from PySide2.QtWidgets import QGroupBox, QHBoxLayout, QVBoxLayout, QLabel
|
||||||
|
|
||||||
|
|
||||||
|
class QBuildingInfo(QGroupBox):
|
||||||
|
|
||||||
|
def __init__(self, building, ground_object):
|
||||||
|
super(QBuildingInfo, self).__init__()
|
||||||
|
self.building = building
|
||||||
|
self.ground_object = ground_object
|
||||||
|
self.init_ui()
|
||||||
|
|
||||||
|
def init_ui(self):
|
||||||
|
self.header = QLabel()
|
||||||
|
path = os.path.join("./resources/ui/units/buildings/" + self.building.dcs_identifier + ".png")
|
||||||
|
if self.building.is_dead:
|
||||||
|
pixmap = QPixmap("./resources/ui/units/buildings/dead.png")
|
||||||
|
elif os.path.isfile(path):
|
||||||
|
pixmap = QPixmap(path)
|
||||||
|
else:
|
||||||
|
pixmap = QPixmap("./resources/ui/units/buildings/missing.png")
|
||||||
|
self.header.setPixmap(pixmap)
|
||||||
|
name = "<b>{}</b> {}".format(self.building.dcs_identifier[0:18], "[DEAD]" if self.building.is_dead else "")
|
||||||
|
self.name = QLabel(name)
|
||||||
|
self.name.setProperty("style", "small")
|
||||||
|
layout = QVBoxLayout()
|
||||||
|
layout.addWidget(self.header)
|
||||||
|
layout.addWidget(self.name)
|
||||||
|
footer = QHBoxLayout()
|
||||||
|
self.setLayout(layout)
|
||||||
|
|
||||||
117
qt_ui/windows/groundobject/QGroundObjectMenu.py
Normal file
@@ -0,0 +1,117 @@
|
|||||||
|
import logging
|
||||||
|
|
||||||
|
from PySide2.QtGui import QCloseEvent
|
||||||
|
from PySide2.QtWidgets import QHBoxLayout, QWidget, QDialog, QGridLayout, QLabel, QGroupBox, QVBoxLayout, QPushButton
|
||||||
|
from dcs import Point
|
||||||
|
|
||||||
|
from game import Game
|
||||||
|
from game.data.building_data import FORTIFICATION_BUILDINGS
|
||||||
|
from game.db import PRICES, unit_type_of
|
||||||
|
from qt_ui.uiconstants import EVENT_ICONS
|
||||||
|
from qt_ui.widgets.QBudgetBox import QBudgetBox
|
||||||
|
from qt_ui.windows.GameUpdateSignal import GameUpdateSignal
|
||||||
|
from qt_ui.windows.groundobject.QBuildingInfo import QBuildingInfo
|
||||||
|
from theater import ControlPoint, TheaterGroundObject
|
||||||
|
|
||||||
|
|
||||||
|
class QGroundObjectMenu(QDialog):
|
||||||
|
|
||||||
|
def __init__(self, parent, ground_object: TheaterGroundObject, buildings:[], cp: ControlPoint, game: Game):
|
||||||
|
super(QGroundObjectMenu, self).__init__(parent)
|
||||||
|
self.setMinimumWidth(350)
|
||||||
|
self.ground_object = ground_object
|
||||||
|
self.buildings = buildings
|
||||||
|
self.cp = cp
|
||||||
|
self.game = game
|
||||||
|
self.setWindowTitle("Location " + self.ground_object.obj_name)
|
||||||
|
self.setWindowIcon(EVENT_ICONS["capture"])
|
||||||
|
self.intelBox = QGroupBox("Units :")
|
||||||
|
self.buildingBox = QGroupBox("Buildings :")
|
||||||
|
self.intelLayout = QGridLayout()
|
||||||
|
self.buildingsLayout = QGridLayout()
|
||||||
|
self.init_ui()
|
||||||
|
|
||||||
|
def init_ui(self):
|
||||||
|
|
||||||
|
self.mainLayout = QVBoxLayout()
|
||||||
|
self.budget = QBudgetBox(self.game)
|
||||||
|
self.budget.setGame(self.game)
|
||||||
|
|
||||||
|
self.doLayout()
|
||||||
|
|
||||||
|
if len(self.ground_object.groups) > 0:
|
||||||
|
self.mainLayout.addWidget(self.intelBox)
|
||||||
|
else:
|
||||||
|
self.mainLayout.addWidget(self.buildingBox)
|
||||||
|
self.setLayout(self.mainLayout)
|
||||||
|
|
||||||
|
def doLayout(self):
|
||||||
|
self.intelBox = QGroupBox("Units :")
|
||||||
|
self.intelLayout = QGridLayout()
|
||||||
|
i = 0
|
||||||
|
for g in self.ground_object.groups:
|
||||||
|
if not hasattr(g, "units_losts"):
|
||||||
|
g.units_losts = []
|
||||||
|
for u in g.units:
|
||||||
|
self.intelLayout.addWidget(QLabel("<b>Unit #" + str(u.id) + " - " + str(u.type) + "</b>"), i, 0)
|
||||||
|
i = i + 1
|
||||||
|
|
||||||
|
for u in g.units_losts:
|
||||||
|
|
||||||
|
utype = unit_type_of(u)
|
||||||
|
if utype in PRICES:
|
||||||
|
price = PRICES[utype]
|
||||||
|
else:
|
||||||
|
price = 6
|
||||||
|
|
||||||
|
self.intelLayout.addWidget(QLabel("<b>Unit #" + str(u.id) + " - " + str(u.type) + "</b> [DEAD]"), i, 0)
|
||||||
|
if self.cp.captured:
|
||||||
|
repair = QPushButton("Repair [" + str(price) + "M]")
|
||||||
|
repair.setProperty("style", "btn-success")
|
||||||
|
repair.clicked.connect(lambda u=u, g=g, p=price: self.repair_unit(g, u, p))
|
||||||
|
self.intelLayout.addWidget(repair, i, 1)
|
||||||
|
i = i + 1
|
||||||
|
|
||||||
|
self.buildingBox = QGroupBox("Buildings :")
|
||||||
|
self.buildingsLayout = QGridLayout()
|
||||||
|
j = 0
|
||||||
|
for i, building in enumerate(self.buildings):
|
||||||
|
if building.dcs_identifier not in FORTIFICATION_BUILDINGS:
|
||||||
|
self.buildingsLayout.addWidget(QBuildingInfo(building, self.ground_object), j/3, j%3)
|
||||||
|
j = j + 1
|
||||||
|
|
||||||
|
self.buildingBox.setLayout(self.buildingsLayout)
|
||||||
|
self.intelBox.setLayout(self.intelLayout)
|
||||||
|
|
||||||
|
def do_refresh_layout(self):
|
||||||
|
try:
|
||||||
|
for i in range(self.mainLayout.count()):
|
||||||
|
self.mainLayout.removeItem(self.mainLayout.itemAt(i))
|
||||||
|
self.doLayout()
|
||||||
|
if len(self.ground_object.groups) > 0:
|
||||||
|
self.mainLayout.addWidget(self.intelBox)
|
||||||
|
else:
|
||||||
|
self.mainLayout.addWidget(self.buildingBox)
|
||||||
|
except Exception as e:
|
||||||
|
print(e)
|
||||||
|
|
||||||
|
def repair_unit(self, group, unit, price):
|
||||||
|
if self.game.budget > price:
|
||||||
|
self.game.budget -= price
|
||||||
|
group.units_losts = [u for u in group.units_losts if u.id != unit.id]
|
||||||
|
group.units.append(unit)
|
||||||
|
GameUpdateSignal.get_instance().updateGame(self.game)
|
||||||
|
|
||||||
|
# Remove destroyed units in the vicinity
|
||||||
|
destroyed_units = self.game.get_destroyed_units()
|
||||||
|
for d in destroyed_units:
|
||||||
|
p = Point(d["x"], d["z"])
|
||||||
|
if p.distance_to_point(unit.position) < 15:
|
||||||
|
destroyed_units.remove(d)
|
||||||
|
logging.info("Removed destroyed units " + str(d))
|
||||||
|
logging.info("Repaired unit : " + str(unit.id) + " " + str(unit.type))
|
||||||
|
|
||||||
|
self.do_refresh_layout()
|
||||||
|
|
||||||
|
def closeEvent(self, closeEvent: QCloseEvent):
|
||||||
|
GameUpdateSignal.get_instance().updateGame(self.game)
|
||||||
@@ -98,6 +98,7 @@ class QMissionPlanning(QDialog):
|
|||||||
self.planned_flight_view.repaint()
|
self.planned_flight_view.repaint()
|
||||||
|
|
||||||
if self.flight_planner is not None:
|
if self.flight_planner is not None:
|
||||||
|
self.flight_planner.on_planned_flight_changed.disconnect()
|
||||||
self.flight_planner.clearTabs()
|
self.flight_planner.clearTabs()
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ class QPlannedFlightsView(QListView):
|
|||||||
self.flightitems[i].update(f)
|
self.flightitems[i].update(f)
|
||||||
|
|
||||||
def setup_content(self, row=0):
|
def setup_content(self, row=0):
|
||||||
|
self.flightitems = []
|
||||||
for i, f in enumerate(self.flight_planner.flights):
|
for i, f in enumerate(self.flight_planner.flights):
|
||||||
item = QFlightItem(f)
|
item = QFlightItem(f)
|
||||||
self.model.appendRow(item)
|
self.model.appendRow(item)
|
||||||
|
|||||||
@@ -24,7 +24,11 @@ class QLoadoutEditor(QGroupBox):
|
|||||||
label = QLabel("<b>{}</b>".format(pylon.__name__[len("Pylon"):]))
|
label = QLabel("<b>{}</b>".format(pylon.__name__[len("Pylon"):]))
|
||||||
label.setSizePolicy(QSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed))
|
label.setSizePolicy(QSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed))
|
||||||
layout.addWidget(label, i, 0)
|
layout.addWidget(label, i, 0)
|
||||||
layout.addWidget(QPylonEditor(flight, pylon, i+1), i, 1)
|
try:
|
||||||
|
pylon_number = int(pylon.__name__.split("Pylon")[1])
|
||||||
|
except:
|
||||||
|
pylon_number = i+1
|
||||||
|
layout.addWidget(QPylonEditor(flight, pylon, pylon_number), i, 1)
|
||||||
|
|
||||||
hboxLayout.addLayout(layout)
|
hboxLayout.addLayout(layout)
|
||||||
hboxLayout.addStretch()
|
hboxLayout.addStretch()
|
||||||
|
|||||||
72
qt_ui/windows/newgame/QCampaignList.py
Normal file
@@ -0,0 +1,72 @@
|
|||||||
|
from PySide2 import QtGui
|
||||||
|
from PySide2.QtCore import QSize, QItemSelectionModel
|
||||||
|
from PySide2.QtGui import QStandardItemModel, QStandardItem
|
||||||
|
from PySide2.QtWidgets import QListView, QAbstractItemView
|
||||||
|
|
||||||
|
from theater import caucasus, nevada, persiangulf, normandy, thechannel, syria
|
||||||
|
import qt_ui.uiconstants as CONST
|
||||||
|
|
||||||
|
CAMPAIGNS = [
|
||||||
|
("Caucasus - Western Georgia", caucasus.WesternGeorgia, "Terrain_Caucasus"),
|
||||||
|
("Caucasus - Russia Small", caucasus.RussiaSmall, "Terrain_Caucasus"),
|
||||||
|
("Caucasus - North Caucasus", caucasus.NorthCaucasus, "Terrain_Caucasus"),
|
||||||
|
("Caucasus - Full Map", caucasus.CaucasusTheater, "Terrain_Caucasus"),
|
||||||
|
("Nevada - North Nevada", nevada.NevadaTheater, "Terrain_Nevada"),
|
||||||
|
("Persian Gulf - Invasion of Iran", persiangulf.IranianCampaign, "Terrain_Persian_Gulf"),
|
||||||
|
("Persian Gulf - Invasion of Iran [Lite]", persiangulf.IranInvasionLite, "Terrain_Persian_Gulf"),
|
||||||
|
("Persian Gulf - Emirates", persiangulf.Emirates, "Terrain_Persian_Gulf"),
|
||||||
|
("Persian Gulf - Desert War", persiangulf.DesertWar, "Terrain_Persian_Gulf"),
|
||||||
|
("Persian Gulf - Full Map", persiangulf.PersianGulfTheater, "Terrain_Persian_Gulf"),
|
||||||
|
|
||||||
|
("Syria - Golan heights battle", syria.GolanHeights, "Terrain_Syria"),
|
||||||
|
("Syria - Invasion from Turkey", syria.TurkishInvasion, "Terrain_Syria"),
|
||||||
|
("Syria - Syrian Civil War", syria.SyrianCivilWar, "Terrain_Syria"),
|
||||||
|
("Syria - Inherent Resolve", syria.InherentResolve, "Terrain_Syria"),
|
||||||
|
("Syria - Full Map", syria.SyriaFullMap, "Terrain_Syria"),
|
||||||
|
|
||||||
|
("Normandy - Normandy", normandy.NormandyTheater, "Terrain_Normandy"),
|
||||||
|
("Normandy - Normandy Small", normandy.NormandySmall, "Terrain_Normandy"),
|
||||||
|
("The Channel - Battle of Britain", thechannel.BattleOfBritain, "Terrain_Channel"),
|
||||||
|
("The Channel - Dunkirk", thechannel.Dunkirk, "Terrain_Channel"),
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
|
class QCampaignItem(QStandardItem):
|
||||||
|
|
||||||
|
def __init__(self, text, theater, icon):
|
||||||
|
super(QCampaignItem, self).__init__()
|
||||||
|
self.theater = theater
|
||||||
|
self.setIcon(QtGui.QIcon(CONST.ICONS[icon]))
|
||||||
|
self.setEditable(False)
|
||||||
|
self.setText(text)
|
||||||
|
|
||||||
|
class QCampaignList(QListView):
|
||||||
|
|
||||||
|
def __init__(self):
|
||||||
|
super(QCampaignList, self).__init__()
|
||||||
|
self.model = QStandardItemModel(self)
|
||||||
|
self.setModel(self.model)
|
||||||
|
self.setMinimumWidth(250)
|
||||||
|
self.setMinimumHeight(350)
|
||||||
|
self.campaigns = []
|
||||||
|
self.setSelectionBehavior(QAbstractItemView.SelectItems)
|
||||||
|
self.setup_content()
|
||||||
|
|
||||||
|
def setup_content(self):
|
||||||
|
for i, campaign in enumerate(CAMPAIGNS):
|
||||||
|
self.campaigns.append(campaign)
|
||||||
|
item = QCampaignItem(*campaign)
|
||||||
|
self.model.appendRow(item)
|
||||||
|
self.setSelectedCampaign(0)
|
||||||
|
self.repaint()
|
||||||
|
|
||||||
|
def setSelectedCampaign(self, row):
|
||||||
|
self.selectionModel().clearSelection()
|
||||||
|
index = self.model.index(row, 0)
|
||||||
|
if not index.isValid():
|
||||||
|
index = self.model.index(0, 0)
|
||||||
|
self.selectionModel().setCurrentIndex(index, QItemSelectionModel.Select)
|
||||||
|
self.repaint()
|
||||||
|
|
||||||
|
def clear_layout(self):
|
||||||
|
self.model.removeRows(0, self.model.rowCount())
|
||||||
@@ -1,8 +1,10 @@
|
|||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
import datetime
|
import datetime
|
||||||
|
import logging
|
||||||
|
|
||||||
from PySide2 import QtGui, QtWidgets
|
from PySide2 import QtGui, QtWidgets
|
||||||
|
from PySide2.QtCore import QPoint, QItemSelectionModel
|
||||||
from PySide2.QtWidgets import QHBoxLayout, QVBoxLayout
|
from PySide2.QtWidgets import QHBoxLayout, QVBoxLayout
|
||||||
from dcs.task import CAP, CAS
|
from dcs.task import CAP, CAS
|
||||||
|
|
||||||
@@ -10,6 +12,7 @@ import qt_ui.uiconstants as CONST
|
|||||||
from game import db, Game
|
from game import db, Game
|
||||||
from game.settings import Settings
|
from game.settings import Settings
|
||||||
from gen import namegen
|
from gen import namegen
|
||||||
|
from qt_ui.windows.newgame.QCampaignList import QCampaignList
|
||||||
from theater import start_generator, persiangulf, nevada, caucasus, ConflictTheater, normandy, thechannel
|
from theater import start_generator, persiangulf, nevada, caucasus, ConflictTheater, normandy, thechannel
|
||||||
|
|
||||||
|
|
||||||
@@ -32,19 +35,15 @@ class NewGameWizard(QtWidgets.QWizard):
|
|||||||
|
|
||||||
def accept(self):
|
def accept(self):
|
||||||
|
|
||||||
|
logging.info("New Game Wizard accept")
|
||||||
|
logging.info("======================")
|
||||||
|
|
||||||
blueFaction = [c for c in db.FACTIONS][self.field("blueFaction")]
|
blueFaction = [c for c in db.FACTIONS][self.field("blueFaction")]
|
||||||
redFaction = [c for c in db.FACTIONS][self.field("redFaction")]
|
redFaction = [c for c in db.FACTIONS][self.field("redFaction")]
|
||||||
isTerrainPg = self.field("isTerrainPg")
|
|
||||||
isTerrainNttr = self.field("isTerrainNttr")
|
selectedCampaign = self.field("selectedCampaign")
|
||||||
isTerrainCaucasusSmall = self.field("isTerrainCaucasusSmall")
|
conflictTheater = selectedCampaign[1]()
|
||||||
isTerrainRussia = self.field("isTerrainRussia")
|
|
||||||
isTerrainCaucasusNorth= self.field("isTerrainCaucasusNorth")
|
|
||||||
isIranianCampaignTheater = self.field("isIranianCampaignTheater")
|
|
||||||
isTerrainNormandy = self.field("isTerrainNormandy")
|
|
||||||
isTerrainNormandySmall = self.field("isTerrainNormandySmall")
|
|
||||||
isTerrainChannel = self.field("isTerrainChannel")
|
|
||||||
isTerrainChannelComplete = self.field("isTerrainChannelComplete")
|
|
||||||
isTerrainEmirates = self.field("isTerrainEmirates")
|
|
||||||
timePeriod = db.TIME_PERIODS[list(db.TIME_PERIODS.keys())[self.field("timePeriod")]]
|
timePeriod = db.TIME_PERIODS[list(db.TIME_PERIODS.keys())[self.field("timePeriod")]]
|
||||||
midGame = self.field("midGame")
|
midGame = self.field("midGame")
|
||||||
multiplier = self.field("multiplier")
|
multiplier = self.field("multiplier")
|
||||||
@@ -58,31 +57,6 @@ class NewGameWizard(QtWidgets.QWizard):
|
|||||||
player_name = blueFaction
|
player_name = blueFaction
|
||||||
enemy_name = redFaction
|
enemy_name = redFaction
|
||||||
|
|
||||||
if isTerrainPg:
|
|
||||||
conflicttheater = persiangulf.PersianGulfTheater()
|
|
||||||
elif isTerrainNttr:
|
|
||||||
conflicttheater = nevada.NevadaTheater()
|
|
||||||
elif isTerrainCaucasusSmall:
|
|
||||||
conflicttheater = caucasus.WesternGeorgia()
|
|
||||||
elif isTerrainRussia:
|
|
||||||
conflicttheater = caucasus.RussiaSmall()
|
|
||||||
elif isTerrainCaucasusNorth:
|
|
||||||
conflicttheater = caucasus.NorthCaucasus()
|
|
||||||
elif isIranianCampaignTheater:
|
|
||||||
conflicttheater = persiangulf.IranianCampaign()
|
|
||||||
elif isTerrainEmirates:
|
|
||||||
conflicttheater = persiangulf.Emirates()
|
|
||||||
elif isTerrainNormandy:
|
|
||||||
conflicttheater = normandy.NormandyTheater()
|
|
||||||
elif isTerrainNormandySmall:
|
|
||||||
conflicttheater = normandy.NormandySmall()
|
|
||||||
elif isTerrainChannel:
|
|
||||||
conflicttheater = thechannel.ChannelTheater()
|
|
||||||
elif isTerrainChannelComplete:
|
|
||||||
conflicttheater = thechannel.ChannelTheaterComplete()
|
|
||||||
else:
|
|
||||||
conflicttheater = caucasus.CaucasusTheater()
|
|
||||||
|
|
||||||
settings = Settings()
|
settings = Settings()
|
||||||
settings.inverted = invertMap
|
settings.inverted = invertMap
|
||||||
settings.supercarrier = supercarrier
|
settings.supercarrier = supercarrier
|
||||||
@@ -91,40 +65,40 @@ class NewGameWizard(QtWidgets.QWizard):
|
|||||||
settings.do_not_generate_player_navy = no_player_navy
|
settings.do_not_generate_player_navy = no_player_navy
|
||||||
settings.do_not_generate_enemy_navy = no_enemy_navy
|
settings.do_not_generate_enemy_navy = no_enemy_navy
|
||||||
|
|
||||||
self.generatedGame = self.start_new_game(player_name, enemy_name, conflicttheater, midGame, multiplier,
|
self.generatedGame = self.start_new_game(player_name, enemy_name, conflictTheater, midGame, multiplier,
|
||||||
timePeriod, settings)
|
timePeriod, settings)
|
||||||
|
|
||||||
super(NewGameWizard, self).accept()
|
super(NewGameWizard, self).accept()
|
||||||
|
|
||||||
def start_new_game(self, player_name: str, enemy_name: str, conflicttheater: ConflictTheater,
|
def start_new_game(self, player_name: str, enemy_name: str, conflictTheater: ConflictTheater,
|
||||||
midgame: bool, multiplier: float, period: datetime, settings:Settings):
|
midgame: bool, multiplier: float, period: datetime, settings:Settings):
|
||||||
|
|
||||||
# Reset name generator
|
# Reset name generator
|
||||||
namegen.reset()
|
namegen.reset()
|
||||||
start_generator.prepare_theater(conflicttheater, settings, midgame)
|
start_generator.prepare_theater(conflictTheater, settings, midgame)
|
||||||
|
|
||||||
print("-- Starting New Game Generator")
|
print("-- Starting New Game Generator")
|
||||||
print("Enemy name : " + enemy_name)
|
print("Enemy name : " + enemy_name)
|
||||||
print("Player name : " + player_name)
|
print("Player name : " + player_name)
|
||||||
print("Midgame : " + str(midgame))
|
print("Midgame : " + str(midgame))
|
||||||
start_generator.generate_inital_units(conflicttheater, enemy_name, True, multiplier)
|
start_generator.generate_inital_units(conflictTheater, enemy_name, True, multiplier)
|
||||||
|
|
||||||
print("-- Initial units generated")
|
print("-- Initial units generated")
|
||||||
game = Game(player_name=player_name,
|
game = Game(player_name=player_name,
|
||||||
enemy_name=enemy_name,
|
enemy_name=enemy_name,
|
||||||
theater=conflicttheater,
|
theater=conflictTheater,
|
||||||
start_date=period,
|
start_date=period,
|
||||||
settings=settings)
|
settings=settings)
|
||||||
|
|
||||||
print("-- Game Object generated")
|
print("-- Game Object generated")
|
||||||
start_generator.generate_groundobjects(conflicttheater, game)
|
start_generator.generate_groundobjects(conflictTheater, game)
|
||||||
game.budget = int(game.budget * multiplier)
|
game.budget = int(game.budget * multiplier)
|
||||||
game.settings.multiplier = multiplier
|
game.settings.multiplier = multiplier
|
||||||
game.settings.sams = True
|
game.settings.sams = True
|
||||||
game.settings.version = "2.0.10"
|
game.settings.version = CONST.VERSION_STRING
|
||||||
|
|
||||||
if midgame:
|
if midgame:
|
||||||
game.budget = game.budget * 4 * len(list(conflicttheater.conflicts()))
|
game.budget = game.budget * 4 * len(list(conflictTheater.conflicts()))
|
||||||
|
|
||||||
return game
|
return game
|
||||||
|
|
||||||
@@ -295,6 +269,21 @@ class TheaterConfiguration(QtWidgets.QWizardPage):
|
|||||||
terrainChannelComplete.setIcon(QtGui.QIcon(CONST.ICONS["Terrain_Channel"]))
|
terrainChannelComplete.setIcon(QtGui.QIcon(CONST.ICONS["Terrain_Channel"]))
|
||||||
terrainCaucasusSmall.setChecked(True)
|
terrainCaucasusSmall.setChecked(True)
|
||||||
|
|
||||||
|
# List of campaigns
|
||||||
|
campaignList = QCampaignList()
|
||||||
|
self.registerField("selectedCampaign", campaignList)
|
||||||
|
|
||||||
|
def on_campaign_selected():
|
||||||
|
index = campaignList.selectionModel().currentIndex().row()
|
||||||
|
campaign = campaignList.campaigns[index]
|
||||||
|
self.setField("selectedCampaign", campaign)
|
||||||
|
|
||||||
|
campaignList.selectionModel().setCurrentIndex(campaignList.indexAt(QPoint(1, 1)), QItemSelectionModel.Rows)
|
||||||
|
campaignList.selectionModel().selectionChanged.connect(on_campaign_selected)
|
||||||
|
on_campaign_selected()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Campaign settings
|
# Campaign settings
|
||||||
mapSettingsGroup = QtWidgets.QGroupBox("Map Settings")
|
mapSettingsGroup = QtWidgets.QGroupBox("Map Settings")
|
||||||
invertMap = QtWidgets.QCheckBox()
|
invertMap = QtWidgets.QCheckBox()
|
||||||
@@ -314,35 +303,8 @@ class TheaterConfiguration(QtWidgets.QWizardPage):
|
|||||||
timePeriodSelect.setCurrentIndex(21)
|
timePeriodSelect.setCurrentIndex(21)
|
||||||
|
|
||||||
# Register fields
|
# Register fields
|
||||||
self.registerField('isTerrainCaucasus', terrainCaucasus)
|
|
||||||
self.registerField('isTerrainCaucasusSmall', terrainCaucasusSmall)
|
|
||||||
self.registerField('isTerrainRussia', terrainRussia)
|
|
||||||
self.registerField('isTerrainCaucasusNorth', terrainCaucasusNorth)
|
|
||||||
self.registerField('isTerrainPg', terrainPg)
|
|
||||||
self.registerField('isIranianCampaignTheater', terrainIran)
|
|
||||||
self.registerField('isTerrainEmirates', terrainEmirates)
|
|
||||||
self.registerField('isTerrainNttr', terrainNttr)
|
|
||||||
self.registerField('isTerrainNormandy', terrainNormandy)
|
|
||||||
self.registerField('isTerrainNormandySmall', terrainNormandySmall)
|
|
||||||
self.registerField('isTerrainChannel', terrainChannel)
|
|
||||||
self.registerField('isTerrainChannelComplete', terrainChannelComplete)
|
|
||||||
self.registerField('timePeriod', timePeriodSelect)
|
self.registerField('timePeriod', timePeriodSelect)
|
||||||
|
self.registerField('timePeriod', timePeriodSelect)
|
||||||
# Build layout
|
|
||||||
terrainGroupLayout = QtWidgets.QVBoxLayout()
|
|
||||||
terrainGroupLayout.addWidget(terrainCaucasusSmall)
|
|
||||||
terrainGroupLayout.addWidget(terrainRussia)
|
|
||||||
terrainGroupLayout.addWidget(terrainCaucasusNorth)
|
|
||||||
terrainGroupLayout.addWidget(terrainCaucasus)
|
|
||||||
terrainGroupLayout.addWidget(terrainIran)
|
|
||||||
terrainGroupLayout.addWidget(terrainEmirates)
|
|
||||||
terrainGroupLayout.addWidget(terrainPg)
|
|
||||||
terrainGroupLayout.addWidget(terrainNttr)
|
|
||||||
terrainGroupLayout.addWidget(terrainNormandy)
|
|
||||||
terrainGroupLayout.addWidget(terrainNormandySmall)
|
|
||||||
terrainGroupLayout.addWidget(terrainChannelComplete)
|
|
||||||
terrainGroupLayout.addWidget(terrainChannel)
|
|
||||||
terrainGroup.setLayout(terrainGroupLayout)
|
|
||||||
|
|
||||||
timeGroupLayout = QtWidgets.QGridLayout()
|
timeGroupLayout = QtWidgets.QGridLayout()
|
||||||
timeGroupLayout.addWidget(timePeriod, 0, 0)
|
timeGroupLayout.addWidget(timePeriod, 0, 0)
|
||||||
@@ -351,7 +313,7 @@ class TheaterConfiguration(QtWidgets.QWizardPage):
|
|||||||
|
|
||||||
layout = QtWidgets.QGridLayout()
|
layout = QtWidgets.QGridLayout()
|
||||||
layout.setColumnMinimumWidth(0, 20)
|
layout.setColumnMinimumWidth(0, 20)
|
||||||
layout.addWidget(terrainGroup, 0, 0, 3, 1)
|
layout.addWidget(campaignList, 0, 0, 3, 1)
|
||||||
layout.addWidget(mapSettingsGroup, 0, 1, 1, 1)
|
layout.addWidget(mapSettingsGroup, 0, 1, 1, 1)
|
||||||
layout.addWidget(timeGroup, 1, 1, 1, 1)
|
layout.addWidget(timeGroup, 1, 1, 1, 1)
|
||||||
self.setLayout(layout)
|
self.setLayout(layout)
|
||||||
@@ -1,3 +1,5 @@
|
|||||||
|
import logging
|
||||||
|
|
||||||
from PySide2.QtCore import QSize, Qt, QItemSelectionModel, QPoint
|
from PySide2.QtCore import QSize, Qt, QItemSelectionModel, QPoint
|
||||||
from PySide2.QtGui import QStandardItemModel, QStandardItem
|
from PySide2.QtGui import QStandardItemModel, QStandardItem
|
||||||
from PySide2.QtWidgets import QLabel, QDialog, QGridLayout, QListView, QStackedLayout, QComboBox, QWidget, \
|
from PySide2.QtWidgets import QLabel, QDialog, QGridLayout, QListView, QStackedLayout, QComboBox, QWidget, \
|
||||||
@@ -269,32 +271,28 @@ class QSettingsWindow(QDialog):
|
|||||||
self.moneyCheatBoxLayout = QGridLayout()
|
self.moneyCheatBoxLayout = QGridLayout()
|
||||||
self.moneyCheatBox.setLayout(self.moneyCheatBoxLayout)
|
self.moneyCheatBox.setLayout(self.moneyCheatBoxLayout)
|
||||||
|
|
||||||
self.cheat25M = QPushButton("Cheat +25M")
|
cheats_amounts = [25, 50, 100, 200, 500, 1000, -25, -50, -100, -200]
|
||||||
self.cheat50M = QPushButton("Cheat +50M")
|
for i, amount in enumerate(cheats_amounts):
|
||||||
self.cheat100M = QPushButton("Cheat +100M")
|
if amount > 0:
|
||||||
self.cheat200M = QPushButton("Cheat +200M")
|
btn = QPushButton("Cheat +" + str(amount) + "M")
|
||||||
self.cheat500M = QPushButton("Cheat +500M")
|
btn.setProperty("style", "btn-success")
|
||||||
self.cheat1000M = QPushButton("Cheat +1000M")
|
else:
|
||||||
|
btn = QPushButton("Cheat " + str(amount) + "M")
|
||||||
self.cheat25M.clicked.connect(lambda: self.cheatMoney(25))
|
btn.setProperty("style", "btn-danger")
|
||||||
self.cheat50M.clicked.connect(lambda: self.cheatMoney(50))
|
btn.clicked.connect(self.cheatLambda(amount))
|
||||||
self.cheat100M.clicked.connect(lambda: self.cheatMoney(100))
|
self.moneyCheatBoxLayout.addWidget(btn, i/2, i%2)
|
||||||
self.cheat200M.clicked.connect(lambda: self.cheatMoney(200))
|
|
||||||
self.cheat500M.clicked.connect(lambda: self.cheatMoney(500))
|
|
||||||
self.cheat1000M.clicked.connect(lambda: self.cheatMoney(1000))
|
|
||||||
|
|
||||||
self.moneyCheatBoxLayout.addWidget(self.cheat25M, 0, 0)
|
|
||||||
self.moneyCheatBoxLayout.addWidget(self.cheat50M, 0, 1)
|
|
||||||
self.moneyCheatBoxLayout.addWidget(self.cheat100M, 1, 0)
|
|
||||||
self.moneyCheatBoxLayout.addWidget(self.cheat200M, 1, 1)
|
|
||||||
self.moneyCheatBoxLayout.addWidget(self.cheat500M, 2, 0)
|
|
||||||
self.moneyCheatBoxLayout.addWidget(self.cheat1000M, 2, 1)
|
|
||||||
|
|
||||||
self.cheatLayout.addWidget(self.moneyCheatBox, 0, 0)
|
self.cheatLayout.addWidget(self.moneyCheatBox, 0, 0)
|
||||||
|
|
||||||
|
def cheatLambda(self, amount):
|
||||||
|
return lambda: self.cheatMoney(amount)
|
||||||
|
|
||||||
def cheatMoney(self, amount):
|
def cheatMoney(self, amount):
|
||||||
|
logging.info("CHEATING FOR AMOUNT : " + str(amount) + "M")
|
||||||
self.game.budget += amount
|
self.game.budget += amount
|
||||||
self.game.informations.append(Information("CHEATER", "You are a cheater and you should feel bad", self.game.turn))
|
if amount > 0:
|
||||||
|
self.game.informations.append(Information("CHEATER", "You are a cheater and you should feel bad", self.game.turn))
|
||||||
|
else:
|
||||||
|
self.game.informations.append(Information("CHEATER", "You are still a cheater !", self.game.turn))
|
||||||
GameUpdateSignal.get_instance().updateGame(self.game)
|
GameUpdateSignal.get_instance().updateGame(self.game)
|
||||||
|
|
||||||
def applySettings(self):
|
def applySettings(self):
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
pydcs>=0.9.9
|
#pydcs>=0.9.10
|
||||||
Pyside2>=5.13.0
|
Pyside2>=5.13.0
|
||||||
pyinstaller==3.6
|
pyinstaller==3.6
|
||||||
pyproj==2.6.1.post1
|
pyproj==2.6.1.post1
|
||||||
|
|||||||
69
resources/customized_payloads/AH-1W.lua
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
local unitPayloads = {
|
||||||
|
["name"] = "AH-1W",
|
||||||
|
["payloads"] = {
|
||||||
|
[1] = {
|
||||||
|
["name"] = "CAS",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["name"] = "STRIKE",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "M260_HYDRA",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "M260_HYDRA",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "M260_HYDRA",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "M260_HYDRA",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["name"] = "ANTISHIP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["unitType"] = "AH-1W",
|
||||||
|
}
|
||||||
|
return unitPayloads
|
||||||
118
resources/customized_payloads/AH-64A.lua
Normal file
@@ -0,0 +1,118 @@
|
|||||||
|
local unitPayloads = {
|
||||||
|
["name"] = "AH-64A",
|
||||||
|
["payloads"] = {
|
||||||
|
[1] = {
|
||||||
|
["name"] = "CAS",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{FD90A1DC-9147-49FA-BF56-CB83EF0BD32B}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{FD90A1DC-9147-49FA-BF56-CB83EF0BD32B}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["name"] = "STRIKE",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["name"] = "CAP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["name"] = "ANTISHIP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["name"] = "SEAD",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["unitType"] = "AH-64A",
|
||||||
|
}
|
||||||
|
return unitPayloads
|
||||||
110
resources/customized_payloads/AH-64D.lua
Normal file
@@ -0,0 +1,110 @@
|
|||||||
|
local unitPayloads = {
|
||||||
|
["name"] = "AH-64D",
|
||||||
|
["payloads"] = {
|
||||||
|
[1] = {
|
||||||
|
["name"] = "CAS",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["name"] = "CAP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["name"] = "ANTISHIP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["name"] = "SEAD",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["name"] = "STRIKE",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 18,
|
||||||
|
[2] = 31,
|
||||||
|
[3] = 32,
|
||||||
|
[4] = 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["unitType"] = "AH-64D",
|
||||||
|
}
|
||||||
|
return unitPayloads
|
||||||
219
resources/customized_payloads/F-16A.lua
Normal file
@@ -0,0 +1,219 @@
|
|||||||
|
local unitPayloads = {
|
||||||
|
["name"] = "F-16A",
|
||||||
|
["payloads"] = {
|
||||||
|
[1] = {
|
||||||
|
["name"] = "CAP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{6D21ECEA-F85B-4E8D-9D51-31DC9B8AA4EF}",
|
||||||
|
["num"] = 6,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{8D399DDA-FF81-4F14-904D-099B34FE7918}",
|
||||||
|
["num"] = 8,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{8D399DDA-FF81-4F14-904D-099B34FE7918}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 9,
|
||||||
|
},
|
||||||
|
[6] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[7] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 10,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["name"] = "CAS",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{6D21ECEA-F85B-4E8D-9D51-31DC9B8AA4EF}",
|
||||||
|
["num"] = 6,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{E6A6262A-CA08-4B3D-B030-E1A993B98453}",
|
||||||
|
["num"] = 8,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{E6A6262A-CA08-4B3D-B030-E1A993B98452}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 9,
|
||||||
|
},
|
||||||
|
[6] = {
|
||||||
|
["CLSID"] = "{AIS_ASQ_T50}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[7] = {
|
||||||
|
["CLSID"] = "{AIS_ASQ_T50}",
|
||||||
|
["num"] = 10,
|
||||||
|
},
|
||||||
|
[8] = {
|
||||||
|
["CLSID"] = "{444BA8AE-82A7-4345-842E-76154EFCCA46}",
|
||||||
|
["num"] = 7,
|
||||||
|
},
|
||||||
|
[9] = {
|
||||||
|
["CLSID"] = "{444BA8AE-82A7-4345-842E-76154EFCCA46}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["name"] = "STRIKE",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{6D21ECEA-F85B-4E8D-9D51-31DC9B8AA4EF}",
|
||||||
|
["num"] = 6,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{BCE4E030-38E9-423E-98ED-24BE3DA87C32}",
|
||||||
|
["num"] = 8,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{BCE4E030-38E9-423E-98ED-24BE3DA87C32}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 9,
|
||||||
|
},
|
||||||
|
[6] = {
|
||||||
|
["CLSID"] = "{AIS_ASQ_T50}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[7] = {
|
||||||
|
["CLSID"] = "{AIS_ASQ_T50}",
|
||||||
|
["num"] = 10,
|
||||||
|
},
|
||||||
|
[8] = {
|
||||||
|
["CLSID"] = "{BCE4E030-38E9-423E-98ED-24BE3DA87C32}",
|
||||||
|
["num"] = 7,
|
||||||
|
},
|
||||||
|
[9] = {
|
||||||
|
["CLSID"] = "{BCE4E030-38E9-423E-98ED-24BE3DA87C32}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["name"] = "ANTISHIP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{6D21ECEA-F85B-4E8D-9D51-31DC9B8AA4EF}",
|
||||||
|
["num"] = 6,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{7B8DCEB4-820B-4015-9B48-1028A4195692}",
|
||||||
|
["num"] = 8,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{7B8DCEB4-820B-4015-9B48-1028A4195692}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 9,
|
||||||
|
},
|
||||||
|
[6] = {
|
||||||
|
["CLSID"] = "{AIS_ASQ_T50}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[7] = {
|
||||||
|
["CLSID"] = "{AIS_ASQ_T50}",
|
||||||
|
["num"] = 10,
|
||||||
|
},
|
||||||
|
[8] = {
|
||||||
|
["CLSID"] = "{444BA8AE-82A7-4345-842E-76154EFCCA46}",
|
||||||
|
["num"] = 7,
|
||||||
|
},
|
||||||
|
[9] = {
|
||||||
|
["CLSID"] = "{444BA8AE-82A7-4345-842E-76154EFCCA46}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["name"] = "SEAD",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{6D21ECEA-F85B-4E8D-9D51-31DC9B8AA4EF}",
|
||||||
|
["num"] = 6,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{E6A6262A-CA08-4B3D-B030-E1A993B98453}",
|
||||||
|
["num"] = 8,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{444BA8AE-82A7-4345-842E-76154EFCCA46}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["CLSID"] = "{6CEB49FC-DED8-4DED-B053-E1F033FF72D3}",
|
||||||
|
["num"] = 9,
|
||||||
|
},
|
||||||
|
[6] = {
|
||||||
|
["CLSID"] = "{AIS_ASQ_T50}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[7] = {
|
||||||
|
["CLSID"] = "{AIS_ASQ_T50}",
|
||||||
|
["num"] = 10,
|
||||||
|
},
|
||||||
|
[8] = {
|
||||||
|
["CLSID"] = "{444BA8AE-82A7-4345-842E-76154EFCCA46}",
|
||||||
|
["num"] = 7,
|
||||||
|
},
|
||||||
|
[9] = {
|
||||||
|
["CLSID"] = "{444BA8AE-82A7-4345-842E-76154EFCCA46}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["unitType"] = "F-16A",
|
||||||
|
}
|
||||||
|
return unitPayloads
|
||||||
@@ -2,6 +2,49 @@ local unitPayloads = {
|
|||||||
["name"] = "F-16C_50",
|
["name"] = "F-16C_50",
|
||||||
["payloads"] = {
|
["payloads"] = {
|
||||||
[1] = {
|
[1] = {
|
||||||
|
["name"] = "ANTISHIP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "LAU3_HE5",
|
||||||
|
["num"] = 6,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "LAU3_HE5",
|
||||||
|
["num"] = 7,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "LAU3_HE5",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "LAU3_HE5",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["CLSID"] = "{40EF17B7-F508-45de-8566-6FFECC0C1AB8}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[6] = {
|
||||||
|
["CLSID"] = "{40EF17B7-F508-45de-8566-6FFECC0C1AB8}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[7] = {
|
||||||
|
["CLSID"] = "{40EF17B7-F508-45de-8566-6FFECC0C1AB8}",
|
||||||
|
["num"] = 8,
|
||||||
|
},
|
||||||
|
[8] = {
|
||||||
|
["CLSID"] = "{40EF17B7-F508-45de-8566-6FFECC0C1AB8}",
|
||||||
|
["num"] = 9,
|
||||||
|
},
|
||||||
|
[9] = {
|
||||||
|
["CLSID"] = "{8A0BE8AE-58D4-4572-9263-3144C0D06364}",
|
||||||
|
["num"] = 5,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
["name"] = "CAP",
|
["name"] = "CAP",
|
||||||
["pylons"] = {
|
["pylons"] = {
|
||||||
[1] = {
|
[1] = {
|
||||||
@@ -44,7 +87,7 @@ local unitPayloads = {
|
|||||||
["tasks"] = {
|
["tasks"] = {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
[2] = {
|
[3] = {
|
||||||
["name"] = "CAS",
|
["name"] = "CAS",
|
||||||
["pylons"] = {
|
["pylons"] = {
|
||||||
[1] = {
|
[1] = {
|
||||||
@@ -52,11 +95,11 @@ local unitPayloads = {
|
|||||||
["num"] = 5,
|
["num"] = 5,
|
||||||
},
|
},
|
||||||
[2] = {
|
[2] = {
|
||||||
["CLSID"] = "{TER_9A_2R*MK-82}",
|
["CLSID"] = "{DB769D48-67D7-42ED-A2BE-108D566C8B1E}",
|
||||||
["num"] = 7,
|
["num"] = 7,
|
||||||
},
|
},
|
||||||
[3] = {
|
[3] = {
|
||||||
["CLSID"] = "{TER_9A_2L*CBU-97}",
|
["CLSID"] = "{DB769D48-67D7-42ED-A2BE-108D566C8B1E}",
|
||||||
["num"] = 3,
|
["num"] = 3,
|
||||||
},
|
},
|
||||||
[4] = {
|
[4] = {
|
||||||
@@ -76,14 +119,14 @@ local unitPayloads = {
|
|||||||
["num"] = 9,
|
["num"] = 9,
|
||||||
},
|
},
|
||||||
[8] = {
|
[8] = {
|
||||||
["CLSID"] = "{TER_9A_2L*CBU-97}",
|
["CLSID"] = "{5335D97A-35A5-4643-9D9B-026C75961E52}",
|
||||||
["num"] = 4,
|
["num"] = 4,
|
||||||
},
|
},
|
||||||
[9] = {
|
[9] = {
|
||||||
["CLSID"] = "{TER_9A_2R*CBU-97}",
|
["CLSID"] = "{5335D97A-35A5-4643-9D9B-026C75961E52}",
|
||||||
["num"] = 6,
|
["num"] = 6,
|
||||||
},
|
},
|
||||||
[10] = {
|
[11] = {
|
||||||
["CLSID"] = "{A111396E-D3E8-4b9c-8AC9-2432489304D5}",
|
["CLSID"] = "{A111396E-D3E8-4b9c-8AC9-2432489304D5}",
|
||||||
["num"] = 11,
|
["num"] = 11,
|
||||||
},
|
},
|
||||||
@@ -91,49 +134,6 @@ local unitPayloads = {
|
|||||||
["tasks"] = {
|
["tasks"] = {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
[3] = {
|
|
||||||
["name"] = "ANTISHIP",
|
|
||||||
["pylons"] = {
|
|
||||||
[1] = {
|
|
||||||
["CLSID"] = "LAU3_HE5",
|
|
||||||
["num"] = 6,
|
|
||||||
},
|
|
||||||
[2] = {
|
|
||||||
["CLSID"] = "LAU3_HE5",
|
|
||||||
["num"] = 7,
|
|
||||||
},
|
|
||||||
[3] = {
|
|
||||||
["CLSID"] = "LAU3_HE5",
|
|
||||||
["num"] = 4,
|
|
||||||
},
|
|
||||||
[4] = {
|
|
||||||
["CLSID"] = "LAU3_HE5",
|
|
||||||
["num"] = 3,
|
|
||||||
},
|
|
||||||
[5] = {
|
|
||||||
["CLSID"] = "{40EF17B7-F508-45de-8566-6FFECC0C1AB8}",
|
|
||||||
["num"] = 2,
|
|
||||||
},
|
|
||||||
[6] = {
|
|
||||||
["CLSID"] = "{40EF17B7-F508-45de-8566-6FFECC0C1AB8}",
|
|
||||||
["num"] = 1,
|
|
||||||
},
|
|
||||||
[7] = {
|
|
||||||
["CLSID"] = "{40EF17B7-F508-45de-8566-6FFECC0C1AB8}",
|
|
||||||
["num"] = 8,
|
|
||||||
},
|
|
||||||
[8] = {
|
|
||||||
["CLSID"] = "{40EF17B7-F508-45de-8566-6FFECC0C1AB8}",
|
|
||||||
["num"] = 9,
|
|
||||||
},
|
|
||||||
[9] = {
|
|
||||||
["CLSID"] = "{8A0BE8AE-58D4-4572-9263-3144C0D06364}",
|
|
||||||
["num"] = 5,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
["tasks"] = {
|
|
||||||
},
|
|
||||||
},
|
|
||||||
[4] = {
|
[4] = {
|
||||||
["name"] = "STRIKE",
|
["name"] = "STRIKE",
|
||||||
["pylons"] = {
|
["pylons"] = {
|
||||||
@@ -173,6 +173,10 @@ local unitPayloads = {
|
|||||||
["CLSID"] = "{8A0BE8AE-58D4-4572-9263-3144C0D06364}",
|
["CLSID"] = "{8A0BE8AE-58D4-4572-9263-3144C0D06364}",
|
||||||
["num"] = 5,
|
["num"] = 5,
|
||||||
},
|
},
|
||||||
|
[11] = {
|
||||||
|
["CLSID"] = "{A111396E-D3E8-4b9c-8AC9-2432489304D5}",
|
||||||
|
["num"] = 11,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
["tasks"] = {
|
["tasks"] = {
|
||||||
},
|
},
|
||||||
@@ -181,7 +185,7 @@ local unitPayloads = {
|
|||||||
["name"] = "SEAD",
|
["name"] = "SEAD",
|
||||||
["pylons"] = {
|
["pylons"] = {
|
||||||
[1] = {
|
[1] = {
|
||||||
["CLSID"] = "{51F9AAE5-964F-4D21-83FB-502E3BFE5F8A}",
|
["CLSID"] = "{DB769D48-67D7-42ED-A2BE-108D566C8B1E}",
|
||||||
["num"] = 6,
|
["num"] = 6,
|
||||||
},
|
},
|
||||||
[2] = {
|
[2] = {
|
||||||
|
|||||||
33
resources/customized_payloads/MQ-9 Reaper.lua
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
local unitPayloads = {
|
||||||
|
["name"] = "MQ-9 Reaper",
|
||||||
|
["payloads"] = {
|
||||||
|
[1] = {
|
||||||
|
["name"] = "CAS",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{88D18A5E-99C8-4B04-B40B-1C02F2018B6E}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "AGM114x2_OH_58",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "AGM114x2_OH_58",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 17,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
},
|
||||||
|
["unitType"] = "MQ-9 Reaper",
|
||||||
|
}
|
||||||
|
return unitPayloads
|
||||||
142
resources/customized_payloads/MiG-25PD.lua
Normal file
@@ -0,0 +1,142 @@
|
|||||||
|
local unitPayloads = {
|
||||||
|
["name"] = "MiG-25PD",
|
||||||
|
["payloads"] = {
|
||||||
|
[1] = {
|
||||||
|
["name"] = "CAP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{5F26DBC2-FB43-4153-92DE-6BBCE26CB0FF}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{5F26DBC2-FB43-4153-92DE-6BBCE26CB0FF}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
[2] = 10,
|
||||||
|
[3] = 18,
|
||||||
|
[4] = 19,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["name"] = "STRIKE",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{682A481F-0CB5-4693-A382-D00DD4A156D7}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{682A481F-0CB5-4693-A382-D00DD4A156D7}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
[2] = 10,
|
||||||
|
[3] = 18,
|
||||||
|
[4] = 19,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["name"] = "CAS",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{682A481F-0CB5-4693-A382-D00DD4A156D7}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{682A481F-0CB5-4693-A382-D00DD4A156D7}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
[2] = 10,
|
||||||
|
[3] = 18,
|
||||||
|
[4] = 19,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["name"] = "ANTISHIP",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{682A481F-0CB5-4693-A382-D00DD4A156D7}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{682A481F-0CB5-4693-A382-D00DD4A156D7}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
[2] = 10,
|
||||||
|
[3] = 18,
|
||||||
|
[4] = 19,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[5] = {
|
||||||
|
["name"] = "SEAD",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{682A481F-0CB5-4693-A382-D00DD4A156D7}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[3] = {
|
||||||
|
["CLSID"] = "{4EDBA993-2E34-444C-95FB-549300BF7CAF}",
|
||||||
|
["num"] = 3,
|
||||||
|
},
|
||||||
|
[4] = {
|
||||||
|
["CLSID"] = "{682A481F-0CB5-4693-A382-D00DD4A156D7}",
|
||||||
|
["num"] = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 11,
|
||||||
|
[2] = 10,
|
||||||
|
[3] = 18,
|
||||||
|
[4] = 19,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["unitType"] = "MiG-25PD",
|
||||||
|
}
|
||||||
|
return unitPayloads
|
||||||
23
resources/customized_payloads/RQ-1A Predator.lua
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
local unitPayloads = {
|
||||||
|
["name"] = "RQ-1A Predator",
|
||||||
|
["payloads"] = {
|
||||||
|
[1] = {
|
||||||
|
["name"] = "CAS",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "{ee368869-c35a-486a-afe7-284beb7c5d52}",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "{ee368869-c35a-486a-afe7-284beb7c5d52}",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 17,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["unitType"] = "RQ-1A Predator",
|
||||||
|
}
|
||||||
|
return unitPayloads
|
||||||
25
resources/customized_payloads/WingLoong-I.lua
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
local unitPayloads = {
|
||||||
|
["name"] = "WingLoong-I",
|
||||||
|
["payloads"] = {
|
||||||
|
[1] = {
|
||||||
|
["name"] = "CAS",
|
||||||
|
["pylons"] = {
|
||||||
|
[1] = {
|
||||||
|
["CLSID"] = "DIS_AKD-10",
|
||||||
|
["num"] = 2,
|
||||||
|
},
|
||||||
|
[2] = {
|
||||||
|
["CLSID"] = "DIS_AKD-10",
|
||||||
|
["num"] = 1,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
[1] = 17,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
["tasks"] = {
|
||||||
|
},
|
||||||
|
["unitType"] = "WingLoong-I",
|
||||||
|
}
|
||||||
|
return unitPayloads
|
||||||
@@ -34,11 +34,24 @@ write_state = function()
|
|||||||
}
|
}
|
||||||
fp:write(json:encode(game_state))
|
fp:write(json:encode(game_state))
|
||||||
fp:close()
|
fp:close()
|
||||||
--logger.info("Done writing DCS Liberation state")
|
-- logger.info("Done writing DCS Liberation state")
|
||||||
--messageAll("Done writing DCS Liberation state.")
|
-- messageAll("Done writing DCS Liberation state.")
|
||||||
end
|
end
|
||||||
|
|
||||||
mist.scheduleFunction(write_state, {}, timer.getTime() + 10, 60, timer.getTime() + 3600)
|
|
||||||
|
write_state_error_handling = function()
|
||||||
|
if pcall(write_state) then
|
||||||
|
-- messageAll("Written DCS Liberation state to "..debriefing_file_location)
|
||||||
|
else
|
||||||
|
messageAll("Unable to write DCS Liberation state to "..debriefing_file_location..
|
||||||
|
"\nYou can abort the mission in DCS Liberation.\n"..
|
||||||
|
"\n\nPlease fix your setup in DCS Liberation, make sure you are pointing to the right installation directory from the File/Preferences menu. Then after fixing the path restart DCS Liberation, and then restart DCS."..
|
||||||
|
"\n\nYou can also try to fix the issue manually by replacing the file <dcs_installation_directory>/Scripts/MissionScripting.lua by the one provided there : <dcs_liberation_folder>/resources/scripts/MissionScripting.lua. And then restart DCS. (This will also have to be done again after each DCS update)"..
|
||||||
|
"\n\nIt's not worth playing, the state of the mission will not be recorded.")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
mist.scheduleFunction(write_state_error_handling, {}, timer.getTime() + 10, 60, timer.getTime() + 3600)
|
||||||
|
|
||||||
activeWeapons = {}
|
activeWeapons = {}
|
||||||
local function onEvent(event)
|
local function onEvent(event)
|
||||||
|
|||||||
@@ -184,6 +184,11 @@ QLabel[style="base-title"]{
|
|||||||
font-size: 24px;
|
font-size: 24px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QLabel[style="budget-label"]{
|
||||||
|
font-size: 16px;
|
||||||
|
margin-right: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
QLabel[style="icon-plane"]{
|
QLabel[style="icon-plane"]{
|
||||||
background-color:#48719D;
|
background-color:#48719D;
|
||||||
min-height:24px;
|
min-height:24px;
|
||||||
@@ -481,3 +486,7 @@ QWidget[style="baseMenuHeader"]{
|
|||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
color:white;
|
color:white;
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
|
QLabel[style="small"]{
|
||||||
|
font-size: 8px;
|
||||||
|
}
|
||||||
@@ -178,4 +178,8 @@ QLabel[style="SEAD"]{
|
|||||||
QWidget[style="baseMenuHeader"]{
|
QWidget[style="baseMenuHeader"]{
|
||||||
font-size: 24px;
|
font-size: 24px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
|
QLabel[style="small"]{
|
||||||
|
font-size: 8px;
|
||||||
|
}
|
||||||
BIN
resources/syria.gif
Normal file
|
After Width: | Height: | Size: 1000 KiB |
BIN
resources/syrialandmap.p
Normal file
@@ -1,6 +1,6 @@
|
|||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
import dcs
|
from pydcs import dcs
|
||||||
|
|
||||||
from game import db
|
from game import db
|
||||||
from gen.aircraft import AircraftConflictGenerator
|
from gen.aircraft import AircraftConflictGenerator
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ def _mk_archieve():
|
|||||||
shutil.rmtree("./dist")
|
shutil.rmtree("./dist")
|
||||||
except FileNotFoundError:
|
except FileNotFoundError:
|
||||||
pass
|
pass
|
||||||
os.system("pyinstaller.exe pyinstaller.spec")
|
os.system("pyinstaller.exe --clean pyinstaller.spec")
|
||||||
#archieve = ZipFile(path, "w")
|
#archieve = ZipFile(path, "w")
|
||||||
#archieve.writestr("dcs_liberation.bat", "cd dist\\dcs_liberation\r\nliberation_main \"%UserProfile%\\Saved Games\" \"{}\"".format(VERSION))
|
#archieve.writestr("dcs_liberation.bat", "cd dist\\dcs_liberation\r\nliberation_main \"%UserProfile%\\Saved Games\" \"{}\"".format(VERSION))
|
||||||
#_zip_dir(archieve, "./dist/dcs_liberation")
|
#_zip_dir(archieve, "./dist/dcs_liberation")
|
||||||
|
|||||||
BIN
resources/tools/syria_terrain.miz
Normal file
BIN
resources/ui/terrain_syria.gif
Normal file
|
After Width: | Height: | Size: 1.3 KiB |
BIN
resources/ui/units/aircrafts/MQ-1A Predator_24.jpg
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
resources/ui/units/aircrafts/MQ-9 Reaper_24.jpg
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
BIN
resources/ui/units/aircrafts/WingLoong-I_24.jpg
Normal file
|
After Width: | Height: | Size: 1.0 KiB |
BIN
resources/ui/units/buildings/.Ammunition depot.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
resources/ui/units/buildings/.Command Center.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
resources/ui/units/buildings/Barracks 2.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
resources/ui/units/buildings/Chemical Tank A.png
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
resources/ui/units/buildings/Comms tower M.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
resources/ui/units/buildings/Electric power box.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
resources/ui/units/buildings/FARP Ammo Dump Coating.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
resources/ui/units/buildings/FARP CP Blindage.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
resources/ui/units/buildings/FARP Fuel Depot.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
resources/ui/units/buildings/FARP Tent.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
resources/ui/units/buildings/Farm A.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
resources/ui/units/buildings/Farm B.png
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
resources/ui/units/buildings/Fire Control Bunker.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
resources/ui/units/buildings/Garage B.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
resources/ui/units/buildings/Garage small B.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
resources/ui/units/buildings/Hangar A.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
resources/ui/units/buildings/Hangar B.png
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
resources/ui/units/buildings/Oil derrick.png
Normal file
|
After Width: | Height: | Size: 16 KiB |
BIN
resources/ui/units/buildings/Oil platform.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
resources/ui/units/buildings/Pump station.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
resources/ui/units/buildings/Repair Workshop.png
Normal file
|
After Width: | Height: | Size: 16 KiB |