Skip to content

Commit

Permalink
Add radio setup for F-5E, Mi-8, Mi-24 and F-86 (#3400)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhexu14 committed Jun 5, 2024
1 parent 352216b commit fd8632a
Show file tree
Hide file tree
Showing 8 changed files with 75 additions and 2 deletions.
3 changes: 3 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ Saves from 11.0.0 are compatible with 11.1.0. See Known Issues section for excep
* **[Campaign]** Fixed double counting of parked aircraft kills when DCS reports multiple kill events.
* **[Campaign]** Fixed error where frontline units are not re-deployed when multiple control points were captured in one turn or when control points are captured "out of order" using air-assault missions.
* **[Cheat Menu]** Re-deploy frontline units when using cheats to capture control points, so that cheats behave the same way as capturing a control point in-mission.
* **[Data]** Added FuSe-65 Early Warning Radar.
* **[Data]** Updated Peru 1995 and Germany 1944 factions.
* **[Flight Planning]** Theater refuelling flight plans (those not tied to a particular package) will remain on station for a longer period, specifically the desired mission duration + 30 minutes. By default, this increases the on-station time from 1 hour to 1.5 hours.
* **[Mission Generation]** Patched bug where Liberation crashed when aborting a turn when Fighter Sweep missions were planned.
* **[Radios]** Added radio setup for F-5E, F-86, Mi-8 and Mi-24.
* **[UI]** Naval control points (carriers, LHAs) can no longer be moved onto land.

## Known Issues
Expand Down
4 changes: 4 additions & 0 deletions game/dcs/aircrafttype.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@
ViperChannelNamer,
WarthogChannelNamer,
PhantomChannelNamer,
HindChannelNamer,
HipChannelNamer,
)
from game.utils import (
Distance,
Expand Down Expand Up @@ -112,6 +114,8 @@ def make_namer(cls, config: dict[str, Any]) -> Type[ChannelNamer]:
"a10c-legacy": LegacyWarthogChannelNamer,
"a10c-ii": WarthogChannelNamer,
"phantom": PhantomChannelNamer,
"hind": HindChannelNamer,
"hip": HipChannelNamer,
}[config.get("namer", "default")]


Expand Down
32 changes: 32 additions & 0 deletions game/radio/channels.py
Original file line number Diff line number Diff line change
Expand Up @@ -405,3 +405,35 @@ def channel_name(radio_id: int, channel_id: int) -> str:
@classmethod
def name(cls) -> str:
return "phantom"


class HindChannelNamer(ChannelNamer):
"""Channel namer for Mi-24 Hind"""

@staticmethod
def channel_name(radio_id: int, channel_id: int) -> str:
radio_name = [
"R863",
"R828",
][radio_id - 1]
return f"{radio_name} Ch {channel_id-1}"

@classmethod
def name(cls) -> str:
return "hind"


class HipChannelNamer(ChannelNamer):
"""Channel namer for Mi-8 Hip"""

@staticmethod
def channel_name(radio_id: int, channel_id: int) -> str:
radio_name = [
"R863",
"R828",
][radio_id - 1]
return f"{radio_name} Ch {channel_id}"

@classmethod
def name(cls) -> str:
return "hip"
6 changes: 4 additions & 2 deletions game/radio/radios.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ def __init__(self, frequency: RadioFrequency) -> None:
),
),
Radio("AN/ARC-222", (RadioRange(MHz(116), MHz(152), MHz(1), Modulation.AM),)),
Radio("AN/ARC-27", (RadioRange(MHz(225), MHz(400), kHz(100), Modulation.AM),)),
Radio("SCR-522", (RadioRange(MHz(100), MHz(156), MHz(1), Modulation.AM),)),
Radio("A.R.I. 1063", (RadioRange(MHz(100), MHz(156), MHz(1), Modulation.AM),)),
Radio("BC-1206", (RadioRange(kHz(200), kHz(400), kHz(10), Modulation.AM),)),
Expand Down Expand Up @@ -237,8 +238,6 @@ def __init__(self, frequency: RadioFrequency) -> None:
Radio("AN/ARC-51BX", (RadioRange(MHz(225), MHz(400), kHz(50), Modulation.AM),)),
Radio("AN/ARC-131", (RadioRange(MHz(30), MHz(76), kHz(50), Modulation.FM),)),
Radio("AN/ARC-134", (RadioRange(MHz(116), MHz(150), kHz(25), Modulation.AM),)),
# F-4E
Radio("AN/ARC-164", (RadioRange(MHz(225), MHz(400), kHz(50), Modulation.AM),)),
# JAS39
Radio("R&S Series 6000", (RadioRange(MHz(100), MHz(156), kHz(25), Modulation.AM),)),
# Mirage F1
Expand Down Expand Up @@ -295,6 +294,9 @@ def __init__(self, frequency: RadioFrequency) -> None:
),
),
),
# Mi-8/Mi-24
Radio("R863", (RadioRange(MHz(220), MHz(400), kHz(25), Modulation.AM),)),
Radio("R828", (RadioRange(MHz(20), MHz(60), kHz(25), Modulation.FM),)),
]


Expand Down
8 changes: 8 additions & 0 deletions resources/units/aircraft/F-5E-3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@ origin: USA
price: 12
role: Light Fighter
max_range: 100
radios:
intra_flight: AN/ARC-164
inter_flight: AN/ARC-164
channels:
type: common
namer: single
intra_flight_radio_index: 1
inter_flight_radio_index: 1
gunfighter: true
variants:
F-5E Tiger II: {}
Expand Down
8 changes: 8 additions & 0 deletions resources/units/aircraft/F-86F Sabre.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@ origin: USA
price: 8
role: Fighter
gunfighter: true
radios:
intra_flight: AN/ARC-27
inter_flight: AN/ARC-27
channels:
type: common
namer: single
intra_flight_radio_index: 1
inter_flight_radio_index: 1
variants:
F-86F Sabre: {}
tasks:
Expand Down
8 changes: 8 additions & 0 deletions resources/units/aircraft/Mi-24P.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,14 @@ origin: USSR/Russia
price: 14
role: Attack/Transport
kneeboard_units: "metric"
radios:
intra_flight: R863
inter_flight: R863
channels:
type: common
namer: hind
intra_flight_radio_index: 1
inter_flight_radio_index: 1
variants:
Mi-24P Hind-F: {}
tasks:
Expand Down
8 changes: 8 additions & 0 deletions resources/units/aircraft/Mi-8MT.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,14 @@ role: Transport/Light Attack
variants:
Mi-8MTV2 Hip: {}
kneeboard_units: "metric"
radios:
intra_flight: R863
inter_flight: R863
channels:
type: common
namer: hip
intra_flight_radio_index: 1
inter_flight_radio_index: 1
tasks:
Air Assault: 40
BAI: 390
Expand Down

0 comments on commit fd8632a

Please sign in to comment.