Fix inactive controller inputs being taken
@@ -394,6 +394,9 @@ private void setupTarget(InputEvent event) {
}
private void processControllerInput(float delta) {
+ if(!display.hasFocus()){
+ return;
+ }
for (ControllerAction action : controllers.getInputQueue()) {
// TODO: send event to entity system
boolean consumed = false;
