Custom key bindings

Hey, I’ve been trying to find a good tutorial on how to setup custom key bindings on my settings widget but I haven’t been able to find any, I want to create a settings for both the keyboard and gamepad which allows the player to choose whatever key they’d like to do certain actions… If you can help, it’ll be appreciated.

I’m not sure why you’re having trouble- every keybind tutorial should go over this.
Using the new or old system, you can just add both the keyboard and gamepad controls, and use the input key selector.

You can just have one widget tab for keyboard inputs and one for gamepad.

That’s the idea I wanna work on, regardless I don’t know what and what I need to do to achieve it, I’ve already created the widget, I just need the codes

Yup- that is what gamedev is. You’ll need to make the code.

The easiest way to separate them is probably to check if the key display name has gamepad in it:




Here’s a tutorial on the basics of the enhanced input action system:

3 Likes

Thanks, this also applys to ue4 right?

Yup- though you’ll need to enable the enhanced input plugin.

The default system in UE4 is deprecated in UE5, so I’d recommend using the enhanced version- it’s also the system I actually sent a tutorial for.

Alright thanks, I’m gonna try to do it following the steps on the tutorial