Actuate MotionPath.bezier

Was reading this article, I have Actuate 1.8.1, but I don’t see this method there. Was it removed? also what does the line(20,20) determine?

The functionality I trying to recreate with actuate is:

var bezier:Array = [
	{ x:camera.x + panAmount },
	{ x: -RESET_ANTICIPATION },
	{ x:0 }
];

if (camera.x + Game.width == camera.right)
	bezier.shift();

duration = (panAmount * 4  + camera.x) / RESET_SCROLL_SPEED;
_resetPanTween = TweenMax.to (
	camera,
	duration,
	{
		bezier:bezier,
		ease:Linear.easeNone,
		onComplete:onResetComplete
	}
);

The motionPath() function is still there; look on line 94 of Actuate.hx.

You may not be able to recreate your code exactly, because it looks like you’re supplying points on the path and relying on GreenSock to draw a smooth curve through them. GreenSock provided a “proprietary algorithm” for this, and Actuate doesn’t yet have anything similar.

For now, you’ll need to figure out where to put the control points, then pass that information to this function:
https://github.com/openfl/actuate/blob/master/motion/MotionPath.hx#L35
(Also look just below it for an explanation of the line() function.)

I think I’d rather just daisey-chain tweens than use a 2d bezier tool for this. Does Actuate allow a sequence of tweens created at once without using anonymous functions? Something along the lines of TimelineMax/Lite

MotionPath can do something like that too; just stick to the line() function.

var path:MotionPath = new MotionPath();

//Set the starting points (optional).
path.line(startX, startY, 0);

//Add the waypoints.
path.line(x1, y1).line(x2, y2).line(x3, y3);

Actuate.motionPath(camera, duration, { x:path.x, y:path.y }).onComplete(onResetComplete);

and and can i specify a different easing for each one? For arguments sake can I apply different onComplete callbacks?

You can also chain like this:

Actuate.tween (myObject, 2, { x: 100 });
Actuate.tween (myObject, 2, { y: 100 }, false).delay (2);

…and so on. You basically set the delay you need, and you disable the auto-overwrite functionality in Actuate, so that it does not cancel out previous tweens. This lets you control the ease or another other part of the animation, just as you would want

That will do for now, thanks!