View Single Post
Old 04-25-2012, 04:02 PM   PM User | #1
joenowhere
New to the CF scene

 
Join Date: Apr 2012
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
joenowhere is an unknown quantity at this point
Before and after question

I'm new in Flash, now I want to make a before and after photo gallery, and each set of photo have a bar in it, so user can click on the bar and slide left and right to see the effect before and after, but the problem is I only know the AC for moving the bar but not with the mask, so did any one know how to make the mask move with the bar? Thanks a lot!

Below is the code I have and the SWF file, please help and thanks!

Code:
slider_mc.addEventListener(MouseEvent.MOUSE_DOWN, drag);
stage.addEventListener(MouseEvent.MOUSE_UP, drop);

function drag(e:MouseEvent):void
{
     e.target.startDrag(false, new Rectangle(0,300,800,0));
}

function drop(e:MouseEvent):void
{
     stopDrag();
}

http://www.4shared.com/document/HgJS...and_After.html
joenowhere is offline   Reply With Quote