{"name":"isGamePaused","title":"isGamePaused","type":"command","url":"https://community.bistudio.com/wiki/isGamePaused","revid":349063,"updated":"2023-11-08T14:47:20Z","groups":["System"],"status":"ok","games":{"arma3":"1.96"},"since":"arma3 1.96","arma3_since":"1.96","description":"Returns the state of game simulation. Simulation can get paused by pressing <kbd>Alt</kbd> + <kbd>↹ Tab</kbd> or a system dialog opening (e.g. <kbd>Esc</kbd> menu).\nSimulation will not get paused if `-noPause` startup parameter is used.\n\n> [!NOTE]\n> onEachFrame event and `\"EachFrame\"` event handler continue to execute when the simulation is paused, which could result in undesired backlog. Use isGamePaused to skip loop if needed.","syntaxes":[{"syntax":"isGamePaused","params":[],"returns":{"type":"Boolean","type_expr":"Boolean","description":"returns true if game simulation is paused, false if not"},"form":"nullary"}],"examples":[{"text":"```sqf\nonEachFrame\n{\n    if (isGamePaused) exitWith {};\n    // ...do stuff\n};\n```","code":["onEachFrame \n{\n\tif (isGamePaused) exitWith {};\n\t// ...do stuff\n};"]}],"multiplayer":"In multiplayer the simulation will not get paused and this command will always return false.","see_also":["isGameFocused"]}