Menu
Let's take a look at the effect: (move the mouse pointer over the three pictures below and click to see the Middle menu slide.) )
Click here to download the source file
1, open Flash, a new document, size set to 480*360, background black. Draw two white lines on the stage, spacing 124px, placing three pictures of the same size below the white line and adjusting the position.
2, the new component menu, the behavior of the selected movie clips, and then insert pictures and text, as shown in the picture.
3, the new component BTN, Action selection button, in the press the frame insert blank key frame, select a rectangular tool, the color of the Strokes selected colorless, fill the color arbitrary, on the stage to draw a rectangle.
4, create a new layer 2, press F11 to open the library panel, drag the component menu to the middle of two white lines in the scene, adjust the position and the left edge of the stage alignment. In the property panel, enter the instance Name menu, select Symbol menu, press F9 to open the Action panel, and enter the statement
Onclipevent (enterframe) {
Xsquare = _root.menu._x;
Xdiff = Xpos-xsquare;
Xmove = XDIFF/10;
_root.menu._x = Xsquare+xmove;
Updateafterevent (Enterframe);
}
5, new layer three, the button components dragged into the scene, placed in the white line below the picture, resize and position just cover the picture, here I placed three pictures, so put three buttons.
6, click to select the first button, press F9 key to open the action panel, enter the statement
On (release) {
_root.menu.xpos = 0;
Enter a statement on the second button
On (release) {
_root.menu.xpos =-480;
}
Enter a statement on the third button
On (release) {
_root.menu.xpos =-960;
}
Test, save the disk.