Skip to content

Please update your browser

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

arrow_back Riproduci suono se preso

Transcript

Games often use sound effects to increase excitement. In this screencast, you will learn how to add sound to your game that will play if the chaser catches the player. Watch this screencast to learn how to add sound, then try it on your own.

To start, click on Chaser 1, then the sounds tab. Select “choose sound from library.”

Test a few sounds by clicking on the play buttons.

Once you’ve found a sound you’d like your game to play when a chaser catches the player, select it and click “OK.”

Great! Now your project has sound, but, you still need to create the code that will tell the computer when to play it.

In a previous screencast, you programmed an if statement to sense if the chaser was touching the player. You can use this same if statement to play the sound you just picked.

Click on the scripts tab, and click on Sound.

Drag out a "play sound" block from the sound menu, and place it in your block stack before the "say" block that makes the chaser say the time left in the game.

Remember, in computer science it’s important to test your code often to make sure it’s working the way you want. Test your code now.

[screeching sound] When the chaser catches the player, the sound you chose should play.

[screeching sound] Now, it’s your turn. Be creative and have fun adding sounds to your Scratch project!

If you get stuck along the way, ask your neighbor for help or put up your sticky to get the attention of your CS First Guru.

Scegli un’estensione
Riproduci suono se preso
Aggiungi un suono al tuo gioco e programma il progetto a riprodurre quel suono.
Gioca con un amico
Programma uno sprite affinché sia controllato da un altro sprite.
Cambia il giocatore
Cambia il costume del giocatore quando tocca un altro sprite.
Accelera la caccia
Rendi più difficile il gioco velocizzando l'inseguimento.
Punteggio alto!
Crea una nuova variabile che memorizzi l'attuale punteggio più alto.
arrow_backward Indietro
Avanti arrow_forward
Istruzioni
  1. Fai clic su qualsiasi casella per andare al video sui componenti aggiuntivi.
  2. Quando hai terminato, torna sulla schermata dei componenti aggiuntivi e prova un altro componente aggiuntivo!