Revert "Removed the game's automatic pausing when window focus is lost."
This reverts commit d4ff9213b5
.
This commit is contained in:
parent
46a80eb30b
commit
e4664b9b1a
|
@ -250,6 +250,11 @@ void getPlayerInput()
|
||||||
engine.keyState[KEY_RIGHT] = prevjoyright = joyright;
|
engine.keyState[KEY_RIGHT] = prevjoyright = joyright;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case SDL_WINDOWEVENT:
|
||||||
|
if(engine.event.window.event == SDL_WINDOWEVENT_FOCUS_LOST)
|
||||||
|
engine.paused = 1;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (engine.keyState[KEY_FULLSCREEN])
|
if (engine.keyState[KEY_FULLSCREEN])
|
||||||
|
|
Loading…
Reference in New Issue