Jump to content
Search Community

Tweening various mc's 1 by 1

glt test
Moderator Tag

Recommended Posts

Hi there,

 

I have an array of mc's which i wish to glow IN and OUT 1 by 1 - first goes on and second one begins only after first goes off:

var slupki:Array = new Array(blue1, blue2, blue3, blue4, green1, green2, green3, green4, green5, gold1, gold2, gold3, gold4, gold5);

var timeline:TimelineMax = new TimelineMax({repeat:-1, yoyo:true});

timeline.insertMultiple( TweenMax.allTo(slupki, .5, {glowFilter:{color:0xffffff, alpha:1, blurX:30, blurY:30}}, .5) );
/* tried also something like this...
for(var i:int=0; i	{
	timeline.insert( TweenMax.to(slupki[i], .5, {glowFilter:{color:0xffffff, alpha:1, blurX:30, blurY:30}}) )
}
*/

 

Unfortunetly they keep glowing 1 by 1 but the sequence is: 1st glows on then second glows on etc. till reach last one - then it begins turning glow off. I wish it would be: 1st glows on then glows off then 2nd goes on and off etc.

Have no idea how to build code to make em work like i wish.

Thanks for help in advance and sorry for my poor English :)

 

Cheers

Link to comment
Share on other sites

you were very close. you need each tween in the allTo to repeat and yoyo.

 

 

timeline.insertMultiple( TweenMax.allTo(slupki, .5, {glowFilter:{color:0xffffff, alpha:1, blurX:30, blurY:30}, repeat:1, yoyo:true}, 1) );

 

that should work for you.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...