Nope, the middle size is always still.
That happens only with the right and left sides, and only with rotationX;

Yes, I aplly rotations only when the tween is finished.
And, yes, when I don't apply the rotations, this problem does not occur.
But it leads to some other problems) (I eally need to figure this out more
carefully)

Here is a bit of code.

for (var i:int = 0; i < currentAnimatedSide.length; i++)
{

//the next block of code is just to apply "onComplete" function to trigger
once, while 9 tweens are created.
if (i == currentAnimatedSide.length - 1)
                        {
                            Tweener.addTween(currentAnimatedSide[i], {
rotationX:  currentAnimatedSide[i].rotationX + (90 * direction),

time:       rotAnimationTime,

transition: "easeInOutExpo",

onComplete: refreshSide } );
                        }
                        else
                        {

                            Tweener.addTween(currentAnimatedSide[i], {
rotationX:  currentAnimatedSide[i].rotationX + (90 * direction),
                                                              time:
"easeInOutExpo",
                                                                 transition:
animationTransition } );
                        }
}

/**
*
*/
private function refreshSide():void
{
            for (var i:int = 0; i < 9; i++)
            {

                (currentAnimatedSide[i] as Cube).applyPosition(
-currentAnimatedSide[i].x,

-currentAnimatedSide[i].y,

-currentAnimatedSide[i].z);

               (currentAnimatedSide[i] as Cube).applyRotations();
            }

            cubeContainer.applyRotations();
}



I'll try to get deeper into my logic of the side cubes selection for the
rotation.
May be I made a terrible mistake there, and now «blame» away3d.
I was just stunned by the correct work of y and z rotations, and such a
weirdness with rotationX.

Thanks, Ben.

Reply via email to