Home Game Development unity – Is it doable to have a number of simultaneous tweens inside a LeanTween sequence?

unity – Is it doable to have a number of simultaneous tweens inside a LeanTween sequence?

0
unity – Is it doable to have a number of simultaneous tweens inside a LeanTween sequence?

[ad_1]

I’m attempting to create a sequence that controls a number of animating objects (ObjectA and ObjectB). I need it to appear to be this…

Step 1: ObjectA strikes to heart, whereas rotating.

Step 2: ObjectB strikes to heart.

Step 3: ObjectA and ObjectB transfer collectively concurrently to left

So my preliminary intuition was to do all of it utilizing a single sequence. However after reviewing all of the documentation and examples I can discover, I’ve not discovered a approach to make a sequence through which you’re working a number of tweens at a single step. For occasion, so far as I can inform, you possibly can’t do something like:

LTSeq sequence = LeanTween.Sequence();
//step 1
sequence.append( <Move ObjectA> AND <Rotate ObjectA>);//There isn't any approach to do that?
//step 2
sequence.append( <Move ObjectB>);
//step 3
sequence.append (<Move ObjectA> AND <Move ObjectB>); //No approach to do that both?

So I additionally tried making two sequences that might run concurrently, like so:

LTSeq sequenceA = LeanTween.Sequence();
LTSeq sequenceB = LeanTween.Sequence();
//step1
sequenceA.append( <Move ObjectA>);
sequenceB.append( <Rotate ObjectA>); 
//step 2
sequenceA.append( <Move ObjectB>);
sequenceB.append( <Wait> );
//step 3
sequenceA.append( <Move ObjectA>);
sequenceB.append( <Move ObjectB>);

But once I do that, Sequences A and B nonetheless happen sequentially though they’re separate objects, as a substitute of concurrently as anticipated.

Does anybody right here know easy methods to make LeanTween carry out a number of simultaneous tweens inside a sequence? I’m out of concepts.

[ad_2]

LEAVE A REPLY

Please enter your comment!
Please enter your name here