Best approach for secondary function keybinds?

I know there is a way to set up an input with shift/control/etc. input on top of the base keybind for an input, but is adding a whole new input entry the best way to approach adding secondary function input? (For example, E does one thing, Shift-E does another).

Just wondering whether it’s best to do the shift-input in blueprints. I usually set up the base input as normal, and then set up a “Secondary Function” bool, which is true while shift is being pressed, false once released. Then just branch the base input and change the function depending on the current state of the bool.

I guess I’m just looking to see if there are any alternatives to this, or any ways that would be more efficient.


Go to your viewport. Edit > Project Settings > Input.
You’ll want to replace all of your instances of things like “E Pressed/Released” with an actual input event that can be rebound.

I’ve already got my input set up correctly. What I’m asking here is which would be the best approach for secondary functions / keybind modifiers.

Let’s say my “Interact” key is “E”. What I’m asking is, would it be better to add a whole new input for “Shift-E”, or handle the “Shift” within the blueprint and keep the single “E” input.

For example:

“E” - Open Door
“Shift-E” - Lock/Unlock Door
“Ctrl-E” - Knock On Door

Would I set up three inputs? Surely that’s overdoing it? Would it not be better to let them assign the one input (in this example, “E”), and then add the inputs for Shift-, Ctrl-, etc. through the blueprint without their own inputs in the project settings.

Look at it from the perspective of a PC player that wants to be able to rebind every part of the functionality of the controls.
Having things hard bound to modifier keys without the ability to rebind the action to a single keypress is not a good idea.