Enhanced Input Started Trigger inconsistent from 5.4 to 5.5

I have a C++ project in UE5.4 which uses a custom CharacterController class using EnhancecdInput system.

It has an InputMappingContext and InputActions for it defined in the editor and added to the BP which extends the CharacterController C++ class.

In 5.4, I enabled a Run action with Left Shift such that the player would keep running as long as you hold it down. I binded the event as shown below

PlayerEnhancedInputComponent->BindAction(Run, ETriggerEvent::Started, this, &ACharacterPlayerController::SetIsRunning);
	PlayerEnhancedInputComponent->BindAction(Run, ETriggerEvent::Completed, this, &ACharacterPlayerController::SetIsRunning);

This worked as expected, where when Started happens, it fires with value true (I casted it to boolean using Value.Get()) and false when Completed happens.

However, in 5.5, Started doesn’t work because it fires with value false. I have to update it to Triggered to make it work but it keeps firing multiple times which is not needed.

Is this a bug or an intended change, and what could I do to make it work?
Let me know if additional information is required

UPDATES:
I noticed another weird thing wherein setting it as Triggered only works if I build solution from IDE (VS/Rider) but doesn’t work if I directly start the editor.

6 Likes

Hello, I am having exactly the same situation. Gateweay to my functions execution solely depends on the Started: True and Completed:False, however in 5.5 ETriggerEvent:Started suddenly seems to be turning false thus breaking a lot of stuff in my game.

Is there a bug report for it or you found a solution somehow about it?

Same issue in 5.5. “Started” only returns 0 but “Triggered” is ok. Breaks my snap turning and jumping handlers.

I pretty much just started checking for Triggered on tick but that’s like a stupid polling solution, which ideally shouldn’t be used. I couldn’t find an official bug report so that’s why I reached out here.

Still not fix ?

well I just bind to different events and solve it on my side, however it is indeed still inconsistent from older versions. Started either turning false or nothing at all. A strange behaviour on the blueprints as well.

Yes pretty much, no fixes yet so best solution to make it behave like Started and Completed with value is to bind Started to one method and set it to true in that, and Completed to second method and set it to false in that.

If there are other use cases that don’t work with this approach, let me know. Will try it out on my end if I can.

1 Like

Another way to solve this is to add a Delay Until Next Tick node to the Started pin. Adding latency to the input isn’t the best idea, so hopefully this can get fixed in a future update. One note is that the Triggered execution pin MUST have something attached to it in order for this solution to work

2 Likes

It appears this is still broken in 5.5.1. How is this not a bigger deal?? VRTemplate – Epic’s Own VRTemplate – no longer functions correctly because of this.

6 Likes

Seriously? this isn’t a top priority? It completely broke my multi choice interactions.

2 Likes

same problem, 5.5 broke my game

1 Like

Breaks my game as well, submitted a ticket before finding this thread.

1 Like

Hi Lazy_Lifeguad, can you post the ticket number here so folks can upvote it? I am facing the same issue and I hope it gets fixed soon; I used DelayUntilNextTick as a hack for now before reading the value.

1 Like

This seems to be related to the GetValue function in the Inputaction.h file.
For some reason it returns an empty ActionValue to your bound function if you use started. using triggered will give you the value. not sure why or when this changed.

1 Like

This worked great for me, thanks!

This workaround succeeded for weapon switching if you use different values for different weapons (pistol - 1.0, rifle - 2.0 etc)

After looking through the source code and the relevant changes, it seems like the way 5.5 is working now is by design? Even in 5.4, the GetValue() function for the InputAction started event would only return a non-zero value if the input’s state was set to ‘triggered’. During the started event this would already be set to ‘triggered’ in 5.4 but now the 5.5 code is forcing the started event to just be in the ‘started’ state, so any call to GetValue() returns 0 (or equivalent for vector type).

It seems like the Epic-intended way to handle getting the input value only once is to do it on the triggered event and set the triggered event to only trigger once when you want it to. Setting a “Pressed” trigger type within an InputAction will cause the triggered event to only be fired once when a button is pressed and the value from GetValue() will then be valid during that triggered event.

2 Likes