Skip to main content
Inspiring
Mar 15, 2024 8:55 PM UTC
Question

why does it play both of audios together after some seconds in sheet music animation

hello there here i send atached the situation

its working the sheet music animation but

after some seconds it plays both audios

from movie clips....

whats the action script to use here in this situation

to stop the audio when the other plays?

 

    This topic is closed to new replies. Start a new post to keep the conversation going.

    100 replies

    Inspiring
    Mar 15, 2024 9:03 PM UTC

    i found this

     

    sound.addEventListener(MouseEvent.CLICK, fl_ClickToStopAllSounds);

    var sc:SoundChannel;

     

    function fl_ClickToStopAllSounds(event:MouseEvent):void

     

    {

        SoundMixer.stopAll();

    var newSound:NewSound=NewSound();

    sc=newSound.play();

    }

     

    how is it used ? with the action script of the button?

    Translate
    kglad
    Community Expert
    Community Expert
    Mar 16, 2024 12:52 AM UTC

    if you're playing your sounds by streaming the sound attached to a timeline, you just need to stop that timeline.  ie, 

     

    sound1_graphic.stop();

     

    Translate
    Inspiring
    Mar 16, 2024 9:58 AM UTC

    i made movie clips and it worked........

    couldnt it be sound1_movieclip.stop();?

    thanks man

    Translate