Workshop › Whack-a-Mole › Step 9 of 18

Show the score

What we are doing

The score goes in the bar at the top.

```js
ctx.fillStyle = 'white'
ctx.font = 'bold 20px sans-serif'
ctx.textAlign = 'left'
ctx.fillText('Score: ' + score, 12, 28)
```

What it means

Your turn

At the end of draw, after the holes loop, write the four lines.

Skills: Drawing on a canvas

All steps

  1. A green field
  2. Nine holes
  3. Draw the holes
  4. A clock and a loop
  5. A mole in a hole
  6. Moles pop up
  7. Which hole was clicked?
  8. Whack!
  9. Show the score
  10. Click to start
  11. Time's running
  12. Time's up
  13. Best score
  14. How far into the round?
  15. Faster and faster
  16. Remember each hit
  17. Floating +1
  18. Build it yourself: combos