Provides a convenient interface for creating all types of tweens.
public static var objectParser:ITweenObjectParser
public static function newTween(parameters:Object):ITween
Uses a generic object to define parameters for a new tween. See ITweenParser and KitchenSyncObjectParser for more details.
Parameters
| parameters:Object — An object that contains properties that define the new tween
|
Returns
See also
public static function newWithTargetProperty(target:Object = null, property:String = "", startValue:Number = 0, endValue:Number = 0, duration:Function = 0, delay:* = 0, easingFunction:* = null):KSTween
Creates a tween with a TargetProperty as it's tween target.
Parameters
| target:Object (default = null) — - the object whose property will be changed
|
| |
| property:String (default = "") — - the name of the property to change. The property must be a Number, int or uint such as a Sprite object's "alpha"
|
| |
| startValue:Number (default = 0) — - the value to tween the property to. After the tween is done, this will be the value of the property.
|
| |
| endValue:Number (default = 0) — - the starting value of the tween. By default, this is the value of the property before the tween begins.
|
| |
| duration:Function (default = 0) — - the time in milliseconds that this tween will take to execute. String values are acceptable too.
|
| |
| delay:* (default = 0) — - the time to wait in milliseconds before starting the tween. String values are acceptable too.
|
| |
| easingFunction:* (default = null) — - the function to use to interpolate the values between fromValue and toValue.
|
Returns
See also
public static function newWithTweenTarget(tweenTarget:*, duration:Function = 0, delay:* = 0, easingFunction:* = null):KSTween
Creates a new KSTween using an ITweenTarget that you pass into it.
Parameters
| tweenTarget:* — An explicitly defined tweenTarget object (or an array of tweentargets) that contains the values you want to tween.
|
| |
| duration:Function (default = 0) — - the time in frames that this tween will take to execute.
|
| |
| delay:* (default = 0) — - the time to wait before starting the tween.
|
| |
| easingFunction:* (default = null) — - the function to use to interpolate the values between fromValue and toValue.
|
Returns