Jump to content

Is a generic keybinding mod possible?


eberkain

Recommended Posts

I've been thinking about building myself a space shuttle styled control panel, the switches would come through as joystick button presses in game.  I have used my HOTAS for flying so I know that all the stock game keybinding stuff would work fine, but with mods there are plenty of things that have to be clicked on that have no way to keybind to them, and most mods have no support for keybinding.  I've done some looking and have never seen the subject discussed.  I imagine a mod that would act as an intermediate, detecting a button press and sending out function calls just as if UI buttons had been clicked, and would work for any mod.  I don't know if such a thing would be possible? @RoverDude @sarbian @linuxgurugamer  If anyone would know it would be you guys.

Link to comment
Share on other sites

19 minutes ago, linuxgurugamer said:

This is actually something I started to do back when 1.2 dropped.

Unfortunately, it would require all mods to support it, there is no way that I am aware of to intercept the low-level Unity calls to get the keyboard events

I have seen mods that respond to keypresses, like Kerbalism, you can press 'numpad 0' on the map view to toggle the radiation fields. But when mods do something like that there is typically no way to rebind the key, or make a joystick event operate that function.

Link to comment
Share on other sites

Just now, eberkain said:

I have seen mods that respond to keypresses, like Kerbalism, you can press 'numpad 0' on the map view to toggle the radiation fields. But when mods do something like that there is typically no way to rebind the key, or make a joystick event operate that function.

exactly.  but those mods are watching the keyboard events, which come from Unity. 

Link to comment
Share on other sites

While it's not generic as you are asking for, this is pretty much the reason for my AGX and ModActions mods.

It is in fact the reasons AGX offers 250 action groups, a couple of the larger SimPits that people talk about have several switches in them. Add in the fact that due to how KSP works, you need an action group for every switch position (even On-Off switches need two groups) you very quickly find yourself using dozens of action groups. AGX is even supposed to recognize all your HOTAS buttons so those can be used as well.

Then ModActions is where I hook into the actions controlled via mouse-clicks and assign them an action that can be put into an action group. (Both stock actions such as the throttle limiter, and actions in other mods.)

Ideally this allows you to control everything you want via your control board without having to ever touch the mouse.

D.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...