I'm trying to get an object to rotate the way I want to through Quaternions. See my pictures for example, but I can't use Quaternion.LookRotation because that changes the Z rotation of the object and I don't want to do that. Pic 1: The 'leg/foot' is pointing at my ball using Quaternion.LookRotation. Looks good. Pic 2: Using Quaternion.LookRotation, notice the foot is not going the right direction, it's going up. This makes sense as to what LookRotation does, but not what I want. Pic 3: This is what I want, but I am manually rotating the object so I can show you. Ideally I want to call a function 'GetQuaternionToPointTo(Vector3 pos)'. I need to keep that rotation proper. Any thoughts? I might be able to solve this by changing the UP vector in that function, but does not completely because I want to drag the ball around and see the object correctly rotate and align the way I want.
Nevermind! I figured it out, I had to store the original UP vector to be used with the LookRotation call... Of course!