How to stop localization changing the engine's language?

In my widgets the way I have input setup is when ‘On Key Down’ happens I see what the display name is of that key, and that determines what the widget will do.
But, when I change the culture to one with Asian characters (e.g. Japanese, Chinese, Korean) then the display name shown is localized to that culture, which means for example if I press the up button on my keyboard, it will now show ‘上’ was pressed instead of 'Up".
Is there a way for UE4 to only change the localization of the text used in game, not everything in the engine?

If I play standalone in the editor I don’t have any problems, it shows the display names of key presses in English even if I change to a different culture. But in a packaged version or PIE, when I change the current culture, it changes the display names of key presses to that culture, causing my problem.

The one thing that seems like it could work is asset groups, but the documentation on that is very limited and I can’t figure out how to set an asset group for widgets only.
I could also go through and manually get the word for each button in those languages and set those up in the same way I setup the English words, but that would be quite time consuming.

1 Like

In my widgets the way I have input setup is when ‘On Key Down’ happens I see what the display name is of that key, and that determines what the widget will do.

It’s generally a very bad idea to branch logic against display strings, as they can change if the language changes (as you’re finding).

If you have a “Key” struct (eg, from calling “Get Key” on a key event), you can use its “Equals” node to compare it against the value of another “Key” struct, which will be a constant value in all languages.

Thanks so much! It works perfectly now.