Double Click with Enhanced Input System

Hello,
I am using enhanced input and I was wondering if one could setup a double click on a left mouse button with a combo trigger or some other way, so there’s no need for a manual double click detection in the blueprint itself.

In my Input Mapping Context I cannot set my input action to be triggered with combo on a mouse (it automatically changes from Left Mouse Button to None).

I couldn’t find any tutorial on a double click just combo with different keys and I cannot make it work.

Thank you in advance

2 Likes

I was able to make this by having two input actions, one for single click and a second for double click. Both actions are added to the context. The single click is default but the double click has a combo trigger made up of two single click actions.

In my example I am using a single left mouse click to select an object and a double left mouse click to focus an object.

I’m still wrapping my head around the new input system myself, so I might be misunderstanding the intended implementation.

3 Likes

ue5.3


it’s worked in my case.

7 Likes

Enhanced Input System is a little different in 5.1, the same settings combo is not triggered? Can you help me implement this in 5.1? Thanks

FYI for 5.3

You cannot use a KEY for a Combo. It must be an existing IA.

So you must use another IA like this

Then use the Cancel and Completed
Completed = Execute
Cancel = Do not Execute

Hope this helps someone

4 Likes

This just helped me, thanks.

Jumping in here to hopefully save someone else hours of messing around:

You can just override the ‘OnMouseDoubleClick’ function, which helped me when I was doing UI widget double-clicking…

1 Like

Thanks, very helpful.

Only, it doesn’t allow any sort of axis type actions to use the combo unfortunately. So using the move input action to try to add double tap to sprint it’s going to work. Will have to do it the old fashioned way (with a gated macro).

“[AssetLog] The mapping of IA_RS_Sprint to Combo Key has a Combo Trigger (From the Mapping Context) with additional non-combo triggers (From the Input Action). Mixing Combo Triggers with other types of Triggers is not supported. Consider putting the Combo Trigger(s) on a seperate mapping or making a seperate Input Action for them.”

Thank you so much, it works !