[Tweener] Tighten the Loop Part II
Wes
sevenxthree at yahoo.com
Tue Oct 28 16:44:13 PDT 2008
Move the onComplete parameter from the second box3 tween to the first box3 tween.
--- On Tue, 10/28/08, Matt Tedeschi <matt at qwlproductions.com> wrote:
From: Matt Tedeschi <matt at qwlproductions.com>
Subject: [Tweener] Tighten the Loop Part II
To: Tweener at lists.caurinauebi.com
Date: Tuesday, October 28, 2008, 2:58 PM
Going a bit crazy here trying to figure out how to make a loop where movie
clips enter from stage left -- sit on stage for some time -- and then exit
stage right (so the clips need to be reset to the negative stage left
x)... I have the loop working, except for that the gap between the last
clip and the first clip is too wide.
If you care to take a look you can see it working here:
http://www.qwlproductions.com/tweener/test.swf
I just need the transitions to be the same... from the red box to the
black box though, there is a delay.
I've just not been able to figure out what's wrong -- changing the
delay
or time on any of the settings hasn't proved fruitful. The only thing
that did seem to work was removing the -- time: .5 -- setting on the
second 'box3' tween, but then that takes away the smooth transition.
Can you help me see what's wrong?? Thanks in advance.
import caurina.transitions.*;
function slideBoxes():void {
var boxArray:Array = new Array(box1, box2, box3);
for (var i:uint = 0; i < boxArray.length; i++) {
var boxLocation = boxArray[i];
boxLocation.x = -400;
boxLocation.y = 0;
boxLocation.alpha = 1;
}
Tweener.addTween(box1, { x: 0, time: .5, delay: 0, alpha: 1, transition:
"easeIn" } );
Tweener.addTween(box1, { x: 400, time: .5, delay: 5, alpha: 0,
transition: "easeOut" } );
Tweener.addTween(box2, { x: 0, time: .5, delay: 5, alpha: 1, transition:
"easeIn" } );
Tweener.addTween(box2, { x: 400, time: .5, delay: 10, alpha: 0,
transition: "easeOut" } );
Tweener.addTween(box3, { x: 0, time: .5, delay: 10, alpha: 1, transition:
"easeIn" } );
Tweener.addTween(box3, { x: 400, time: .5, delay: 15, alpha: 0,
transition: "easeOut", onComplete:slideBoxes } );
}
slideBoxes();
_______________________________________________
Tweener mailing list
Tweener at lists.caurinauebi.com
http://lists.caurinauebi.com/listinfo.cgi/tweener-caurinauebi.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.caurinauebi.com/pipermail/tweener-caurinauebi.com/attachments/20081028/206db132/attachment.htm>
More information about the Tweener
mailing list