Hi, I'm a newbie.
I am trying to make a mesh follow a L path.
How's the best way to achieve it? Create 2 straight fly animators or a follow spline animator?
If it is possible please show me a code snippet
Thanks y'all
L path
-
The Onslaught
- Posts: 41
- Joined: Mon Jan 29, 2007 3:33 pm
L path
After reading this sentence you will realize you have wasted 5 seconds of your life
-
Radikalizm
- Posts: 1215
- Joined: Tue Jan 09, 2007 7:03 pm
- Location: Leuven, Belgium
A spline sounds like a good option to achieve this, check out the API for the follow spline animator (link) to see how it should be used
-
The Onslaught
- Posts: 41
- Joined: Mon Jan 29, 2007 3:33 pm
-
Radikalizm
- Posts: 1215
- Joined: Tue Jan 09, 2007 7:03 pm
- Location: Leuven, Belgium
-
The Onslaught
- Posts: 41
- Joined: Mon Jan 29, 2007 3:33 pm
-
Radikalizm
- Posts: 1215
- Joined: Tue Jan 09, 2007 7:03 pm
- Location: Leuven, Belgium
You could take the hacky route and check every frame at which position your mesh is and rotate it accordingly, but I'd rather suggest that you check out the implementation of the follow spline animator, and that you implement your own animator using this code, altering it to take your rotation into account
This would be the cleanest way to achieve what you want
This would be the cleanest way to achieve what you want
-
The Onslaught
- Posts: 41
- Joined: Mon Jan 29, 2007 3:33 pm
-
Radikalizm
- Posts: 1215
- Joined: Tue Jan 09, 2007 7:03 pm
- Location: Leuven, Belgium
To be honest, I haven't used the animator that much, so I can't give you an answerThe Onslaught wrote:Alright, it seems that my own implementation will be the only way to achieve this, thanks Radikalizm for your help.
One last question, in order for the path to go straight, the spline tightness should be 0 or 1?
You should try and see what works, or wait until someone else can answer your question
EDIT:
By the way, when you finish your animator (if you're going for the custom implementation that is) it might be a good idea to post it in the code snippets forum if you would be willing, I could see more people wanting this kind of animator
