2019-12-02 05:58:26 +01:00
|
|
|
# is Paused
|
|
|
|
|
|
|
|
Find out if the game is paused or not.
|
|
|
|
|
|
|
|
```sig
|
|
|
|
game.isPaused()
|
|
|
|
```
|
|
|
|
|
|
|
|
## Returns
|
|
|
|
|
|
|
|
* a [boolean](/types/boolean) value that is `true` if the game is paused or `false` if not.
|
|
|
|
|
|
|
|
## Example
|
|
|
|
|
|
|
|
Resume the game if it's paused and button **B** is pressed.
|
|
|
|
|
|
|
|
```blocks
|
2023-01-11 18:51:27 +01:00
|
|
|
input.onButtonEvent(Button.B, input.buttonEventValue(ButtonEvent.Down), function () {
|
2019-12-02 05:58:26 +01:00
|
|
|
if (game.isPaused()) {
|
|
|
|
game.resume()
|
|
|
|
}
|
|
|
|
})
|
|
|
|
```
|
|
|
|
|
|
|
|
## See also
|
|
|
|
|
|
|
|
[is running](/reference/game/is-running),
|
|
|
|
[is game over](/reference/game/is-game-over)
|