Variables to Control Sound


I had this idea that would make Music a lot easier to program in Hopscotch. It would be cool to see variables able to be put into sound blocks (where the note is) by assigning values to each sound

We’d use this for piano recorders or Siri Shortcut json mods :wink:

Same as point 1?

Example design by JSON Free Edit:

Other programming languages? They don’t really use sound like that…

Another idea very closely related to this:
Make specialized variables? Instead of one set variable block in the editor, you can use set “to number”, set “to string”, “to color”, “to sound”.

Format: Set (variable) to string (<text field>)


Yes! Definitely!


Yes! Amazing idea.

1 Like

A long time ago, back when the editor layout was still Hopscotch 2.0, you could actually copy the sound and paste it into a text block to see what the sound was called. For example, “bubbles”, “roar”, or “sharp C”.

1 Like

That’s not what I mean. Each sound should have a number value so I think can be controlled with a variable


I know, but it could help when using a variable to set the sound. The problem is that in Hopscotch, variables can only support numbers, unlike in Scratch, where they can support all characters.

1 Like

Yeah, hence my secondary idea, then you could slide without number values. But numbr values are better, because you can randomly select a sound, etc.

1 Like

Yes. However, variable strings would still be amazing.


(I like the secondary idea a lot too)

1 Like

So basically data types in Hopscotch? I like this idea, but it could be confusing for beginners. It would help to keep projects organized, though, as well as adding some nice functionality :wink:


Yeah, under “set variable”. Set variable to string, etc. etc. all as separate blocks