class flixel.tweens.motion.LinearMotion extends Motion

Available on all platforms

Determines motion along a line, from one point to another.

Instance Fields

var distance:Float

Length of the current line of movement.

function setMotion(FromX:Float, FromY:Float, ToX:Float, ToY:Float, DurationOrSpeed:Float, ?UseDuration:Bool = true):LinearMotion

Starts moving along a line. * *

FromX

X start. *

FromY

Y start. *

ToX

X finish. *

ToY

Y finish. *

DurationOrSpeed

Duration or speed of the movement. *

UseDuration

Whether to use the previous param as duration or speed.