PrevTransform? (SOLVED)

I currently have an object moving on a motion path within a sequence and I’m trying to get the current location and the previous transform so I can figure out a particular vector, but I keep getting the same values for both. Anyway ideas?

You can ask the NurbsCurve itself for the tangent vector at a given time t. This might be easier to get, faster to compute, and more accurate.

However, to answer your direct question, if you’re querying np.getPrevTransform() you should be aware that this is really designed for the collision system, but you can make use of it. For an object flying on an interval you need to specify fluid = 1 to the interval constructor to allow it to set the prevTransform as it moves.

David

Well, I did figure something out. All I did was created a variable called prevPos for my object and did my script with it and then set prevPos to the object’s current position with a task. It worked for what I was doing. I’m not sure if it was the best approach though.