Trying to do this effect in Flash



Hi the page below
where it has the transparent going through it
http://www.mintietechnologies.com/index.cfm

i tried to do it with mask but it look pretty lame and i was wondering if any one can help me try to reproduce the effect as my boss likes it alot
Thank you
LVL 7
TRACEYMARYAsked:
Who is Participating?
 
BillystyxCommented:
no worries:)
0
 
BillystyxCommented:
You don't need to use a mask, just create a rectangle, convert it to an mc, and set the alpha  to 10 or so. Then motion tween it (or with action script), from left to right across the image below.

Billystyx
0
 
BillystyxCommented:
Make the rectangle for the mc white, and you can obviously experiment with the best alpha level for the clip to get the right effect.

In action script, give your instance of the rectangle a name - 'myMc' for example.

on the root time line create a keyframe on the first frame and add this code.
myMc._alpha=20;//or 10 or 50 ...

myMc.onEnterFrame=function(){
if(this._x<400){
this._x +=5;
}

this will move it from original position (on left of stage), to finishing place (on right of stage).
You know how to attachMovie and remove etc, so you can always use that and set it all in AS

Billystyx
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
TRACEYMARYAuthor Commented:
Oh i see.............then i can swap out the images under neath it.......

I give it a go.
0
 
BillystyxCommented:
How do you mean 'swap out the images underneath it'?
The way I was intending here was that the image (the banner the translucent bar runs across) is essentially static (except for the first transition where you 'roll it out' across the stage, and only the rectangular bar needs to move - it moves across the top of the banner. So in the timeline, the layer for the rectangle is above the layer holding the banner.

Hope this makes sense:)

Billystyx
0
 
TRACEYMARYAuthor Commented:
Thinking...
  Lets say layer 1      is the translucent bar  mc clip
              layer 2      image 2
              layer 3      image 3

  the code above goes in layer 1

  then the bar will go across the page.
             the layer 2 i could display for x frames and then start layer 3.........

so that when the bar goes across the page then pic 2 starts and then pic 3

Does that make sense
0
 
BillystyxCommented:
Close, but if you want the pictures changing say, when the bar reaches the right hand side of the picture, then I would suggest attaching them and removing them with code, rather than working so closely with the layers.

on frame 1:
myArr=["MC1","MC2","MC3"];
count=0;
createMCS();
function createMCS(){
attachMovie(myArr[count],myArr[count],1);
_root[myArr[count]]._x=275;
_root[myArr[count]]._y=200;
}
dep=_root.getNextHighestDepth();
attachMovie("myMc","myMc",dep);
myMc._x=10;
myMc._y=200;
myMc._alpha=20;//or 10 or 50 ...

myMc.onEnterFrame=function(){
if(this._x<400){
this._x +=5;
}else{
this._x=10;
if(count<3){
count ++;
}else{
count=0;
}
createMCS();
}


This should do it - you obviously need to set the appropriate linkage names in the library too.
(BTW this is air code so it may not be exactly right)
Billystyx

0
 
TRACEYMARYAuthor Commented:
Cheers billy let me play with this.............
air code..........phew i get that good in a few years.......i can do it with asp and sql.........

Thanks
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.