Monday you turn Happy Accelerometer into Happy Balance — a game that talks to you when you lose. Today: hear the sounds, play the finished game, and plan where sound goes in your game. About 20 minutes.
These are the actual four sound files you'll upload on Monday. One per edge. Turn your sound on and tap each one.
Sound ID. I'll play one. Which edge was it? Four rounds.
This is what you're building. Keep the face in the middle. Hit an edge and it tells you which edge — by name — then the sad face shows and you get asked to play again. Arrow keys, the buttons, or tilt your phone.
Play again?
The log on the right is the event handler firing. Watch the edge number — you'll need it in step 3.
App Inventor hands your handler a number called edge. Tap each edge of the phone to learn its number, then answer the four checks.
One handler, four edges, four sounds. Tap a chip, then tap the slot it belongs in. A chip can be used once.
One more. You could also write this as four separate if blocks with no else. The lesson says the chain is better. Why?
A Sound component lives in the Media drawer. It's non-visible. You upload a file to its Source property and play it with call Sound.Play. Where does sound belong in the game you built? Two moments, in WHEN / DO form.