Repository navigation
Waves
REMEMBER ME TO FINISH THIS WIKI!!
Waves is an extension that lets the user write and play music. Unlike default blocks and commands, Waves is much more complex and allows for way more freedom without having to write any code.
This guide covers everything needed to use the Store custom song function and write a sheet that Waves reads and plays.
A sheet is a huge string that tells Waves how to play the song, which notes to press and what code to run.
The Store custom song function asks for a string array, which is then converted to a huge string and stored as the sheet. The reason for the array is to allow you to organize your sheet, divide it in sections, use shortcuts and write comments. You can use arrays however you may wish, as long as Waves can combine all of it into a single readable string.
The header goes in the start of the sheet. It tells Waves which rules should be applied to sheet-reading to maximize compatibility. It is 6 characters long, 3 characters for each information. If the header is 000150 for example, Waves will set to version 000 and set BPM to 150.
Fields are 3-character long and are considered either a note or command.
A note field tells Waves what note to play for how long.
- Character 1 tells the note, which can be one of these: C, c, D, d, E, F, f, G, g, A, a, B
- Character 2 tells the octave, a value between 0 and 4
- Character 3 tells the duration. It's a value between 1 and 9, but outputs the lenght of a beat divided by it
- To make a note longer than a beat, D means double, T means triple and Q means quadruple
A command field tells Waves what command to execute according to its first character.
- Character 2 tells what timbre to switch to
- 0 = Square wave
- 1 = Triangle wave
- 2 = Sawtooth wave
- 3 = Sine wave
- 4 = Noise
- Also, if character 2 is "S", you can set the slide effect to on (1) or off (0)
- Character 3 tells what volume effect to apply
- 0 = None
- 1 = Slight fade-out
- 2 = Fade-out
- 3 = Slight fade-in
- 4 = Fade-in
The following two characters decide how many times the loop will happen, so if I write @05 the section will:
- Repeat
05times - Remember this field as the starting point of the looping section
To define the end of the looping section, write @... When the two dots are read, the song reader goes back to the starting point.