This content has been marked as final. Show 2 replies
why not just make image A and B animate for 5 seconds in iys own timeline.
That way it wount interfeer with anything else.
im saying that as an alternative to using actionScript...
but if you DO find the code to do it.. please share it with me... =)
the more code one has the better..
>> Is there any way to make a timed tween from image
>> A to image B using actionscript? Ex. Making image
>> A fade out and image B to fade in, all of this over 5
>> seconds. Thanks.
Sure thing. If the idea is to make it look like A is dissolving into B,
I would leave B at full opacity the whole time. Just reduce A's opacity.
If you fade one out and fade one in at the same time, there's this "dead
spot" when both are at half opacity, and the whole image seems to dip out
You could use the Tween class for this. Look up "Tween class" in the
documentation and you'll find a section on "About the Tween class" as well
as the Tween class entry itself, in the Components Language Reference. Use
_alpha as the property to tween.
> why not just make image A and B animate for 5 seconds
> in iys own timeline. That way it wount interfeer with anything
There are definitely times to animate by hand (think complex character
animation), but there are also times to animate via ActionScript. If you
want something to animate for 5 seconds in a timeline, you have to take into
consideration what framerate you're running and do the math. If you need
five seconds at 24fps, you need 120 frames for that. What if you decide to
change your mind? What if you need 10 seconds? Now you need 240. What if
you change the movie's over all framerate? With ActionScript and the Tween
class, you only need one frame.
> im saying that as an alternative to using actionScript...
> but if you DO find the code to do it.. please share it with
> me... =) the more code one has the better..
Code can actually be harmful if you're unfamiliar with it. ;) More
important than finding code is making sure you have a programmer's mindset.
Adobe Community Expert
Dev blog, http://www.quip.net/blog/
"Luck is the residue of good design."