How I can split rotation between 2 joints?

Hello guys. I have robot model, which has 2 motors on his neck. Robot should be able to look towards certain objects, but I have problems with calculating CFrames. I need to split rotation between 2 motors, like red lines with dots on image:


Left is initial state, right: red - what I want to achieve, green - target rotation, pinks - lines for showing angles,
blues - angles themselves.
How I can do this thing in 3D?

4 Likes

so… just simple inverse kinematics?

2 Likes

I can’t use them in my situations, because for joints I used rigid constraints with attachments. + I need some sort of specific calculations due to how robot built