📖 Read the Catch the Stars tutorial
The function onCatch runs every time you catch a star. Inside it, score = score + 1 means “add 1 to the score”. You can change what happens when you catch!
🎯 Make every star you catch worth 3 points.
🧺 Your game
Press Play to try your game. Change the code, then press Play again to see the difference.
Lesson 2 of 11 · Lesson map · Your code runs safely inside this page and is never sent anywhere.