GweTV's Guide To Coding Music

Hello Hopscotchers!

People keep asking me how to code music, and how to code music well. So, I decided to make a guide and shares steps I use to code music on Hopscotch!

inhales

STEP 1

Find music you really like.

You will feel more inspired to code music you like than coding music you don’t like. For me, I like Weezer, Green Day, and Led Zeppelin. You may have seen me code songs by those artists because I like their music.

Gwe's Music Links

https://www.youtube.com/watch?v=ENXvZ9YRjbo
Weezer: Say It Ain’t So

https://www.youtube.com/watch?v=IPeJ7iM55hc
Green Day: Brain Stew

https://www.youtube.com/watch?v=kemivUKb4f4
Weezer: Buddy Holly

https://www.youtube.com/watch?v=erG5rgNYSdk
Weezer: Island In The Sun

https://www.youtube.com/watch?v=okthJIVbi6g
Weezer: El Scorcho (Director’s Cut)

STEP 2

Sheet Music

You can’t code music without sheet music! (unless you have a really good memory)
There are many sheet music websites out there, but the two I use are musescore.com and musicnotes.com. I recommend musescore because the sound quality when you play the demo is better.

Note: Don’t worry about “buying” anything. You can still view the sheet music without buying it.

STEP 3

Timing Between Notes

Since HS uses milliseconds as time between notes, you need to do two things.

  1. Once you have your sheet music, you should find a number in the top left corner (BPM), next to how fast you play the piece

  2. Now, go to https://msu.edu/course/asc/232/song_project/dectalk_pages/note_to_%20ms.html (the conversion website) and find the BPM on the left side, and it should give you a list of notes (quarter, half, whole, dotted half, etc.) with the millisecond conversion.

(Credits to @Hopscotcher for finding this website)

The Conversion Table (credit to AE)
BPM Quarter Dotted Quarter Whole Dotted Half Half Eighth Sixteenth
60 1000 1500 4000 3000 2000 500 250
66 909 1364 3636 2727 1818 455 227
70 857 1286 3428 2571 1714 429 214
76 789 1184 3156 2367 1578 395 197
80 750 1125 3000 2250 1500 375 188
86 698 1047 2792 2094 1396 349 175
90 667 1001 2668 2001 1334 334 167
96 625 938 2500 1875 1250 313 156
100 600 900 2400 1800 1200 300 150
106 566 849 2264 1698 1132 283 142
110 545 818 2180 1635 1090 273 136
116 517 776 2068 1551 1034 259 129
120 500 750 2000 1500 1000 250 125
126 476 714 1904 1428 952 238 119
130 462 693 1848 1386 924 231 116
136 441 662 1764 1323 882 221 110
140 429 644 1716 1287 858 215 107
146 411 617 1644 1233 822 206 103
150 400 600 1600 1200 800 200 100
156 385 578 1540 1155 770 193 96
160 375 563 1500 1125 750 188 94
166 361 542 1444 1083 722 181 90
170 353 530 1412 1059 706 177 88
176 341 512 1364 1023 682 171 85
180 333 500 1332 999 666 167 83
186 323 485 1292 969 646 162 81
190 316 474 1264 948 632 158 79
196 306 459 1224 918 612 153 77
200 300 450 1200 900 600 150 75
206 291 437 1164 873 582 146 73
210 286 429 1144 858 572 143 72
216 278 417 1112 834 556 139 70
220 273 410 1092 819 546 137 68
226 265 398 1060 795 530 133 66
230 261 392 1044 783 522 131 65
236 254 381 1016 762 508 127 64
240 250 375 1000 750 500 125 63
246 244 366 976 732 488 122 61
250 240 360 960 720 480 120 60
256 234 351 936 702 468 117 59
260 231 347 924 693 462 116 58
266 226 339 904 678 452 113 57
276 217 326 868 651 434 109 54
286 210 315 840 630 420 105 53
296 203 305 812 609 406 102 51
306 196 294 784 588 392 98 49
316 190 285 760 570 380 95 48
326 184 276 736 552 368 92 46

STEP 4

Coding

At first, it might take awhile since you’re slowly coding music, but in time, you should get the hang of it. I’ll link a few of my “mashups” for inspiration

Mashups

https://c.gethopscotch.com/p/108dfufat7 (90’s Mashup)
https://c.gethopscotch.com/p/10b405k1k8 (Rock Mashup)
https://c.gethopscotch.com/p/10boo89k6z (Rock Mashup 2.0)
https://c.gethopscotch.com/p/104jh8xukf (Green Day Mashup)
https://c.gethopscotch.com/p/zwxnv4age (Black Sabbath Mashup)
https://c.gethopscotch.com/p/zvi95zuop (Meme Song Mashup)
https://c.gethopscotch.com/p/zw0bvdvsi (Christmas Songs)
https://c.gethopscotch.com/p/zk3b8utgb (Songboard)

STEP 5

Marvel at your awesome work!

Don’t worry if it doesn’t sound like what you want it to be. It takes practice and many hours of coding. It took me 1 year before I had a decent mashup ready lol

exhales

I hope that’s it. Tag me for any questions!

(@omtl)

Related topic: Sustained notes+more notes

27 Likes

Cool! What about music that has no note sheet?

6 Likes

Amazing man. It would sound better if notes could be sustained…

4 Likes

Totally agree

3 Likes

Good job. A good tutorial to link on Set Sound

6 Likes

Yee, it would works with a few Alt songs

4 Likes

Most music out there has sheet music

4 Likes

Thanks!

3 Likes

I’m drawing something up for a music suggestion for hopscotch rn, I hope it gets considered

3 Likes

Ooooooh, what is it?

3 Likes

You shall see soon

1 Like

THE SUSPENSE!

3 Likes

The tutorial we have been waiting for

2 Likes

Yes

You asked, I delivered

4 Likes

This is a great tutorial! I’m definitely going to use the in the future!

2 Likes

Amazing dude! I love the information! Great job!

2 Likes

Thanks!

4 Likes
The Table
BPM Quarter Dotted Quarter Whole Dotted Half Half Eighth Sixteenth
60 1000 1500 4000 3000 2000 500 250
66 909 1364 3636 2727 1818 455 227
70 857 1286 3428 2571 1714 429 214
76 789 1184 3156 2367 1578 395 197
80 750 1125 3000 2250 1500 375 188
86 698 1047 2792 2094 1396 349 175
90 667 1001 2668 2001 1334 334 167
96 625 938 2500 1875 1250 313 156
100 600 900 2400 1800 1200 300 150
106 566 849 2264 1698 1132 283 142
110 545 818 2180 1635 1090 273 136
116 517 776 2068 1551 1034 259 129
120 500 750 2000 1500 1000 250 125
126 476 714 1904 1428 952 238 119
130 462 693 1848 1386 924 231 116
136 441 662 1764 1323 882 221 110
140 429 644 1716 1287 858 215 107
146 411 617 1644 1233 822 206 103
150 400 600 1600 1200 800 200 100
156 385 578 1540 1155 770 193 96
160 375 563 1500 1125 750 188 94
166 361 542 1444 1083 722 181 90
170 353 530 1412 1059 706 177 88
176 341 512 1364 1023 682 171 85
180 333 500 1332 999 666 167 83
186 323 485 1292 969 646 162 81
190 316 474 1264 948 632 158 79
196 306 459 1224 918 612 153 77
200 300 450 1200 900 600 150 75
206 291 437 1164 873 582 146 73
210 286 429 1144 858 572 143 72
216 278 417 1112 834 556 139 70
220 273 410 1092 819 546 137 68
226 265 398 1060 795 530 133 66
230 261 392 1044 783 522 131 65
236 254 381 1016 762 508 127 64
240 250 375 1000 750 500 125 63
246 244 366 976 732 488 122 61
250 240 360 960 720 480 120 60
256 234 351 936 702 468 117 59
260 231 347 924 693 462 116 58
266 226 339 904 678 452 113 57
276 217 326 868 651 434 109 54
286 210 315 840 630 420 105 53
296 203 305 812 609 406 102 51
306 196 294 784 588 392 98 49
316 190 285 760 570 380 95 48
326 184 276 736 552 368 92 46
4 Likes

Thanks!

2 Likes

Yee

4 Likes