Anim8or Community
General Category => ASL Scripts => Topic started by: Pirmin on October 11, 2008, 04:38:35 am
-
I have a vehicle the does some movements (I start with a circle).
My vehicle always should look ahead where it is moving to.
I will write the Location Controllers to do more movements (e.g. lines, curves, ...) depending on the current frame.
I could in parallel write Orientation Controllers to set the desired orientation at any location.
Isn't there a way to just write a single Orientation controller which always assures that the orientation stays ahead?
-
You can try creating only the position controller and set the orientation to "facing path".
-
I have tried a lot.
- Relative to Parent -> Vehicle is allways looking to Z direction
- Relative to Path -> Vehicle is allways looking to X direction
- Relative to Other, Path -> Error: No such element
- Relative to Facing Other, Path -> Error: No such element
???
-
Oh, sorry, I wrote "facing path", I meant "Relative to Path"... Yes, you're right, I've just tried it and I found out that the "relative to path" function doesn't work when the path is created by a controller script...
I'm afraid you'll have to animate the orientation by hand... Or you can use key frames instead of a controller script for position - that would make "relative to path" work correctly...
-
Hmm. The problem with controller scripts for position is that they have no derivative - i.e. direction. They only return the position at a specific frame. I suppose I could evaluate the position at frame N-1 and N+1 and use those to create a derivative. This would require me to change how controllers are evaluated in general. Now Anim8or assumes that only one frame's data is needed at a time.
-
To solve my problem I have used key frames for animation as proposed by Kubajzz.
Therefore I don't need the feature "look ahead".
But I think it could be usefull in future for me and for others.
-
Sounds like a good idea, random moving objects in the background would be a lot easier for people who are able to actually write that sort of script, it would free up a lot of time.
eg.
Get random planes to fly around, without having to make them face the right way frame by frame.
-
this might help ....http://www.anim8or.com/smf/index.php?topic=959.0