Notifications
Clear all

[Closed] getting attach prop offsets

I’m working on a game engine weapon/prop attachment scheme,
I need to extract the offset pos and rotation of a weapon prop form its parent joint in a skeleton.

can it really be this simple?


offset_pos=$attachment_01.pos-$attachment_01.parent.pos
offset_rotation= $attachment_01.rotation-$attachment_01.parent.rotation

seems too easy…am I over looking something?

1 Reply
1 Reply
(@denist)
Joined: 11 months ago

Posts: 0

your disbelief is absolutely appropriate…
to transform in parent coordinate system (‘transform offset’ in your terminology) is


 <node>.transform * (inverse <node>.parent.transform)