Very annoying problem with creating an in-game pause menu with UMG

Hello, I currently have a very annoying problem that I have encountered with the 4.8.3 version of UE4.

I’ve been using the UMG documentation to create an in-game pause menu ( https://docs.unrealengine.com/latest/INT/Engine/UMG/QuickStart/5/index.html ). My Blueprint is highly similar to the one shown in the documentation. Now onto the problem. When I pause the game, the pause menu comes up and everything is working as it is intended. However when I un-pause the game, any movement key that was held when the game was paused is stopped and won’t allow you to move unless you release the key which you had held in the pause menu for your character to move.

So say you’re moving and you’re holding down the W key to move and you want to pause the game. When you pause the game you still haven’t let go of the W key, when you un-pause the game while still holding W to move after the game is un-paused you stop moving forward unless you let go of the key to move again.

This issue doesn’t happen if I remove the “Set Input Mode UI and Game only” node but that requires the player to click on the screen for the mouse to focus on the widget. It also doesn’t happen if I remove the “Create Widget” node but that doesn’t bring up the pause menu when the game is paused.



Can you post a picture of how you are handling the player’s movement?

Here is how the player movement was done.

After you Unpause while holding W, is the InputAxis MoveForward event firing?

It still fires. Though it isn’t limited to only moving forward. Its not limited to only moving forward. It also happens if I go in any direction.

I know this is going to sound silly, but… why would the player still be holding down “W” key if the player pauses the game? I don’t think I’ve ever once done that in any game I’ve played (held onto any key during pause screen).

> ‘Paused?’

Lol, I like to prefix my booleans with is so like: isPaused, true or false. A little easier to read :wink:

So if I understand this correctly, you only experience this issue while the key is being held down while they pause it? Very odd. And Victor, yeah it seems silly but you can’t trust your users to not try to break it because they will find a way :wink:

@TheFoyer Oh, yeah Its a personal thing regarding the names.

“So if I understand this correctly, you only experience this issue while the key is being held down while they pause it?”
Pretty much. I’ve been trying to solve it for a week now.

@Victor
"but… why would the player still be holding down “W” key if the player pauses the game? I don’t think I’ve ever once done that in any game I’ve played (held onto any key during pause screen). "
I and many others do this plenty of times though. If I pause the game, I always hold whatever direction I move in to have that preemptive advantage. If I wanted to study a bosses’ pattern to know the exact moment he does an attack, being able to pause and hold down the key for movement or the key for blocking/any other important action then it will be massively helpful and will me allow to counter that pattern/move which helps me learn more about the boss.

There are many uses for such a feature.

When this bug is occurring with W, what is the Axis Value of Move Forward?

I think you’ve found the cause of the problem. Because the value is reset when I pause the game.

Yo, how do you find out the value if it’s paused and you’re in game? Unless you’re hovering over the variable output…probably…nvm.

@Victor
I printed the value out in-game.

Oh, even easier! Cool, things people don’t think about at the moment, but might come in handy if I am debugging something later:) ty

But back to that value…isn’t it going to be 0 because the game is paused? Or while paused does it still show up the “pressed” value

Nope, mainly because I enabled the axis event to be executed while it’s paused. When I make a pause feature without the “Set Input Mode Game and UI only” or “Create Widget” node then I am able to move forward after un-pausing without this bug.

Yeah, I am noticing what you are talking about now, I am looking at an old pause screen of mine. Like I said, I never pause with any key held. So I never noticed it.

I still haven’t been able to find a solution to this very annoying problem. I tried to use the “Set Tickable when Paused” node but that still doesn’t work.

Have you tried to Enable/Disable “tick when paused” on even node itself? I mean in properties of the Event node itself.
Another option is to change your input to discrete button press instead of Axis input and see if that works.
Another option is to use your input to flip some Boolean flags and use those to decide if you should move or not.

“Have you tried to Enable/Disable “tick when paused” on even node itself? I mean in properties of the Event node itself.”
I’ve made sure to set the “Set Tickable when Paused” node’s boolean to true.

“Another option is to change your input to discrete button press instead of Axis input and see if that works.”
I don’t quite know what a discrete button press is in UE4 unless you mean movement being assigned to a key on the keyboard rather than an axis event.

“Another option is to use your input to flip some Boolean flags and use those to decide if you should move or not.”
I tried that option before though it didn’t work either.

Yes, I mean assigned to key press instead of axis input.