charliefoxtwo / TouchDCS

An application for interfacing with DCS-BIOS using TouchOSC (or potentially other OSC applications).
GNU General Public License v3.0
35 stars 2 forks source link

Add aliasing for aircraft names #4

Closed charliefoxtwo closed 3 years ago

charliefoxtwo commented 3 years ago

Some aircraft have multiple models which output different ACFT_NAME values in dcs-bios, but use the same json file (e.g. A-10C and A-10C_2 both use a-10c.json. We'll need a way to associate multiple aircraft with the same dcs-bios json file.

Aircraft that have multiple models: A-10C, C-101CC, F-14B (soon?), all FC3 aircraft, P-47D, P-51D, SA-342M, Spitfire LF Mk IX.

This list does not include modded aircraft, or aircraft that share config files with mods (F/A-18C and UH-1H). The easiest way I've found to check is to look at the lua files in dcs-bios and check for a line like BIOS.protocol.setExportModuleAircrafts({"A-10C", "A-10C_2"}). If there are multiple exports specified, then we'll need to account for that.

I think we can add this to the config.json file. This will allow people to add their own mods fairly quickly for testing too, and update their config if we're behind on a patch. From there, we can build an alias dictionary in BiosOscTranslator and reference that when determining the active aircraft or active json file to consider.