如何停止声音?

时间:2010-07-02 19:18:48

标签: flex flash actionscript-3 actionscript flex3

如何阻止这种声音? :

MySound.play(0,100,null);

2 个答案:

答案 0 :(得分:4)

play返回SoundChannel,其中包含stop()方法。请参阅Documentation

  

生成一个新的SoundChannel对象   播放声音。这种方法   返回一个SoundChannel对象   你访问停止声音和   监听音量。

答案 1 :(得分:3)

var soundChannel:SoundChannel = MySound.play(0, 100, null);
...
soundChannel.stop();