Handling Unfocused State in UE4 Windows Packages (Sound Playback, GamePad Input)
Behavior When Unfocused I use UE4 for non-game purposes at work, often alongside other applications on Windows. A common pattern is creating the display part with UE4 and a controller-like part with WPF, then using them together. In this pattern, the focus inevitably goes to the WPF application, leaving the UE4 window unfocused. This caused the following problems: Sound cannot be heard GamePad input cannot be captured I couldn’t find solutions for these for a while, but after checking the Engine source, I found countermeasures for both, so I’m writing them down as a memo. ...