Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sound object not working in _root movie

Status
Not open for further replies.

tilotama

Programmer
Aug 24, 2001
25
MY
I have a movie called MovSound. The movie 'MovSound.swf' contains a movieclip called Mov which is the container/target for another movie called Sound.swf. i.e, Sound.swf will be called into the movie MovSound.swf via the following script:

loadMovie ("Sound.swf", "Mov");

Sound.swf contains a sound object with the identifier Sound1, and called into the movie thru the following script:

firstSound = new Sound();
firstSound.attachSound("Sound1");
firstSound.start(0,999);


this script worked fine when Sound.swf was played on its own, however when i tried to play it in movie MovSound, the animations worked(movie loaded into main movie), but the audio effects just wouldnt.
i know that it had something to do with the sound object's path(_root.Mov.Sound1(?)). i have tried without success :(
can anyone help?
 
Although MM says the parameter is optional, try adding this to your soundObject definition:

firstSound = new Sound(this);
...

Usually works!
Regards,

oldman3.gif
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top