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
|
2022-04-26 19:28:42 +02:00
|
|
|
input.onButtonEvent(Button.B, 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)
|