arrow_back Theme Music
In this add-on, you’ll program music that will play while your models walk in the fashion show. To get started, click on the stage backdrop.
Next, click on the sounds tab on your project, then on “choose new sound from library.”
You’ll find many different sounds there that you can use in your program.
There are different categories of sounds. Click on the “Music Loops” category on the left to see different music loops, or short sections of music tracks. These loops are longer than other sounds. Press the “play” button on each sound to hear it. When you find a song you like, click on it, then click “OK.”
You can now add the new song you chose to your project. To do that, click on the scripts tab, click on the Sound menu, and drag out a “play sound until done” block from the sound menu into the script editor. The “play sound” block plays a specific sound without pausing the rest of the code. This block is mostly used for quick sound effects. The “play sound until done” block, on the other hand, pauses the rest of the code until the sound has finished playing. For this example, using a “play sound until done” block will prevent your background music from being cut short.
Since you want the music to play continuously during your fashion show, select a forever loop from the control menu, and place it around your “play sound” block. To make this code start when your fashion show starts, add a “when green flag clicked” event to the top of this code stack. Click to the flag to test your code.
The music plays! It’s a little loud. To fix this, drag out a “set volume to” block from the sound menu, and put it at the top of the “forever” loop. The “set volume to” block sets the volume level. Change the value to something smaller than 100%.
Tinker with the number until you have something that you like. This example uses 50%.
Now when you click the green flag, the music plays and it sounds like it’s in the background.
Now, it’s your turn. Add a sound from the sound library.
Add “play sound until done” and “set volume to” blocks inside a “forever loop.”
Don’t forget to add the “when green flag clicked” event so the music will play when your fashion show begins.