
-----------------------------------
bored_hacker
Thu Jul 07, 2005 10:11 am

hammer
-----------------------------------
I got bored so I decided to write out the BGM for when you pick up the hammer on Super Smash Bros Melee.

loop
    Music.Sound (270, 200)
    Music.Sound (270, 100)
    Music.Sound (270, 100)
    Music.Sound (270, 250)
    Music.Sound (270, 200)
    Music.Sound (335, 200)
    Music.Sound (270, 200)
    Music.Sound (335, 200)
    Music.Sound (270, 200)
    Music.Sound (335, 200)
    Music.Sound (335, 100)
    Music.Sound (335, 100)
    Music.Sound (335, 200)
    Music.Sound (335, 200)
    Music.Sound (400, 200)
    Music.Sound (335, 200)
    Music.Sound (400, 200)
    Music.Sound (335, 200)
end loop

-----------------------------------
Delos
Thu Jul 07, 2005 12:23 pm


-----------------------------------
Cute.  Try doing something similar to that using the 'play()' command.  And add an exit condition in there (like 'exit when hasch') since infinite loops are never a good idea!

-----------------------------------
TokenHerbz
Tue Jul 19, 2005 2:54 pm


-----------------------------------
How do you know how to make the notes???
i cant make a song, GJ!

-----------------------------------
Delos
Tue Jul 19, 2005 4:02 pm


-----------------------------------
Well, in bored_hacker's method, he used known frequencies of sounds and given lengths to produce a tone that we recognize as a particular note.  For instance, 440 Hz is the note 'A'.  This can be produced using the Music.Sound() command.
On the other hand, using the play command produces a midi-like note, or series thereof.
For example, the scale of D-major is thus:


  play ("4def+gabc+>d")


The '4' stands for a crotchet (quater note), the letters are...well...the notes, the + stands for sharp (- for flat), and the > means up an octave (< for down).

-----------------------------------
[Gandalf]
Wed Jul 20, 2005 11:39 am


-----------------------------------
You also have to keep in mind that when you go up an octave, it stays in effect for the whole song.  So to go back down you need to put a < before the next note.
