Pretty straight-forward. A few different ways to do it, but I'd create a layer with one image and a layer with the other image and put a mask over one of the layers.
Using CS3 and AS2, I'd put an onEnterFrame on the mask layer to have it slide with the mouse. And, to make it look more like the example, put a black line and have it follow it as well.
I attached a sample clip.
If it was going to be used in a larger program, I might come up with a way to avoid using the onEnterFrame, maybe a transparent layer or something. Also, looks like they're using some easing as well to give some physics to the mask.
Lots of other ways to do it as well. Would definitely do it differently in AS3, but the concept is the same.
Hope that helps!
Love like you've never been hurt, live like there's no tomorrow and dance like nobody's watching.
Hello there!! wow..god knows how i was looking for this example!! could you please make an example with clicking and draging the black line to the left to reveal the other image? how can i make this? please hope you can help me! my mail juandrhc@gmail.com
thanks in advance!!!
flashpipe1 first of all thanx a lot for your response!! it didn't worked. I placed your code on the first keyframe, just as the old one. but I got this:error.jpg
Pretty straight-forward. A few different ways to do it, but I'd create a layer with one image and a layer with the other image and put a mask over one of the layers.
Using CS3 and AS2, I'd put an onEnterFrame on the mask layer to have it slide with the mouse. And, to make it look more like the example, put a black line and have it follow it as well.
I attached a sample clip.
If it was going to be used in a larger program, I might come up with a way to avoid using the onEnterFrame, maybe a transparent layer or something. Also, looks like they're using some easing as well to give some physics to the mask.
Lots of other ways to do it as well. Would definitely do it differently in AS3, but the concept is the same.
Hope that helps!
I was hoping to use the file you send but unfortunately with the version I have it won't read AS2. It simply deletes the code so I can't use it and couldn't find it anywhere else. Could you please send me the file in AS3! Thank you so much in advance!