How to make or add music.

So I’m a newb when it comes to lua and CODEA. I’m Curious if it’s possible to make or add music to a game. Thanks! :slight_smile:

You can make your own sounds. There is something about in the sounds example. To add music or sounds to a game you just type sound() and put the name of the sound within the parenthesis . You have to import your music to the codea library I believe if you want to use it.

Hi @Bartleycollin, Codea supports particular and random sound effects as well as pitches. Playing imported audio data is more experimental at the moment, but can be done. Tunes can be played using this library of mine: http://twolivesleft.com/Codea/Talk/discussion/225/abcplayercodea-play-music-in-your-project#Item_59

Check out also the sound() documentation and the advanced sound picker, as well as the sound-related threads.

Hi @Fred, what software do you suggest to compose music to be then exported in abc notation? Does it exist something that works also on iPad? Sorry but I’m pretty ignorant about that, but really interested in!

Hi @shrike, there are lots for different platforms listed on the ABC notation website, http://abcnotation.com

I like converting from MIDI to ABC using , which you can find at: http://www.midicond.de/Freeware/index_en.html#MidiZyx2abc

Or you can just write it out by hand…
| e d c d | e e e2 | d d d2 | e e e2 | e d c d | e e e e | d d e d | c4 ||

:slight_smile:

Hi @Fred, thanks a lot, I’ll give a check to MidiZyx2abc soon!

@Fred Just curious, what program do you use to compose MIDI files?

Hi ChrisF, there are lots of choices including free ones. I use Apple’s Logic Pro, which does everything!

@Fred It won’t let me copy and paste your abc player code. Any Suggestions?

Hi @Bartleycollin, what do you mean?