Lesson 3 +10 XP

Your First Sounds

To make a sound, use the sound function with the name of a sound inside quotes.

The sound function


strudel
sound("casio")

casio is one of many standard sounds. Try a few others:


strudel
sound("insect")

Sounds to explore


strudel
sound("wind jazz metal east crow casio space numbers")

You might hear a little pause the first time while a sound loads.

Pick a sample with :

A single sound can contain multiple samples (audio files). Select one by appending : and a number:


strudel
sound("casio:1")

Try different sound / sample-number combinations. Not adding a number is the same as :0.

Sounds are patterns

A sound name is a value. Pass several names separated by spaces and Strudel plays them in sequence:


strudel
sound("bd hh sd hh")

Notice how the currently playing sound is highlighted in the code and visualized below.

TL;DR

  • sound("name") plays a sound.
  • name:0, name:1, name:2 pick different samples.
  • :0 is the default if you don't write a number.
  • Spaces in the string make a sequence.