2 more more Tweener tweens at once

I have completley forgotten how to tween two at once, its something like

 ActionScript Code:
 [LEFT]Tweener.[COLOR=#000080]addTween[/COLOR] [COLOR=#000000][[/COLOR][COLOR=#000000]([/COLOR]sprite1, [COLOR=#000000]{[/COLOR] [COLOR=#0000ff]time[/COLOR]:[COLOR=#000080]1[/COLOR], y:[COLOR=#000080]20[/COLOR], transition:[COLOR=#ff0000]"easeInOutExpo"[/COLOR] [COLOR=#000000]}[/COLOR] [COLOR=#000000])[/COLOR][COLOR=#000000]][/COLOR],  [COLOR=#000000][[/COLOR][COLOR=#000000]([/COLOR]sprite2, [COLOR=#000000]{[/COLOR] [COLOR=#0000ff]time[/COLOR]:[COLOR=#000080]1[/COLOR], y: -[COLOR=#000080]20[/COLOR], transition:[COLOR=#ff0000]"easeInOutExpo"[/COLOR] [COLOR=#000000]}[/COLOR][COLOR=#000000])[/COLOR][COLOR=#000000]][/COLOR];

[/LEFT]

but its not that, i can remember that there’s []'s in there, but I just cant remember where
thanks

Why don’t you just stick them on two lines?

i need them to fire at the same time

TweenMax has the “onStart” and “onComplete” params.
You can use onStart to target a function that contains your second tween.

the code you are writing looks similar to tweenlite (rather than the built-in tween package)

http://blog.greensock.com/tweenliteas3/

i´ve just started using it and it makes me happy, i´d recommend downloading it and using it. if you do want to use the built in package the closest i can think to have a simultaneous firing is:

import fl.transitions.Tween
import fl.transitions.easing.Regular
var a:Array = new Array(new Tween(your_mc,“x”,Regular.easeIn,boxmc.x,300,1,true),
new Tween(boxmc,“y”,Regular.easeIn,your_mc.y, 300,1,true))

as a side note: i´ve found putting tweens in an array like this seems to fix some of the problems i´ve run into when i do the more standard thing:

var twn1:Tween = new Tween(…)
var twn2:Tween = new Tween(…)

sometimes when removing tweens, adding listeners, etc… this will run into problems. i think it has something to do with the garbage collector… anyway putting tweens in arrays gets rid of such problems

If you just do something like:


Tweener.addTween(myObject, {myParams});
Tweener.addTween(myObject2, {myParams});
Tweener.addTween(myObject3, {myParams});

They’ll all fire at the same time. I think you’re either misunderstanding how it works or you’re not articulating why they need to be in the same declaration.