Workshop › Endless Runner › Step 10 of 19
The world should not start rushing before the player is ready. The game has a state; it starts as 'ready' and the
first jump switches it to 'running'.
```js
let state = 'ready' // 'ready', 'running' or 'over'
state = 'running'
if (state !== 'running') return
ctx.textAlign = 'center'
if (state === 'ready') {
ctx.font = '16px sans-serif'
ctx.fillText('Press Space to start', canvas.width / 2, canvas.height / 2)
}
```update returns at once unless running, so nothing moves or spawns before the start.runner, write state.state = 'running' the first line of jump.update, with an empty line after it.draw, write the ready message.Skills: Game states