Forums > Jitter

bug: jit.anim.node getworldpos message

January 21, 2012 | 8:25 am

I’m trying to find the absolute position of an object that’s controlled by a jit.anim.node – but when I change the position of the node (or any of its parent nodes) & then send the message "getworldpos" to the node, the node reports the previous position. (Sending the message "getposition" works correctly.)

Example:

– Pasted Max Patch, click to expand. –

January 22, 2012 | 7:08 pm

the anim.node needs to update after it’s local position is changed, before it will report the correct world position.

updates are normally triggered when attached gl objects are drawn.

you can trigger an update manually with a bang to a jit.anim.node object.
so, to fix your problem, simply put a bang in between the position message and the getworlpos message.


Viewing 2 posts - 1 through 2 (of 2 total)