The classic game of Hot Potato is a great one for kids to explore how to translate the rules of a game to a program. It is a good starting point for thinking about any coding project: what are the rules/requirements; what are my resources; how can I break the problem down into smaller steps. We'll walk through this program one block at a time.
Sphero has an algorithm that allows it to determine when it is experiencing a freefall event and you can then make something happen when that event occurs.
mainLED using the colorRandom variable valuemainLED color to the colorRandom variable valueWhen you lose the game (the Sphero lands in your hands and the numTime is decremented to 0) these blocks will execute.