First time here? First time here? Newsletter Signup Newsletter
651326 Members and growing! | Flash Jobs
Search tutorials
Author: Boban Klasnikov | Website: http://www.PowerOfArt.com

Adding Realism

Now we have to make the effect of dragging the magnifier over small picture look realistic. Because both the small (50% )picture and big (100%) picture are centrally aligned, we have to position the magnifier in the dead center to make it look realistic.

Because bigpic is 2 times bigger we have to move it in opposite direction of magnifier movement for double amount. (If we use 1:1 transformation ratio between the small and bigpic we multiply movement in opposite direction by 1, for ratio 1:2 we multiply with 2; with ratio 1:3 with 3).

You should always import the picture as the big picture then scale it down to get the smaller picture.

You should also always use the Transform Inspector (Windows > Inspectors > Transform), because you will need to scale objects by exact amounts. If we mark bigpic to be 100% all the time then the formula would be 100% / SmallPic% = multiplying factor. In our case Multiplying Factor is 100% / 50% = 2. In actionscript I quoted previously I just added *2 (see below), so the final action script for the frame 2 would look like this:

Set Variable: "x_mask" = GetProperty (outline ,_x)
Set Variable: "y_mask" = GetProperty(outline,_y)
Set Property ("/outline/bigpic", X Position) = (200- x_mask)*2
Set Property ("/outline/bigpic", Y Position) = (200 - y_mask) * 2

There you go! If you have any problems don't forget that the flashkit board is available to answer any of your questions. You can also download the source file to pick apart at the bottom of this page. Good luck and happy flashing.

» Level Intermediate

Added: 2000-09-06
Rating: 7.99 Votes: 525
(10 being the highest)
» Author
Boban Klasnikov is a graphic artist and master illustrator. He came to computer design after more than 20 yrs of art experience. Currently working on web design at PowerOfArt.com
» Download
Download the files used in this tutorial.
» Forums
More help? Search our boards for quick answers!

Comments

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

  • You must have javascript enabled in order to post comments.

Leave a Comment
  • Your email address will not be published. All fields are required.
Featured Flash FLA
» Author: S.Saipriya
» Title: Flash Fire Effect
» Description: This tutorial explains about how to create Fire Effect in Flash of Actionscript 2.0.I hope this tutorial helps you!
Featured Sound Loops
Image for equalize

Audio Player

» Author: Aidan Crouzet-Pascal
» Title: Falling Star
» Description: This loop is a cool sounding, E minor loop.
Latest Font
» Author: Fábio FAFERS
» Description: I created this font for free use. Everyone can apply it in personal or business texts. Its free, but I want to be communicated in case of business use. Donations are accepted to keep the project of free fonts alive! Thank you all
Featured Sound Fx
Image for equalize

Audio Player

» Author: Brandan Paulin
» Description: Epic sounding loop with Brass, Percussion, Strings and Winds. This is actually part of a Loop Pack called the Coming where you can download the rest of the loops that go with it FREE from my website.