In this add-on, you will play a tune and use graphic effects like mosaic and color to makeyour program more entertaining. To start, add a new backdrop. Click the stageand the backdrops tab. Choose a backdrop from one of the options.
Next change this backdrop using an effect. From the “looks” menu, drag the “changeeffect” block into the scripts area. Click the dropdown to see the different choices.
Select an effect and click the block to try it out. To reset the backdrop, click the “cleargraphic effects” block in the palette.
Select “color,” and click on the block. This block changes the stage’s color.
Make this effect happen over and over with a loop. A loop is a block that repeats theactions inside it. Click the control menu. Drag a “forever” loop around the “changeeffect” block. Click the stack to try it out . The colors keep on changing!
To run this code at the start of the program, place a “when flag clicked” block at thetop of the stack. Make your project more exciting by addinga sound. Click the sounds tab and “choose sound from library.” Click the play buttonto listen to a few sounds. When you find a sound you like, click on it,and select “ok.” Select the scripts tab, and from the “sound” menu, drag a “playsound until done” block into the script editor. From the dropdown, select the soundyou chose. Click on the block. Nice. Drag out a “forever” loop to make thesound repeat. Now that’s a sweet beat! If your sound loop doesn’t sound right,make sure you used a “play sound until done” block. The “play sound until done” blockwill play the sound all the way through before running any other code. The “play sound”block, on the other hand, will run the next block while the sound is still playing, whichmay sound awkward in a loop. Finally, add a “when flag clicked” blockto the top of this stack. Click the flag to start your program. The backdrop color changesAND the sound you added repeats over and over. Now, it’s your turn:Change the backdrop’s look by selecting the “stage" and using the “change effect”block. Add a sound by clicking on the “sounds”tab and using a “play sound until done” block.
Add “forever” blocks to each block stack to run the code over and over.
Finally, add “when flag clicked” blocks to the top of the block stacks.