joeri
08-15-2002, 08:07 PM
Hi,
I tried to load a sound and manage it with some buttons but it didn't really work......???
I did the following :
sound_object = new Sound();
sound_object.loadSound("music/mymusic.mp3",false);
On the buttons(on a other layer) that should control the sound I placed the following script :
//button1
on(release){sound_object.start();}
//button2
on(release){sound_object.stop();}
I used false in the load statement because the file eventually is stored onto a cd-rom, so a streaming sound is out of the question.
Perhaps I should use the attachSound() method??
And is the sound palyed automatically when you load it?Should I therfore use a stop action directly when I load it?
Thanx, Joeri
I tried to load a sound and manage it with some buttons but it didn't really work......???
I did the following :
sound_object = new Sound();
sound_object.loadSound("music/mymusic.mp3",false);
On the buttons(on a other layer) that should control the sound I placed the following script :
//button1
on(release){sound_object.start();}
//button2
on(release){sound_object.stop();}
I used false in the load statement because the file eventually is stored onto a cd-rom, so a streaming sound is out of the question.
Perhaps I should use the attachSound() method??
And is the sound palyed automatically when you load it?Should I therfore use a stop action directly when I load it?
Thanx, Joeri