mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Initial support for Germany Cold War (#518)
* Initial support of Germany Cold War terrain * Updated with latest beacon import * Updated changelog and ran black * Fixed the GermanyCW landmap and naming scheme * Temporarily changed the requirements for pydcs to my branch (will switch back when merged) * Updated landmap for germanycw with even fewer exclusions * Removed unnecessary changes * Updated requirements to lastest pydcs * Fixed naming issues for Germany * Update pydcs to latest commit for GCW support * Add landmap to game.theater.__init__ * Update requirements.txt * Resolve PyCharm type-waring * Updated pydcs and exclusion of germany * Updated land and sea shapefiles for Germany Cold War with new map limits --------- Co-authored-by: Raffson <Raffson@users.noreply.github.com>
This commit is contained in:
parent
5254ef3442
commit
9a00a60cd4
@ -5,6 +5,7 @@
|
|||||||
* **[Plugins]** Improvements to AI support for EW Script 2.0
|
* **[Plugins]** Improvements to AI support for EW Script 2.0
|
||||||
* **[Config]** New preference setting to trigger the first-start window on every start (could help in scenarios multiple Retribution instances need to run concurrently)
|
* **[Config]** New preference setting to trigger the first-start window on every start (could help in scenarios multiple Retribution instances need to run concurrently)
|
||||||
* **[Modding]** Update Grinelli Designs F-22A Mod to 2.0.0 (May 2025)
|
* **[Modding]** Update Grinelli Designs F-22A Mod to 2.0.0 (May 2025)
|
||||||
|
* **[Campaign Design]** Added support for Germany Cold War terrain by Ugra Media
|
||||||
* **[Options]** New option to control EPLRS-task injection in mission generator
|
* **[Options]** New option to control EPLRS-task injection in mission generator
|
||||||
|
|
||||||
## Fixes
|
## Fixes
|
||||||
|
|||||||
@ -49,7 +49,9 @@ class GameJs(BaseModel):
|
|||||||
iads_network=IadsNetworkJs.from_network(game.theater.iads_network),
|
iads_network=IadsNetworkJs.from_network(game.theater.iads_network),
|
||||||
threat_zones=ThreatZoneContainerJs.for_game(game),
|
threat_zones=ThreatZoneContainerJs.for_game(game),
|
||||||
navmeshes=NavMeshesJs.from_game(game),
|
navmeshes=NavMeshesJs.from_game(game),
|
||||||
map_center=game.theater.terrain.map_view_default.position.latlng(),
|
map_center=LeafletPoint.from_latlng(
|
||||||
|
game.theater.terrain.map_view_default.position.latlng()
|
||||||
|
),
|
||||||
unculled_zones=UnculledZoneJs.from_game(game),
|
unculled_zones=UnculledZoneJs.from_game(game),
|
||||||
map_zones=MapZonesJs.from_game(game),
|
map_zones=MapZonesJs.from_game(game),
|
||||||
)
|
)
|
||||||
|
|||||||
@ -19,6 +19,10 @@ class LeafletPoint(BaseModel):
|
|||||||
|
|
||||||
title = "LatLng"
|
title = "LatLng"
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def from_latlng(latlng: LatLng) -> LeafletPoint:
|
||||||
|
return LeafletPoint(lat=latlng.lat, lng=latlng.lng)
|
||||||
|
|
||||||
|
|
||||||
LeafletLine = list[LeafletPoint]
|
LeafletLine = list[LeafletPoint]
|
||||||
|
|
||||||
|
|||||||
@ -2,5 +2,6 @@ from .base import *
|
|||||||
from .conflicttheater import *
|
from .conflicttheater import *
|
||||||
from .controlpoint import *
|
from .controlpoint import *
|
||||||
from .frontline import FrontLine
|
from .frontline import FrontLine
|
||||||
|
from .landmap import *
|
||||||
from .missiontarget import MissionTarget
|
from .missiontarget import MissionTarget
|
||||||
from .theatergroundobject import SamGroundObject
|
from .theatergroundobject import SamGroundObject
|
||||||
|
|||||||
@ -12,6 +12,7 @@ from dcs.mission import Mission
|
|||||||
from dcs.terrain.terrain import Terrain
|
from dcs.terrain.terrain import Terrain
|
||||||
from shapely import geometry, LineString
|
from shapely import geometry, LineString
|
||||||
from shapely.geometry import MultiPolygon, Polygon
|
from shapely.geometry import MultiPolygon, Polygon
|
||||||
|
import shapely as shp
|
||||||
|
|
||||||
|
|
||||||
@dataclass(frozen=True)
|
@dataclass(frozen=True)
|
||||||
@ -28,6 +29,11 @@ class Landmap:
|
|||||||
if not self.sea_zones.is_valid:
|
if not self.sea_zones.is_valid:
|
||||||
raise RuntimeError("Sea zones not valid")
|
raise RuntimeError("Sea zones not valid")
|
||||||
|
|
||||||
|
# Generate Spatial Index using `prepare` to improve performance
|
||||||
|
shp.prepare(self.inclusion_zones)
|
||||||
|
shp.prepare(self.exclusion_zones)
|
||||||
|
shp.prepare(self.sea_zones)
|
||||||
|
|
||||||
@cached_property
|
@cached_property
|
||||||
def inclusion_zone_only(self) -> MultiPolygon:
|
def inclusion_zone_only(self) -> MultiPolygon:
|
||||||
return self.inclusion_zones - self.exclusion_zones - self.sea_zones
|
return self.inclusion_zones - self.exclusion_zones - self.sea_zones
|
||||||
|
|||||||
@ -20,6 +20,7 @@ from dcs.terrain import (
|
|||||||
Kola,
|
Kola,
|
||||||
Afghanistan,
|
Afghanistan,
|
||||||
Iraq,
|
Iraq,
|
||||||
|
GermanyColdWar,
|
||||||
)
|
)
|
||||||
|
|
||||||
from .conflicttheater import ConflictTheater, THEATER_RESOURCE_DIR
|
from .conflicttheater import ConflictTheater, THEATER_RESOURCE_DIR
|
||||||
@ -39,6 +40,7 @@ ALL_TERRAINS = [
|
|||||||
Kola(),
|
Kola(),
|
||||||
Afghanistan(),
|
Afghanistan(),
|
||||||
Iraq(),
|
Iraq(),
|
||||||
|
GermanyColdWar(),
|
||||||
]
|
]
|
||||||
|
|
||||||
TERRAINS_BY_NAME = {t.name: t for t in ALL_TERRAINS}
|
TERRAINS_BY_NAME = {t.name: t for t in ALL_TERRAINS}
|
||||||
|
|||||||
@ -33,7 +33,7 @@ pluggy==1.5.0
|
|||||||
pre-commit==4.2.0
|
pre-commit==4.2.0
|
||||||
pydantic==2.11.0b2
|
pydantic==2.11.0b2
|
||||||
pydantic-settings==2.8.1
|
pydantic-settings==2.8.1
|
||||||
pydcs @ git+https://github.com/dcs-retribution/pydcs@4a5e3ee63d3a487841c7b88c0a5bf58811567d6c
|
pydcs @ git+https://github.com/dcs-retribution/pydcs@4520ed28306a62c029a07becfe1f30907589c6b0
|
||||||
pyinstaller==5.13.2
|
pyinstaller==5.13.2
|
||||||
pyinstaller-hooks-contrib==2024.0
|
pyinstaller-hooks-contrib==2024.0
|
||||||
pyparsing==3.2.1
|
pyparsing==3.2.1
|
||||||
|
|||||||
2200
resources/dcs/beacons/germanycw.json
Normal file
2200
resources/dcs/beacons/germanycw.json
Normal file
File diff suppressed because it is too large
Load Diff
BIN
resources/theaters/germanycw/icon.gif
Normal file
BIN
resources/theaters/germanycw/icon.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.6 KiB |
44
resources/theaters/germanycw/info.yaml
Normal file
44
resources/theaters/germanycw/info.yaml
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
---
|
||||||
|
name: GermanyCW # Mostly based on Caucasus, could be updated with more appropriate data if necessary
|
||||||
|
timezone: +1
|
||||||
|
daytime:
|
||||||
|
dawn: [6, 9]
|
||||||
|
day: [9, 18]
|
||||||
|
dusk: [18, 20]
|
||||||
|
night: [0, 5]
|
||||||
|
climate:
|
||||||
|
day_night_temperature_difference: 9.0
|
||||||
|
seasons:
|
||||||
|
winter:
|
||||||
|
average_pressure: 29.72 # TODO: Find real-world data
|
||||||
|
average_temperature: 3.0
|
||||||
|
weather:
|
||||||
|
thunderstorm: 1
|
||||||
|
raining: 20
|
||||||
|
cloudy: 60
|
||||||
|
clear: 20
|
||||||
|
spring:
|
||||||
|
weather:
|
||||||
|
thunderstorm: 1
|
||||||
|
raining: 20
|
||||||
|
cloudy: 40
|
||||||
|
clear: 40
|
||||||
|
summer:
|
||||||
|
average_pressure: 30.02 # TODO: Find real-world data
|
||||||
|
average_temperature: 22.5
|
||||||
|
weather:
|
||||||
|
thunderstorm: 1
|
||||||
|
raining: 10
|
||||||
|
cloudy: 35
|
||||||
|
clear: 55
|
||||||
|
fall:
|
||||||
|
weather:
|
||||||
|
thunderstorm: 1
|
||||||
|
raining: 30
|
||||||
|
cloudy: 50
|
||||||
|
clear: 20
|
||||||
|
turbulence:
|
||||||
|
high_avg_yearly_turbulence_per_10cm: 9
|
||||||
|
low_avg_yearly_turbulence_per_10cm: 3.5
|
||||||
|
solar_noon_turbulence_per_10cm: 3.5
|
||||||
|
midnight_turbulence_per_10cm: -3
|
||||||
BIN
resources/theaters/germanycw/landmap.p
Normal file
BIN
resources/theaters/germanycw/landmap.p
Normal file
Binary file not shown.
@ -0,0 +1 @@
|
|||||||
|
UTF-8
|
||||||
BIN
unshipped_data/arcgis_maps/germanycw/exclusion/exclusion.dbf
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/exclusion/exclusion.dbf
Normal file
Binary file not shown.
@ -0,0 +1 @@
|
|||||||
|
PROJCS["WGS_1972_BE_UTM_Zone_34N",GEOGCS["GCS_WGS_1972_BE",DATUM["D_WGS_1972_BE",SPHEROID["WGS_1972",6378135.0,298.26]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",21.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]]
|
||||||
BIN
unshipped_data/arcgis_maps/germanycw/exclusion/exclusion.shp
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/exclusion/exclusion.shp
Normal file
Binary file not shown.
BIN
unshipped_data/arcgis_maps/germanycw/exclusion/exclusion.shx
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/exclusion/exclusion.shx
Normal file
Binary file not shown.
1
unshipped_data/arcgis_maps/germanycw/land/land.cpg
Normal file
1
unshipped_data/arcgis_maps/germanycw/land/land.cpg
Normal file
@ -0,0 +1 @@
|
|||||||
|
UTF-8
|
||||||
BIN
unshipped_data/arcgis_maps/germanycw/land/land.dbf
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/land/land.dbf
Normal file
Binary file not shown.
1
unshipped_data/arcgis_maps/germanycw/land/land.prj
Normal file
1
unshipped_data/arcgis_maps/germanycw/land/land.prj
Normal file
@ -0,0 +1 @@
|
|||||||
|
PROJCS["WGS_1972_BE_UTM_Zone_34N",GEOGCS["GCS_WGS_1972_BE",DATUM["D_WGS_1972_BE",SPHEROID["WGS_1972",6378135.0,298.26]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",21.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]]
|
||||||
BIN
unshipped_data/arcgis_maps/germanycw/land/land.shp
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/land/land.shp
Normal file
Binary file not shown.
BIN
unshipped_data/arcgis_maps/germanycw/land/land.shx
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/land/land.shx
Normal file
Binary file not shown.
1
unshipped_data/arcgis_maps/germanycw/sea/sea.cpg
Normal file
1
unshipped_data/arcgis_maps/germanycw/sea/sea.cpg
Normal file
@ -0,0 +1 @@
|
|||||||
|
UTF-8
|
||||||
BIN
unshipped_data/arcgis_maps/germanycw/sea/sea.dbf
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/sea/sea.dbf
Normal file
Binary file not shown.
1
unshipped_data/arcgis_maps/germanycw/sea/sea.prj
Normal file
1
unshipped_data/arcgis_maps/germanycw/sea/sea.prj
Normal file
@ -0,0 +1 @@
|
|||||||
|
PROJCS["WGS_1972_BE_UTM_Zone_34N",GEOGCS["GCS_WGS_1972_BE",DATUM["D_WGS_1972_BE",SPHEROID["WGS_1972",6378135.0,298.26]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",21.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]]
|
||||||
BIN
unshipped_data/arcgis_maps/germanycw/sea/sea.shp
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/sea/sea.shp
Normal file
Binary file not shown.
BIN
unshipped_data/arcgis_maps/germanycw/sea/sea.shx
Normal file
BIN
unshipped_data/arcgis_maps/germanycw/sea/sea.shx
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user