Shoot down the asteroids, and don't crash into them. Aim with the mouse, press space to fire. WASD keys move the spaceship. The score goes down over time, but goes up when you hit an asteroid. The game ends if your score reaches 0 or you get hit by an asteroid.
Learn to program games with this free online Scratch course: https://inventwithscratch.com/class Version 2 of this game has a limited ammo feature.