Scusate l'intromissione, ma non è più facile fare così?
Senza inserire un ingestibile onClipEvent.Codice PHP:var mySound:Sound = new Sound(this);
mySound.loadSound("http://www.miosito.it/canzone.mp3", false);
this.onEnterFrame = function () {
var c:Number = mySound.getBytesLoaded();
var t:Number = mySound.getBytesTotal();
var p:Number = Math.floor((c/t)*100);
if (!isNaN(p)) {
this.load_txt = "downloading song - " + p + "%";
}
if (c >= t && t > p && p == 100) {
delete this.onEnterFrame;
this.load_txt = "";
mySound.start();
}
}

Rispondi quotando