I’ve got a group of buttons that don’t navigate but show a tool tip. I have some of the functions working fine but can’t seem to get my current button to stick.
What am i overlooking here?
fla: http://themachinedistrict.com/nav/nav.zip
stop();
var swatches:Array = [
protectedAreas_mc,
renewableEnergy_mc,
whaleMigration_mc,
SMH_mc,
comFish_mc,
recFish_mc,
oilGas_mc,
tourRec_mc,
cruiseShips_mc,
shippingLanes_mc
];
var activebtn:MovieClip;
function hover (){
this.gotoAndStop(6);
}
function out (){
if (this != actviebtn){
this.gotoAndStop(1);
}else{
this.gotoAndStop(6);
}
}
function current (){
var prevbtn:MovieClip = activebtn;
prevbtn.onRollOut();
this.gotoAndStop(6);
activebtn = this;
}
function init() {
for (var mc in swatches) {
swatches[mc].onRollOver = hover;
swatches[mc].onRollOut = out;
swatches[mc].onRelease = current;
}
}
init();
Thanks