PDA

View Full Version : a little help about UnloadMovie



#Angel
October 27th, 2004, 08:26 AM
I'm a new guy in here and my english is not that well, so please be kind :)

Can anyone help me to use UnloadMovie in this Script? I use Flash MX 2004.

knap_array = new Array();
allOff = function () {
var len = knap_array.length;
for (var i = 0; i<len; i++) {
this[knap_array[i]].gotoAndStop(1);
this[knap_array[i]].down = false;
}
};
newButtonDef = function (name, method, value, target) {
this[name].onRollOver = function() {
if (!this.down) {
this.gotoAndStop(2);
}
};
this[name].onRollOut = function() {
if (!this.down) {
this.gotoAndPlay(4);
}
};
this[name].onPress = function() {
allOff();
this.gotoAndStop(3);
this.down = true;
};
if(method == 0){
this[name].onRelease = function() {
gotoAndPlay(value);
}
}
if(method == 1){
this[name].onRelease = function() {
gotoAndStop(value);
}
}
if(method == 2 && isNaN(target)){
this[name].onRelease = function() {
loadMovie(value, target);
}
}else if(method == 2){
this[name].onRelease = function() {
loadMovieNum(value, target);
}
}
if(method == 3){
this[name].onRelease = function() {
getURL(value, target);
}
}
knap_array.push(name);
};
newButtonDef("forside", 1, "unknown");
newButtonDef("nyheder", 1, "unknown");
newButtonDef("profil", 1, 153);
newButtonDef("showcase", 1, 154);
newButtonDef("referencer", 1, "unknown");
newButtonDef("tutorials", 1, 155);
newButtonDef("kontakt", 1, "unknown");
newButtonDef("links", 1, "unknown");
newButtonDef("forum", 1, "unknown");
newButtonDef("gæstebog", 1, "unknown");