我遇到了聲音問題。我正在動態加載它,url來自flashvars。 應用程序正在工作,但stil給出錯誤,未處理的ioError。但我已經處理了它。Actionscript 3聲音ioError問題
` VAR的聲音:聲音=新聲音()
try{
sound.load(new URLRequest(req));
} catch(e:IOError){
trace("catch ioerror");
}
sound.addEventListener(IOErrorEvent.IO_ERROR, function(evt:IOErrorEvent):void { trace("error:",evt) });
sound.addEventListener(Event.COMPLETE, function(e:Event):void{
channel = sound.play(0,int.MAX_VALUE);
});`
該行是循環。是否需要嘗試catch塊,如果加載,事件將觸發。你們試過了嗎? – atilkan 2011-05-20 08:56:31