Package  net.flashpunk.tweens.motion 
Class  public class LinearMotion 
Inheritance  LinearMotion Motion Tween Object 
Property  Defined By  

active : Boolean
If the tween should update.  Tween  
complete : Function
Tween completion callback.  Tween  
delay : Number = 0
Length of time to wait before starting this tween.  Tween  
distance : Number [readonly]
Length of the current line of movement.  LinearMotion  
object : Object
Target object for the tween.  Motion  
percent : Number
The completion percentage of the Tween.  Tween  
scale : Number [readonly]
The current time scale of the Tween (after easer has been applied).  Tween  
x : Number
Current x position of the Tween.  Motion  
y : Number
Current y position of the Tween.  Motion 
Method  Defined By  

LinearMotion(complete:Function = null, type:uint = 0)
Constructor.  LinearMotion  
cancel():void
Immediately stops the Tween and removes it from its Tweener without calling the complete callback.  Tween  
setMotion(fromX:Number, fromY:Number, toX:Number, toY:Number, duration:Number, ease:Function = null):void
Starts moving along a line.  LinearMotion  
setMotionSpeed(fromX:Number, fromY:Number, toX:Number, toY:Number, speed:Number, ease:Function = null):void
Starts moving along a line at the speed.  LinearMotion  
start():void
Starts the Tween, or restarts it if it's currently running.  Tween  
update():void
Updates the Tween, called by World.  Tween 
distance  property 
distance:Number
[readonly] Length of the current line of movement.
public function get distance():Number
LinearMotion  ()  Constructor 
public function LinearMotion(complete:Function = null, type:uint = 0)
Constructor.
Parameterscomplete:Function (default = null ) — Optional completion callback.
 
type:uint (default = 0 ) — Tween type.

setMotion  ()  method 
public function setMotion(fromX:Number, fromY:Number, toX:Number, toY:Number, duration:Number, ease:Function = null):void
Starts moving along a line.
Parameters
fromX:Number — X start.
 
fromY:Number — Y start.
 
toX:Number — X finish.
 
toY:Number — Y finish.
 
duration:Number — Duration of the movement.
 
ease:Function (default = null ) — Optional easer function.

setMotionSpeed  ()  method 
public function setMotionSpeed(fromX:Number, fromY:Number, toX:Number, toY:Number, speed:Number, ease:Function = null):void
Starts moving along a line at the speed.
Parameters
fromX:Number — X start.
 
fromY:Number — Y start.
 
toX:Number — X finish.
 
toY:Number — Y finish.
 
speed:Number — Speed of the movement.
 
ease:Function (default = null ) — Optional easer function.
