Flashvault.net

Advanced light effect

4.8.2006, 21:17    Total views: 77366
This tutorial will learn you how to create advanced light effect using the Action Script code. In this tutorial I will apply a light effect on some picture. This tutorial is so complicated to explain, but I'll try on to explain it on the best way I can. To create this tutorial you must use a Flash 8.



Step 1

Create a new Flash Document, press Ctrl+R on the keyborad (Import to Stage), and import any picture.



Step 2

While your picture is still selected, press F8 on the keyborad (Convert to Symbol), and convert it into a Movie Clip. Look at the picture below!



Step 3

Double click on layer1 to rename its name into a picture_bottom.

Step 4

Insert a new layer (layer 2) and name it picture_top. Lock picture_bottom layer .



Step 5

After that, open the Library Panel (Ctrl+L) and using drag and drop technique, move your picture (Movie Clip - See step2 ) on the stage.

Step 6

Then, open the Align Panel (Ctrl+K) and click on Align to stage icon, after that on Align horizontal center and Align vertical center icon, to precisely center your top picture with background (bottom picture).



Step 7

Select the top picture, open the Properties Panel (Ctrl+F3), and under type:  top_picture.



Step 8

Lock and hide a picture-top layer and unlock picture_bottom layer.



Step 9

Select the bottom picture ( picture of the picture_bottom layer ), open the Properties Panel (Ctrl+F3), choose Filletrs, click on plus icon and choose Adjust color. Look at the pictures below!

#ads#





Step 10

After that set the options from the picture below!



Step 11

Now, your bottom picture must look something like this:



Now, you have a two different pictures. One - dark and gray scale image (bottom picture - picture_bottom layer ) and One - bright and coloring picture ( top picture - picture_top layer). Look at the picture below!



Step 12

Lock picture_bottom layer, unhide a picture_top layer, insert a new layer and name it gradient_circle.



Step 13

Take the Oval Tool (O), Stroke color must be switched off, under Fill color choose any color and draw a circle.





Step 14

While your "circle" is still selected, open the Color Mixer Panel (Shift+F9), and set the options from the picture below!





Step 15

While your "circle" is still selected, press F8 on the keyborad (Convert to Symbol), to convert it into a Movie Clip. Look at the picture below!



Step 16

Open the Properties Pannel (Ctrl+F3), and under type GradientCircle.



Step 17

Insert a new layer and name it Action.



Step 18

Click on the first frame of layer Action, open the Action Script Panel (F9), and paste this script:

top_picture.cacheAsBitmap = true;
GradientCircle.cacheAsBitmap = true; top_picture.setMask(GradientCircle);

top_picture.setMask(GradientCircle);

Mouse.hide();

this.onMouseMove = function() {
GradientCircle._x = this._xmouse;
GradientCircle._y = this._ymouse;
updateAfterEvent();
}

this.onMouseDown = function() {
top_picture.cacheAsBitmap = false;
}

this.onMouseUp = function() {
top_picture.cacheAsBitmap = true;
}

We're done! Test your Movie (Ctrl+Enter)


Download source file (.fla)
Have questions about this tutorial?
Visit our friendly Community Forums!
Digg it! Add this tutorial to del.icio.us! Furl it! Add this tutorial to reddit! Spurl it! Add this tutorial to technorati!

Forum - Newest Discussions

Waiting for your hour of triumph? It is near!
Last post by: VitaMary
Date: 21.11.2008 18:46:41

Yeow dogs!
Last post by: deco11
Date: 21.11.2008 01:15:49

Show your girlfriend what a real sex is!
Last post by: VitaMary
Date: 20.11.2008 22:00:13

Regarding the Gradient by Mouse Tutorial...
Last post by: cloudy-days
Date: 19.11.2008 07:41:03

Open flash cs3 fla in flash 8???
Last post by: benjezza
Date: 14.11.2008 23:41:46

flash form tutorial
Last post by: bukopie79
Date: 12.11.2008 07:56:46

Flash form with PHP and Postgre
Last post by: bukopie79
Date: 07.11.2008 04:23:06

Contact Form
Last post by: jesustippe
Date: 02.11.2008 09:37:24

Contact Flash Form
Last post by: mr_byeng
Date: 01.11.2008 06:08:39

Related links