diff --git a/game/campaignloader/campaign.py b/game/campaignloader/campaign.py index 582c7f7a..b1741e5d 100644 --- a/game/campaignloader/campaign.py +++ b/game/campaignloader/campaign.py @@ -15,7 +15,6 @@ from game.profiling import logged_duration from game.theater import ( ConflictTheater, FalklandsTheater, - NevadaTheater, NormandyTheater, TheChannelTheater, ) @@ -113,7 +112,6 @@ class Campaign: def load_theater(self, advanced_iads: bool) -> ConflictTheater: theaters = { - "Nevada": NevadaTheater, "Normandy": NormandyTheater, "The Channel": TheChannelTheater, "Falklands": FalklandsTheater, diff --git a/game/theater/conflicttheater.py b/game/theater/conflicttheater.py index efccbad5..d9c440c7 100644 --- a/game/theater/conflicttheater.py +++ b/game/theater/conflicttheater.py @@ -9,7 +9,6 @@ from uuid import UUID from dcs.mapping import Point from dcs.terrain import ( falklands, - nevada, normandy, thechannel, ) @@ -243,27 +242,6 @@ class ConflictTheater: return Heading.from_degrees(position.heading_between_point(conflict_center)) -class NevadaTheater(ConflictTheater): - terrain = nevada.Nevada() - landmap = load_landmap(Path("resources/nevlandmap.p")) - daytime_map = DaytimeMap( - dawn=(datetime.time(hour=4), datetime.time(hour=6)), - day=(datetime.time(hour=6), datetime.time(hour=17)), - dusk=(datetime.time(hour=17), datetime.time(hour=18)), - night=(datetime.time(hour=0), datetime.time(hour=5)), - ) - - @property - def timezone(self) -> datetime.timezone: - return datetime.timezone(datetime.timedelta(hours=-8)) - - @property - def seasonal_conditions(self) -> SeasonalConditions: - from .seasonalconditions.nevada import CONDITIONS - - return CONDITIONS - - class NormandyTheater(ConflictTheater): terrain = normandy.Normandy() landmap = load_landmap(Path("resources/normandylandmap.p")) diff --git a/game/theater/seasonalconditions/nevada.py b/game/theater/seasonalconditions/nevada.py deleted file mode 100644 index 36b7934d..00000000 --- a/game/theater/seasonalconditions/nevada.py +++ /dev/null @@ -1,36 +0,0 @@ -from .seasonalconditions import SeasonalConditions, Season, WeatherTypeChances - -CONDITIONS = SeasonalConditions( - summer_avg_pressure=30.02, # TODO: Find real-world data - winter_avg_pressure=29.72, # TODO: Find real-world data - summer_avg_temperature=31.5, - winter_avg_temperature=5.0, - temperature_day_night_difference=6.0, - weather_type_chances={ - # TODO: Find real-world data for all these values - Season.Winter: WeatherTypeChances( - thunderstorm=1, - raining=10, - cloudy=50, - clear_skies=40, - ), - Season.Spring: WeatherTypeChances( - thunderstorm=1, - raining=5, - cloudy=45, - clear_skies=50, - ), - Season.Summer: WeatherTypeChances( - thunderstorm=1, - raining=5, - cloudy=30, - clear_skies=65, - ), - Season.Fall: WeatherTypeChances( - thunderstorm=1, - raining=10, - cloudy=45, - clear_skies=45, - ), - }, -) diff --git a/resources/theaters/nevada/info.yaml b/resources/theaters/nevada/info.yaml new file mode 100644 index 00000000..401071fc --- /dev/null +++ b/resources/theaters/nevada/info.yaml @@ -0,0 +1,39 @@ +--- +name: Nevada +timezone: -8 +daytime: + dawn: [4, 6] + day: [6, 17] + dusk: [17, 18] + night: [0, 5] +climate: + day_night_temperature_difference: 6.0 + seasons: + winter: + average_pressure: 29.72 # TODO: Find real-world data + average_temperature: 5.0 + weather: + thunderstorm: 1 + raining: 10 + cloudy: 50 + clear: 40 + spring: + weather: + thunderstorm: 1 + raining: 5 + cloudy: 45 + clear: 50 + summer: + average_pressure: 30.02 # TODO: Find real-world data + average_temperature: 31.5 + weather: + thunderstorm: 1 + raining: 5 + cloudy: 30 + clear: 65 + fall: + weather: + thunderstorm: 1 + raining: 10 + cloudy: 45 + clear: 45 diff --git a/resources/nevlandmap.p b/resources/theaters/nevada/landmap.p similarity index 100% rename from resources/nevlandmap.p rename to resources/theaters/nevada/landmap.p