CountDown using Action Script 2
Note that back button doesn't work on this particular file but it has a nice explosion and a sound file to go with it.
First, open the file "Count Down"
On Frame 1 open the actionscript editor (F9) and enter this text: stop(); Next on Frame 1 use the text tool to insert the text: PLAY Select the text with the black pointer (not the text tool) and convert to a Button Symbol. It has to be a button. Edit the button PLAY You should see a button timeline that looks like this: Select the "Over" frame, right click and insert a keyframe.
Using the text tool select the PLAY text and change color. You might want to also use the transform tool and make the text slightly larger. Now return to the SCENE and select the play button. Hit F9 and enter the following code:
on(release){ gotoAndPlay(2); } Test the movie to see if the button works. The programs should stop on frame 1. When you mouse over the button it should change color. And when you click the button it should play the countdown and return to the start screen. If it doesn't, you made a mistake. |
Next step is to create two arrows. I like to build one arrow, copy it, then transform it from left to right to make a second button identical except pointing in the opposite direction. Screen should now look like this:
Use the black selection tool to pick the right button. Hif F9 and enter the following code:
on(release){ nextFrame(); } Test the animation. Clicking on the next button should move the screen to the 10 frame. Now let's program the left button. Use the black selection tool to pick the left button. Hif F9 and enter the following code:
on(release){ prevFrame(); } Since there is no previous frame this button doesn't currently work. Next step:
On frame 1 select both the next button and the previous button. Use control C to place them on the clipboard. Then go to frame 2 (has the ten on it) and press Control-Shift-V (all three buttons at the same time. This pastes the contents of the clipboard onto the new page in exactly the same position as they were on the original. Continue the process until you have pasted the arrow buttons on all of the frames. Then return to the original frame 1 and erase the prev arrow button there since it makes no sense to be there. Final Step: This is a countdown for something to happen. Make something happen like an explosion, a funny face, something. Your choice! Then turn in to the turn in box and see if it plays on your website. |
Proudly powered by Weebly