Skip to content

Please update your browser

Your browser version is not supported by this site. CS First may not work properly. Learn more

Transcript

One of the great aspects of the computer science community is that you can borrow and remix other people’s ideas. One way to do this in Scratch is by using the backpack. In this add-on, you’ll add a fireworks sprite to your backpack, then add it to your program, and decide when to run its code.

Click the fireworks link next to the introduction video on this page. This project contains a fireworks sprite that already contains code. Click the flag to run the code.

Wow! That's pretty awesome. Next, make sure that you’re signed in to Scratch. If you’re not signed in, you won’t be able to add the firework to your backpack.

Open the backpack by clicking the backpack menu at the very bottom of the screen.

If you’ve never added anything to your backpack, it will be empty.

Click and drag the fireworks sprite into your backpack.

Next, switch back to your original project, make sure your work is saved, and refresh the page. Open your backpack again, and drag the fireworks sprite into your project. Click the flag to try it out.

Awesome, the fireworks sprite and all of its code is now copied into your project! It’s pretty distracting to have fireworks playing for the entire program though, so decide when you want these fireworks to play. In this example, the fireworks will play at the end of the story. To do this, broadcast a new message at the end of the story, which is the bottom of the “conclusion” block stack. Call the message something like “end.”

Then, select the fireworks sprite. Replace the “when flag clicked” block with a “when I receive” block, and change the value to “end.”

To play the fireworks during the middle of the story, select a different message, like body or conclusion. Click the flag to test.

Great! The fireworks play at the right time in the story!

Now, it’s your turn: Open the fireworks project next to this video.

Be sure that you’re signed in to Scratch, open your backpack, and drag in the fireworks sprite. Switch back to your original project, refresh, and drag the sprite out of your backpack. Program the fireworks to run by broadcasting and receiving a message.

Scegli un’estensione
Cambia scena
Cambia l'ambientazione in ogni parte della storia.
Modernizza il design della tua invenzione
Personalizza il costume dello sprite come desideri.
Fuochi d'artificio
Aggiungi nella valigetta uno sprite Fuochi d'artificio, poi inseriscilo nel programma e decidi quando eseguire il codice.
Proteggi la tua idea
Chiedi al pubblico di non condividere con nessuno le idee contenute nella tua storia.
Alza il volume
Aggiungi un brano musicale nella storia e imposta volumi diversi nelle varie parti.
Interattività
Rendi interattivo il finale della presentazione ponendo una domanda al pubblico e rispondendo di conseguenza.
arrow_backward Indietro
Avanti arrow_forward
Istruzioni
1. Scegli i componenti aggiuntivi e crea!