Hi, after having started watching Cult of Rig I’ve been trying to recreate the different constraints using standard Maya nodes.

In trying to find a solution for the aim constraint I stumbled upon a post on Lester Banks - the issue I found while trying to implement this one with nodes was I had no idea how to create a quaternion that specifies the rotation around a vector with a given angle.

My final solution was creating a vector for aim, up and the cross of those. Then supplying those to a 4x4 matrix to give it’s X, Y and Z axis directions, which I then decomposed and took the rotation from. In tests this have acted just like the aim constraint, but the above solution in code still eludes me how to implement using nodes.

Is it worth putting more time and effort into implementing this using quaternions or should the rotations from 4x4 matrices be stable enough to use?

Also as a more general question in implementing constraints using maya nodes, how do one steer clear of cycles. ie: getting the position of the position of an object that I later down the chain will want to rotate?