Tween.onmotionchanged - MACROMEDIA FLASH 8-COMPONENTS LANGUAGE Reference

Components language reference
Table of Contents

Advertisement

Example
This example applies a tweened animation to the
looped to play repeatedly from its starting point by calling the
within a handler triggered by the
forwardByFrame_btn calls the
calling the
Tween.nextFrame()
has the effect of stopping the animation and then moving forward by only a single frame.
When you create the Tween instance, the
tween frame based. This process is required to use the
clip instance named
img1_mc
import mx.transitions.Tween;
var myTween:Tween = new Tween(img1_mc, "_x",
mx.transitions.easing.None.easeNone,0, Stage.width, 60, false);
myTween.onMotionFinished = function() {
myTween.start();
};
forwardByFrame_btn.onRelease = function() {
myTween.stop();
myTween.nextFrame();
};

Tween.onMotionChanged

Availability
Flash Player 6 (6.0.79.0).
Edition
Flash MX 2004.
Usage
tweenInstance.onMotionChanged = function() {
// ...
};
1324
Tween class
img1_mc
Tween.onMotionFinished
method to stop the animation, followed by
Tween.stop()
method. Clicking the button during the tweened animation
useSeconds
is required on the Stage for this example:
movie clip
The animation is
.
Tween.start()
event. Clicking a button called
parameter is declared false to make the
Tween.nextFrame()
method from
method. A movie

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Flash 8

Table of Contents