Here’s the pseudocode of practically what i want to do.
I have a few buttons, each attached with a different sound. Lets say i’ve clicked button A and then i click on button B…the sound must stop…and its the same for the other rest.
I cannot use stopAllSounds for each button when they are clicked because there will be a background music running. Does anyone know how to do this and could tell me how ???
Really need help desperately…Please please please… :(((
you could try this:
[AS]on (release) {
this.mySound.stop(current);
this.mySound = new Sound();
this.mySound.attachSound(“newsong”);
current = “newsong”;
this.mySound.start("", 99);
}
[/AS]
maybe i wasn’t clear.
there’s button A with my code. it tells the current sound to stop en “newsongA” to play and it sets “newsongA” to current.
on buttonB the same, if you press this it will stop current (newsongA) and play newsongB and sets this to current…
ad so on.
btw i used the attach sound, made a fla with all the sound in it and load that in my main movie.