very good it looks like you're getting going just fine - good job!
you're issue here is like to do with declaring the 'scope' of the Sound object within the constructor - this is often a 'good' thing to do - so good work, however what this does is creates a 'global' object that controls 'any' sound within the scope designated. since you have declared all of them to be within the scope of 'this' any of the three sounds will 'control' *all* sound objects running within the scope targeted. simply remove the 'this' from each and you should then have individual control of them.
Firstly, Thank you very much for appreciating my shabby work!
I did as you recomend - I fired the 'this' keyword in the constructor.
now, the code part in the decleration is like this:
mySound1 = new Sound();
similarly, I updated the other variables too. [ previously it was " mySound1 = new Sound(this); " ]
But I am still stuck with the same problem! when I click on any other buttons, all sound still stops! may be it would help if you could look at the source file? I realized that I had not attached the source file, so here is the link: Source File.
Thank you very much again!
Any updates on this anyone?
or Am I doing it in a wrong way?
I mean, is there any other way to do this?
okay I did a little trial and error, tried to declare the sound object in several places and finally found out a way to make them work perfectly!!
first, I had to create a movie clip, and code all the lines inside that movie clip,
and while declaring the sound object, initialize the object with 'this' constructor. so the sound object is not stuck to the movie clip.
from then on, it never interrupts any other sounds anywhere else in the movie. I had to write a lil extra lines to make the sound stop and play with the click of same movie clip, but, in the end, i got it to work!!
thanks a lot for helping me out CLBEECH. your hint on constructors really did the trick, I dint realize what I was passing the 'this' operator till you told me!
did a lil trial and error and bent it to my will, finally!
thanks very much again!