FLASH Buttons - Part IIToday, we shall learn inserting sounds on different button states and producing more interactivity in buttons using more than one layer. First of all we shall create a button using three layers and then insert sounds at its different stages. After all our button will look like as shown below. Creating Button In the previous article, we have built a button using only one layer. On the same steps lets create a more interactive button using three layers so follow steps one by one. STEP 1: Choose Insert > New Symbol or press Ctrl+F8 keys combination. In the Name, type 'mul_button'. Choose Button from the behavior and finally click OK. STEP 2: After clicking OK, Flash will go into the button-editing mode. Choose Insert > Layer. Repeat this again so that three layers come into the timeline. Double-click Layer 1 to rename it 'Circle'. Similarly rename Layer 2 and Layer 3 'Square' and 'Triangle' respectively. STEP 3: Select Triangle Layer and draw a triangle of red color on the stage. Select Square Layer and draw a square of blue color slightly touching the triangle. At the end select Circle Layer and draw a circle of yellow color slightly touching both triangle and square. STEP 4: Click Frame 2 of the Triangle Layer under Over column. Click Insert > Keyframe or press F6. Choose blue color from the color box to change the triangle color to blue. Click Frame 2 of the Square Layer under Over column. Click Insert > Keyframe. Choose yellow color from the color box. Click Frame 2 of the Circle Layer. Click Insert > Keyframe. Choose red color from the color box. STEP 5: Click Frame 3 of the Triangle Layer under Down column. Click Insert > Keyframe. Choose yellow color from the color box. Click Frame 3 of the Square Layer under Down column. Click Insert > Keyframe. Choose red color from the color box. Click Frame 3 of the Circle Layer. Click Insert > Keyframe. Choose blue color from the color box. Congratulations! You have rightly done. Click Scene 1 in the upper left corner or choose Edit > Edit Movie to return to your movie. Open Library and drag this button onto stage. Click Control > Test Movie to check it out. Press cross mark in the upper right corner to return back to the movie. Inserting Sounds STEP 1: Right-click on the button and choose Edit. Insert a new layer and name it 'Sound'.
The copyright of the article FLASH Buttons - Part II in FLASH Programming is owned by Umais Ahmad. Permission to republish FLASH Buttons - Part II in print or online must be granted by the author in writing.
Go To Page: 1 2 Articles in this Topic Discussions in this Topic |