Link to home
Start Free TrialLog in
Avatar of George-TCC
George-TCCFlag for Australia

asked on

seamless flash loop

Hi,
i'm trying to created a seamless loop of fading images using actionscript. With the AS i'm using it fades out the last image then fades in the first image again so there is a gap between the last and the first image.
I'd like the last image to fade into the first image seamlessly without a gap.
I'm using tweenlite but would take suggestions of other options
Below is my code:
import gs.TweenLite;
 
 
		function startShow():Void {		
		
		image1._alpha = 0; // start faded down
		TweenLite.to(image1, 1, {_alpha:100});
		TweenLite.to(image1, 1, {_alpha:0, delay:3, overwrite:false});
		
		image2._alpha = 0; // start faded down
		TweenLite.to(image2, 1, {_alpha:100, delay:3, overwrite:false});
		TweenLite.to(image2, 1, {_alpha:0, delay:6, overwrite:false});
		
		image3._alpha = 0; // start faded down
		TweenLite.to(image3, 1, {_alpha:100, delay:6, overwrite:false });
		TweenLite.to(image3, 1, {_alpha:0, delay:9, overwrite:false});
 
		
		image4._alpha = 0; // start faded down
		TweenLite.to(image4, 1, {_alpha:100, delay:9, overwrite:false});
		TweenLite.to(image4, 1, {_alpha:0, delay:12, overwrite:false});
 
		image5._alpha = 0; // start faded down
		TweenLite.to(image5, 1, {_alpha:100, delay:12, overwrite:false});		
		TweenLite.to(image5, 1, {_alpha:0, delay:15, overwrite:false, onComplete:startShow, onCompleteScope:this});
   }
 
startShow();

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of wal_toor
wal_toor
Flag of Netherlands image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial