I’m using iTween Paths to set up enemy movement in a 2D space shoot shooter game I’m working on. The only problem I’ve run into is that I can’t seem to properly orient to path, as the ship can never seem to point in the direction it’s moving, nor does it continue moving in any particular orientation. It seems to move in whichever direction is the most convenient at the time.
This is the iTween code, currently:
void Start ()
{
iTween.MoveTo(gameObject, iTween.Hash("path", iTweenPath.GetPath("path1"),"axis","x", "orientToPath", true, "time", 20, "easetype", iTween.EaseType.easeInOutSine)); //"orientToPath", true,
}
And this is my result. (Which seems correct enough, but not what I want.)
http://www.youtube.com/watch?v=sP8BCXMPl28&feature=youtu.be
So, how would I go about fixing this?