I’ve been trying to figure out how to get Makecode to play multiple music notes at a time. I know how to put in the play melody block, and then go into Javascript to make longer songs with multiple pitches of notes, but how do I get Makecode to play two (or three) different notes at the same time?
For example, if I write a bass line for the melody and something higher to play over it, Makecode will just play one one group of coded notes and then play the next set of notes when it’s over. How do I get them to play at the same time?
One way to do multiple notes at once without an extension is to have a “On game update every _ ms” block that increments a variable each time it happens. This variable can be used in a forever loop as "if (variable) = (value) " then it can run code at that time with two of these if statements.