I am working with a jukebox sort of deal. I have a button they opens up a dropdown list. The song is seleceted and then I want the drop down to disappear on the realease and a set a variable to 1 or whatever. I am having a few problems and I dont know what is wrong with my actionscript.
Heres my script:
Loading the Varible
loadVariables(“variables.txt”,“loadvars”)
Converting Soundfile to Interger
soundfile = Number(soundfile);
Selectiong Button for Song 1
**
on (press) {
soundfile = 1;
}
on (release) {
gotoAndPlay(1);
}
**
Starting the sound works.
Stoping the Sound
**
on (release) {
if (soundfile == 1) {
jukeboxSound.stop(“soundfile_1”);
}
else if (soundfile == 2) {
jukeboxSound.stop(“soundfile_2”);
}
else if (soundfile == 3) {
jukeboxSound.stop(“soundfile_3”);
}
else if (soundfile == 4) {
jukeboxSound.stop(“soundfile_4”);
}
playing=false;
}
**
Can someone tell me what I am doing wrong. Am I not loading the variable correct or is my code to change soundfile wrong?