Knappekode flash

Dette er scriptet for alle knappene:



// Btn1 Over function
function btn1Over(event:MouseEvent):void {
btn1.gotoAndPlay("over"); // go into btn1 movieclip and play the over frame label
}
// Btn1 Out function
function btn1Out(event:MouseEvent):void {
btn1.gotoAndPlay("out"); // go into btn1 movieclip and play the out frame label
}
// Btn1 Click function
function btn1Click(event:MouseEvent):void {
btn1.gotoAndPlay("click"); // go into btn1 movieclip and play the click frame label
// Jump out of this clip using parent code and jump into and control allPages clip
MovieClip(parent).gotoAndPlay("about");
}
// Btn1 listeners
btn1.addEventListener(MouseEvent.ROLL_OVER, btn1Over);
btn1.addEventListener(MouseEvent.ROLL_OUT, btn1Out);
btn1.addEventListener(MouseEvent.CLICK, btn1Click);
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
function btn2Over(event:MouseEvent):void {
btn2.gotoAndPlay("over");
}
function btn2Out(event:MouseEvent):void {
btn2.gotoAndPlay("out");
}
function btn2Click(event:MouseEvent):void {
btn2.gotoAndPlay("click");
// Jump out of this clip using parent code and jump into and control allPages clip
MovieClip(parent).gotoAndPlay("work");
}
btn2.addEventListener(MouseEvent.ROLL_OVER, btn2Over);
btn2.addEventListener(MouseEvent.ROLL_OUT, btn2Out);
btn2.addEventListener(MouseEvent.CLICK, btn2Click);
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
function btn3Over(event:MouseEvent):void {
btn3.gotoAndPlay("over");
}
function btn3Out(event:MouseEvent):void {
btn3.gotoAndPlay("out");
}
function btn3Click(event:MouseEvent):void {
btn3.gotoAndPlay("click");
// Jump out of this clip using parent code and jump into and control allPages clip
MovieClip(parent).gotoAndPlay("kontakt");
}
btn3.addEventListener(MouseEvent.ROLL_OVER, btn3Over);
btn3.addEventListener(MouseEvent.ROLL_OUT, btn3Out);
btn3.addEventListener(MouseEvent.CLICK, btn3Click);
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
function btn4Over(event:MouseEvent):void {
btn4.gotoAndPlay("over");
}
function btn4Out(event:MouseEvent):void {
btn4.gotoAndPlay("out");
}
function btn4Click(event:MouseEvent):void {
btn4.gotoAndPlay("click");
// Jump out of this clip using parent code and jump into and control allPages clip
MovieClip(parent).gotoAndPlay("home");
}
btn4.addEventListener(MouseEvent.ROLL_OVER, btn4Over);
btn4.addEventListener(MouseEvent.ROLL_OUT, btn4Out);
btn4.addEventListener(MouseEvent.CLICK, btn4Click);




Én kommentar

Dan

03.feb.2010 kl.11:11

Jasså ja. Du driver å scripter ja.

Skriv en ny kommentar

hits