Search tutorials
Adding the script
The script will manipulate the original photo's transparency. Go into the main timeline and place an instance of the 'assembled' movieclip. Keep the movieclip selected and go into the actions panel. Enter this script:
onClipEvent(load)
{
dir = 0;
speed = 6;
original._alpha = 0
this.onRollOver = function()
{
dir = 1;
}
this.onRollOut = function()
{
dir = -1;
}
useHandCursor = false;
}
onClipEvent(enterFrame)
{
temp = original._alpha + speed*dir;
original._alpha = Math.min(100,Math.max(temp,0));
}
Press Ctrl+enter to test your movie. You should have get a blur transition effect when you move your mouse over the photo. If you receive an error such as: 'Clip events are permitted only for movie clip instances', it's because you placed the script on a frame instead of on the movieclip. Make sure you have the movieclip selected before pasting the script into the actions panel.
| » Level Basic |
|
Added: 2004-08-25 Rating: 8 Votes: 39 |
| » Author |
| The author is a math enthusiast. He is currently studying Physics at McGill University. |
| » Download |
| Download the files used in this tutorial. |
| Download (356 kb) |
| » Forums |
| More help? Search our boards for quick answers! |
-
You must have javascript enabled in order to post comments.


Comments
There are no comments yet. Be the first to comment!