isPaused property
Whether the engine is currently paused or running.
Implementation
bool get isPaused => _isPaused;
Pauses or resumes the engine.
Implementation
set isPaused(bool value) {
_isPaused = value;
final gameLoop = _gameRenderBox?.gameLoop;
if (gameLoop != null) {
if (value) {
gameLoop.stop();
} else {
gameLoop.start();
}
}
}