- Home /
The question is answered, right answer was accepted
iTween - look for new path, move to or reverse at end?
I would like my object to look for a new path when it reaches the end of current path. if new path is found (within x distance) object moves to and follows new path. if no path is found object reverses direction on current path. I am very new to unity, my background is modeling and animating in 3ds, very new to coding, sorry (hopefully) if there is simple answer, but could not find it searching, thanks
How do you store the paths: Array of paths? A path assigned to empty game objects?
Paths are typically defined by an array of points (Vector3s). How is the distance measured: From the endpoint of the new path? From one of the Vector3s that define the path? Or from any position on the path?
to answer robertbu, I plan on attaching each path to an object in the scene that the user can move, the user would move the paths around the scene to manipulate a character's position in the scene. the paths would be measured from the end point on the path that the character has reached to the end point of the new path
@maclaine - $$anonymous$$y answer would have taken a bit different approach but I needed the additional information. But it looks like you got an answer you are happy with.
Follow this Question
Related Questions
iTweens MoveTo and "path" property 7 Answers
itween MoveTo IndexOutOfRangeException 0 Answers
Using iTween to chain multiple paths together 2 Answers