stop();
loadMovie("song/componenti/x.swf", "target");
var pausa:Number = 0;
var intervallo:Number = 100;
var rilevaPlay:Boolean = true;
suona = new Sound(_root);
suona.loadSound("song/03.mp3",true);
suona.onSoundComplete = function() {
suona.loadSound("song/03.mp3",true);
};
//
i = 50;
suona.setVolume(i);
vol = i;
musica = true;
x = 401;
//
var interval = setInterval(progressSound, intervallo, suona);
//
function progressSound(sound:Sound):Void {
pausa = sound.position/1000;
}
//
btn.onPress = function() {
if (rilevaPlay) {
suona.stop();
rilevaPlay = false;
loadMovie("song/componenti/play.swf", "target");
} else {
suona.start(pausa);
rilevaPlay = true;
loadMovie("song/componenti/x.swf", "target");
}
};
//
volbtn1.onPress = function() {
if (i<100) {
i = i+10;
suona.setVolume(i);
vol = i;
}
if (x<424.6) {
setProperty("volume", _x, x+7);
x = x+7;
}
}
volbtn2.onPress = function() {
if (i>0) {
i = i-10;
suona.setVolume(i);
vol = i;
}
if (x>377.4) {
setProperty("volume", _x, x-7);
x = x-7;
}
}