Tween.fforward()

Availability

Flash Player 6 (6.0.79.0).

Edition

Flash MX 2004.

Usage

tweenInstance.fforward()

Returns

Nothing.

Description

Method; forwards the tweened animation directly to the final value of the tweened animation.

Example

In this example, Tween.fforward() is called to forward a tweened animation directly to its final value, immediately triggering the onMotionFinished event. A handler for the Tween.onMotionFinished event calls the Tween.yoyo() method. The tweened animation therefore visibly starts with the reversing effect of the Tween.yoyo() method, since the initial animation was skipped to its end. A movie clip instance named img1_mc is required on the Stage for this example:

import mx.transitions.Tween;
var myTween:Tween = new Tween(img1_mc, "_x", mx.transitions.easing.Elastic.easeOut,0, Stage.width - img1_mc._width, 8, true);

myTween.fforward();

myTween.onMotionFinished = function() {
    myTween.yoyo();
};