Jump to content

Quaggles - DCS Input Command Injector Mod - Store custom input commands safely in Saved Games instead of merging them with developer changes each update


Quaggles

Recommended Posts

9 hours ago, Quaggles said:

Did you put them in a "joystick/default.lua" as shown in the instructions on the github? If you only put them in "keyboard/default.lua" they can't be assigned to HOTAS.

 

In doubt, I just checked and yes, they are in the right place.
I did the same thing for the FA18 and it works, I don't know! Never mind, thanks anyway.

System specs: Win10 x64 | i7-9700KF / i9-12900KF | 48/64 GB | GTX 1080 Ti 11 GB / RTX 3090TI 24GB | *NvME PRO 2To | HOTAS Warthog/Virpil | MFG Crosswind Pedals | Button Box

Link to comment
Share on other sites

3 hours ago, Kervinou said:

In doubt, I just checked and yes, they are in the right place.
I did the same thing for the FA18 and it works, I don't know! Never mind, thanks anyway.

Some modules have device-specific LUA files, and the F-5 is one of them.

Go to this folder in your DCS installation folder: DCS\Mods\aircraft\F-5E\Input\F-5E\joystick

There you will see some device-specific LUA files that are separate from the main default.lua file. They are the large files around 146KB.

If you are trying to add commands to "Defender COBRA M5 USB Joystick", "Joystick - HOTAS Warthog", "Saitek Pro Flight Rudder Pedals", or "Throttle - HOTAS Warthog", then you need to put the custom controls in a lua file by that device name.

Sounds like you were adding them for a warthog so you'd need to add lua files named like "Joystick - HOTAS Warthog.lua" or "Throttle - HOTAS Warthog.lua" to the F-5 directory in your InputCommands folder, then put your custom commands there. If you've already got your default.lua file setup with the custom commands you can copy-rename it to include the device name. Then Quaggles mod will apply those custom commands to the "Joystick - HOTAS Warthog.lua" or "Throttle - HOTAS Warthog.lua" files that are part of the F-5 module. The custom commands not being in the device-specific LUA files is why they will be greyed out in game - the commands haven't been defined for that device. The X-55 doesn't have a device-specific LUA for the F-5, which is why Quaggles could add it to the default.lua and it work ok.

Here's an example from keybinds project where I have multiple device files setup using Quaggles to provide custom controls for A-10C: https://github.com/Munkwolf/dcs-community-keybinds/tree/main/InputCommands/A-10C/Input/A-10C/joystick

Looks like I haven't done that for the F-5. I'll get that updated sometime in the next week and see what other commands I can add (such as the airbrakes).


Edited by Munkwolf
  • Like 2
  • Thanks 1
Link to comment
Share on other sites

Ah good advice Munkwolf, I've never owned a device that had those device specific luas configured so I completely forgot about them for custom input stuff, they just happen to work with the injector since I hook into the DCS function that handles all lua input files and not just the generic ones, so that's fortunate haha

  • Like 1
Link to comment
Share on other sites

Many, many thanks for all this information!

It works perfectly well now

Really, a big thank you!

  • Like 1

System specs: Win10 x64 | i7-9700KF / i9-12900KF | 48/64 GB | GTX 1080 Ti 11 GB / RTX 3090TI 24GB | *NvME PRO 2To | HOTAS Warthog/Virpil | MFG Crosswind Pedals | Button Box

Link to comment
Share on other sites

  • 2 weeks later...

Hi

is it just me, or has it stopped working since the last update?

(I did reactivate the mod in the game folder)

System specs: Win10 x64 | i7-9700KF / i9-12900KF | 48/64 GB | GTX 1080 Ti 11 GB / RTX 3090TI 24GB | *NvME PRO 2To | HOTAS Warthog/Virpil | MFG Crosswind Pedals | Button Box

Link to comment
Share on other sites

3 hours ago, Kervinou said:

Hi

is it just me, or has it stopped working since the last update?

(I did reactivate the mod in the game folder)

Still working for me, no changes in this patch to the file that the mod changes. Are the custom controls just not showing up ingame?

Link to comment
Share on other sites

Yes, controls are not visibles

and the controls obviously no longer work


Edited by Kervinou

System specs: Win10 x64 | i7-9700KF / i9-12900KF | 48/64 GB | GTX 1080 Ti 11 GB / RTX 3090TI 24GB | *NvME PRO 2To | HOTAS Warthog/Virpil | MFG Crosswind Pedals | Button Box

Link to comment
Share on other sites

If it was working before the patch then maybe the mod didn't reinstall correctly? Try going to`DCS World/Scripts/Input/Data.lua` once you've installed the mod and search for "Quaggles" if it doesn't find any results then your mod manager isn't overwriting the script correctly.

If that doesn't lead to anything you can try following the guide on the Github: https://github.com/Quaggles/dcs-input-command-injector#my-new-input-commands-arent-showing-up-ingame

That should determine why it's not hooking the custom commands if the mod is installed.


Edited by Quaggles
  • Like 1
Link to comment
Share on other sites

Yes, you're right!

OK, I get it, forget about my sorry comment

It's the fault of the AMVI version of OVGME which doesn't want to write in the game folder without being launched in admin mode

Sorry, thanks

Before I had installed all the mods with the original version of OVGME and because of a few, I set up the AMVI version, and as there is no error message, I thought the activations / deactivations were working.

But no, in fact it was all smoke and mirrors but as I had activated them before, I thought it was ok!

Anyway 😉

 

System specs: Win10 x64 | i7-9700KF / i9-12900KF | 48/64 GB | GTX 1080 Ti 11 GB / RTX 3090TI 24GB | *NvME PRO 2To | HOTAS Warthog/Virpil | MFG Crosswind Pedals | Button Box

Link to comment
Share on other sites

@Quaggles I'm running into a strange issue while working on keybinds for the Mirage F1. For them to show up, I have to load into any other module, then quit back to menu, then load into the F1. If I go straight into the F1 after game start, the custom binds usually won't be there. A couple of times they were, but it was either the Mirage F1 common binds, or the F1CE binds, but not all of them. I've done a repair and tried some different file setups for the binds but the behavior continues.

https://github.com/Munkwolf/dcs-community-keybinds/tree/main/InputCommands/Mirage-F1/Input

Also I went through and updated the InputCommands_Skeleton files in keybinds project to add the device-specific lua files and Mirage F1 files, if you'd like to update the InputCommands.zip in the command injector repo with it.


Edited by Munkwolf
  • Like 1
Link to comment
Share on other sites

On 7/24/2022 at 6:57 AM, Munkwolf said:

@Quaggles I'm running into a strange issue while working on keybinds for the Mirage F1. For them to show up, I have to load into any other module, then quit back to menu, then load into the F1. If I go straight into the F1 after game start, the custom binds usually won't be there. A couple of times they were, but it was either the Mirage F1 common binds, or the F1CE binds, but not all of them. I've done a repair and tried some different file setups for the binds but the behavior continues.

https://github.com/Munkwolf/dcs-community-keybinds/tree/main/InputCommands/Mirage-F1/Input

Also I went through and updated the InputCommands_Skeleton files in keybinds project to add the device-specific lua files and Mirage F1 files, if you'd like to update the InputCommands.zip in the command injector repo with it.

 

Unfortunately I can't replicate that issue, at first I just brought your Mirage F1 binds in and it worked as expected, then I thought it might be that you had hit some limit on the total amount of input commands that can exist in DCS haha

So I brought your entire package in and closed and opened DCS a bunch of times going right into the control menu for the Mirage F1 CE and always had the common and Mirage F1 CE keyCommands and axisCommands show up, even the `Aircrafts\common_joystick_binding.lua` bindings I have were working on top of that.

This was the only input related code I saw in dcs.log but it was all still working for me:

2022-07-25 14:51:17.598 INFO    INPUT: Key combo skipped. Layer[InputOptionsView] key = [KEY_L] device = [Keyboard] modifiers[key = [KEY_RCONTROL] device = [Keyboard]] switches[] action[down = -166, ]. Combo already mapped to action [down = -72, ]
2022-07-25 14:51:17.598 INFO    INPUT: Key combo skipped. Layer[InputOptionsView] key = [KEY_J] device = [Keyboard] modifiers[key = [KEY_LSHIFT] device = [Keyboard]] switches[] action[down = -199, ]. Combo already mapped to action [down = -61, ]
2022-07-25 14:51:17.598 INFO    INPUT: Key combo skipped. Layer[InputOptionsView] key = [KEY_K] device = [Keyboard] modifiers[key = [KEY_RCONTROL] device = [Keyboard]] switches[] action[down = -208, ]. Combo already mapped to action [down = -27, ]
2022-07-25 14:51:17.599 INFO    INPUT: Key combo skipped. Layer[InputOptionsView] key = [KEY_T] device = [Keyboard] modifiers[] switches[] action[down = -305, ]. Combo already mapped to action [down = -266, ]
2022-07-25 14:51:17.599 INFO    INPUT: Key combo skipped. Layer[InputOptionsView] key = [KEY_P] device = [Keyboard] modifiers[key = [KEY_RSHIFT] device = [Keyboard]] switches[] action[down = -315, ]. Combo already mapped to action [down = -52, ]
2022-07-25 14:51:17.600 INFO    INPUT: Key combo skipped. Layer[InputOptionsView] key = [KEY_Z] device = [Keyboard] modifiers[key = [KEY_LALT] device = [Keyboard]; key = [KEY_LSHIFT] device = [Keyboard]] switches[] action[down = -344, ]. Combo already mapped to action [down = -62, ]

If you haven't already set `quagglesLoggingEnabled = true` in the Data.lua file then reproduce the problem on your end and upload dcs.log here.

Link to comment
Share on other sites

  • 2 weeks later...

I need to create keybinds for actions that do not exist in the controls tab for a mod, the SU30M. Although there are some keybinds in the controls dialog, many are missing-start engines, battery, the electrical switches, etc. How do I go about doing this? Where do I look in the lua files?

 

edit: found answer here

 


Edited by skypickle

4930K @ 4.5, 32g ram, TitanPascal

Link to comment
Share on other sites

unfortunately this doesnt work so well for the su-30 mod.

 

The clickabledata.lua for the SU30 has this line:

elements["BATTERY1"] = {class = {class_type.TUMB,class_type.TUMB}, hint  = _("Battery 1"), device = devices.ELECTRIC_SYSTEM, action = {device_commands.Button_127, device_commands.Button_127}, arg = {3127,3127}, arg_value = {0,1}, arg_lim = {{0,1},{0,1}},updatable = true}

 

I tried to modify the default.lua file so that bindings would appear in the controls tab.

I added these lines to the default.lua

 

{down = device_systems.Batt1OnOff,        value_down = 1 , name = _('Battary 1 ON'),                        category = _('Systems')},
{down = device_systems.Batt1OnOff,        value_down = 0 , name = _('Battary 1 OFF'),                        category = _('Systems')},

Although bindings appear in the controls tab, the buttons on my box assigned to these actions do nothing in the cockpit.


Edited by skypickle

4930K @ 4.5, 32g ram, TitanPascal

Link to comment
Share on other sites

2 hours ago, skypickle said:

unfortunately this doesnt work so well for the su-30 mod.

 

The clickabledata.lua for the SU30 has this line:

elements["BATTERY1"] = {class = {class_type.TUMB,class_type.TUMB}, hint  = _("Battery 1"), device = devices.ELECTRIC_SYSTEM, action = {device_commands.Button_127, device_commands.Button_127}, arg = {3127,3127}, arg_value = {0,1}, arg_lim = {{0,1},{0,1}},updatable = true}

 

I tried to modify the default.lua file so that bindings would appear in the controls tab.

I added these lines to the default.lua

 

{down = device_systems.Batt1OnOff,        value_down = 1 , name = _('Battary 1 ON'),                        category = _('Systems')},
{down = device_systems.Batt1OnOff,        value_down = 0 , name = _('Battary 1 OFF'),                        category = _('Systems')},

Although bindings appear in the controls tab, the buttons on my box assigned to these actions do nothing in the cockpit.

 

 

You used "device_systems.Batt1OnOff" but I don't see it in your clickabledata quote.. 

Try this:

  {down = 3127, cockpit_device_id = devices.ELECTRIC_SYSTEM, value_down = 1, name = _('Batt1 On'), category = _('Special')},

{down = 3127, cockpit_device_id = devices.ELECTRIC_SYSTEM, value_down = 0, name = _('Batt1 Off'), category = _('Special')},

 

Pimax Crystal VR & Simpit User | Ryzen CPU & Nvidia RTX GPU | Some of my mods

Link to comment
Share on other sites

12 hours ago, TAIPAN_ said:

 

You used "device_systems.Batt1OnOff" but I don't see it in your clickabledata quote.. 

Try this:

  {down = 3127, cockpit_device_id = devices.ELECTRIC_SYSTEM, value_down = 1, name = _('Batt1 On'), category = _('Special')},

{down = 3127, cockpit_device_id = devices.ELECTRIC_SYSTEM, value_down = 0, name = _('Batt1 Off'), category = _('Special')},

 

I added those lines to the default.lua file and although the control options appear in the controls tab and are bindable, they still do nothing in the cockpit. I also tried 

 

  {down = 127, cockpit_device_id = devices.ELECTRIC_SYSTEM, value_down = 1, name = _('Batt1 On'), category = _('Special')},

{down = 127, cockpit_device_id = devices.ELECTRIC_SYSTEM, value_down = 0, name = _('Batt1 Off'), category = _('Special')},

4930K @ 4.5, 32g ram, TitanPascal

Link to comment
Share on other sites

Question, what is the best way to check for duplicate entries as clearly some modules, e.g. F-14, get updated with commands by the devs which causes orange lined duplicates in DCS if they are also in the injector files?

Intel i7 12700K · MSI Gaming X Trio RTX 4090 · ASUS ROG STRIX Z690-A Wi-Fi · MSI 32" MPG321UR QD · Samsung 970 500Gb M.2 NVMe · 2 x Samsung 850 Evo 1Tb · 2Tb HDD · 32Gb Corsair Vengance 3000MHz DDR4 · Windows 11 · Thrustmaster TPR Pedals · Tobii Eye Tracker 5 · Thrustmaster F/A-18 Hornet Grip · Virpil MongoosT-50CM3 Base · Virpil Throttle MT-50 CM3 · Virpil Alpha Prime Grip · Virpil Control Panel 2 · Thrustmaster F-16 MFDs · HTC Vive Pro 2 · Total Controls Multifunction Button Box

Link to comment
Share on other sites

I noticed conflicts in the F-14, so I just removed them from my Input Commands file.  I was just wondering if there was a non-manual way of checking.

Intel i7 12700K · MSI Gaming X Trio RTX 4090 · ASUS ROG STRIX Z690-A Wi-Fi · MSI 32" MPG321UR QD · Samsung 970 500Gb M.2 NVMe · 2 x Samsung 850 Evo 1Tb · 2Tb HDD · 32Gb Corsair Vengance 3000MHz DDR4 · Windows 11 · Thrustmaster TPR Pedals · Tobii Eye Tracker 5 · Thrustmaster F/A-18 Hornet Grip · Virpil MongoosT-50CM3 Base · Virpil Throttle MT-50 CM3 · Virpil Alpha Prime Grip · Virpil Control Panel 2 · Thrustmaster F-16 MFDs · HTC Vive Pro 2 · Total Controls Multifunction Button Box

Link to comment
Share on other sites

The F14 has extremely useful kneeboard commands I want to use with the Huey and A-10C kneeboards. But they don’t have them. 

These useful kneeboard commands are:

Kneeboard Make Shortcut, Kneeboard Next Shortcut, and Kneeboard Prev Shortcut

Will this software help me to duplicate these kneeboard commands to other mods? 

  • Like 1
Link to comment
Share on other sites

10 hours ago, slo_mo said:

The F14 has extremely useful kneeboard commands I want to use with the Huey and A-10C kneeboards. But they don’t have them. 

These useful kneeboard commands are:

Kneeboard Make Shortcut, Kneeboard Next Shortcut, and Kneeboard Prev Shortcut

Will this software help me to duplicate these kneeboard commands to other mods? 

Not out of the box, but you could add them. (Maybe for the A-10Cs though, as I do have them, but not in the Huey).
I've never noticed that. You do know you've found a(n) bug/oversight?

You should report it as a bug in the Huey section.

Cheers!

Link to comment
Share on other sites

20 hours ago, MAXsenna said:

Not out of the box, but you could add them. (Maybe for the A-10Cs though, as I do have them, but not in the Huey).

Wait, you have the options in the A-10 for these commands?? I only see them in the F14 not the A-10 (or the Huey):

Kneeboard Make Shortcut, Kneeboard Next Shortcut, and Kneeboard Prev Shortcut

I’m confused, I thought they were commands that Heatblur created, not DCS. I only have the three mods so I don’t have a good data sample…

 

Link to comment
Share on other sites

@slo_mo No, these are core features.

I even think they were in the Huey before. So it's absolutely incorrect that they are not.

I have every module, so I'll will check them all. I only checked the A-10s and the Huey for now. 

Cheers!

 

 


 


Edited by MAXsenna
spelling and grammar
Link to comment
Share on other sites

@slo_mo

 

Thanks for noticing this. It has to be an oversight. Went through all the modules, and even community modules and mods have it like the A-4E-C and Santa's Sleigh. 😁

The ones that do not have it are as follows:

MiG-21bis, this was actually to be expected as it was one of the first 3rd parties and have its own keyboard commands anyway.
Bf-109K-4
FW 190 A-8
FW 190 D-9
Ka-50
P-51D
Spitfire LF Mk IX
TF-51D
UH-1H

So only ED modules. Two old helicopters and most of the WWII modules (old ones?)
This issue is probably due to the fact that these modules somehow do not "inherit" these settings.

Pinging you @BIGNEWY Would you like me to make a "bug report" on each of these?

Cheers!

  • Like 2
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...