While Sinthoras gave you a good example how to equip things, I'll give ya a function which plays your .mid file

Code:

var music_handle;

string para_music;

function play_music(para_music,_loop,_volume)
{
if(!music_handle) { media_stop(music_handle); }

if(!_loop)
{ music_handle = media_play(para_music,null,_volume); }
else
{ music_handle = media_loop(para_music,null,_volume); }
}

//Just call the function like this:
play_music("SA2Death.mid",0,100); //Music will not be looped
play_music("SA2Death.mid",1,100); //Music will be looped


NOTE: The code is not tested! Use it on your own risk

Last edited by Thunder; 07/16/06 09:19.