Código :
var sonido:Sound = new Sound();
sonido.loadSound("1.mp3", true);
sonido.loadSound("2.mp3", true);
sonido.setVolume(100);
sonido.start(0, 1);
this.tituloMP3.text = "song1 <performances by enigma>";
this.tituloMP3.text = "song2 <performances by enigma>";
precarga = function (cual) {
this.createEmptyMovieClip("indicador", 10);
this.indicador.clear();
this.indicador._x = 172;
this.indicador._y = 600;
this.onEnterFrame = function(Void) {
var cargado = this.sonido.getBytesLoaded();
var total = this.sonido.getBytesTotal();
this.indicador.lineStyle(2.5, 0x666666,100);
this.indicador.moveTo(0, 0);
this.indicador.lineTo(190, 0);
if (cargado == total && total>50) {
delete this.onEnterFrame;
} else {
var x = Math.round((cargado*100/total));
this.indicador.lineStyle(2, 0xFF9D00,100);
this.indicador.moveTo(0, 0);
this.indicador.lineTo((1.35*x), 0);
}
};
};
precarga(sonido);
var miXML:XML = new XML();
miXML.ignoreWhite = true;
miXML.load("canciones.xml");
var format:TextFormat = new TextFormat();
format.bold = false;
format.font = "Verdana";
format.size = 8;
creaMenu = function(Void) {
createEmptyMovieClip("menu", 5);
menu._x =400;
menu._y =580;
for (var i = 0; i<=miXML.firstChild.childNodes.length-1; i++) {
menu.createEmptyMovieClip("boton"+i, i);
menu["boton"+i]._y = i*11;
menu["boton"+i].createTextField("boton", 1, 0, 0, 1, 1);
menu["boton"+i].boton.autoSize = true;
menu["boton"+i].boton.selectable = true;
menu["boton"+i].boton.setNewTextFormat(format);
menu["boton"+i].boton.textColor = 0xFF9D00;
menu["boton"+i].boton.text = miXML.firstChild.childNodes[i].attributes.titulo;
menu["boton"+i].ruta = miXML.firstChild.childNodes[i].attributes.ruta;
menu["boton"+i].titulo = miXML.firstChild.childNodes[i].attributes.titulo;
menu["boton"+i].onRelease = function(Void) {
this._parent._parent.tituloMP3.text = this.titulo;
sonido.loadSound(this.ruta, true);
sonido.start(0, 1);
precarga(sonido);
};
menu["boton"+i].onRollOver = function(Void) {
format.underline = true;
this.boton.setTextFormat(format);
};
menu["boton"+i].onRollOut = this.menu["boton"+i].onReleaseOutside=function (Void) {
format.underline = false;
this.boton.setTextFormat(format);
};
}
}
miXML.onLoad = creaMenu;
this.iniciar.onRelease = function(Void) {
sonido.start(0, 1);
};
this.parar.onRelease = function(Void) {
sonido.stop();
};
this.anterior.onRelease = function(Void) {
sonido.start(0, 1);
};
this.siguiente.onRelease = function(Void) {
sonido.start(0, 1);
};usa las etiquetas code para postear tu codigo
