Constrain only position but not orientation
-
- Posts: 9
- Joined: 11 Feb 2020, 15:11
Constrain only position but not orientation
Is there a way to constrain a child object only on x,y,z but keeping its initial orientation without scriping? I have a sensor child of my robot. During the simulation, my robot rotates and moves around but I want my sensor not to change its orientation but follow only the robot's position. Since I have other scripts I don't want my simulation to get heavier, I'd like to avoid adding another one.
Re: Constrain only position but not orientation
How about setting the orientation with respect to the world to the desired one?
Depending if your object is dynamically enabled you might need to connect it via revolute joints, and compute the joint angles that give you the desired orientation.
Depending if your object is dynamically enabled you might need to connect it via revolute joints, and compute the joint angles that give you the desired orientation.
Re: Constrain only position but not orientation
I'd add a simple
Cheers
non-threaded child script
to handle that. That won't change anything in terms of execution speed.Cheers