PDA

View Full Version : Going insane over Aim Constraints.


DataForge
08-24-2005, 08:11 PM
OK although I am doing something a little more complicated it can be reproduced by simply creating a cone and a locator, aim constraining the cube to the locator in only the Y axis (Actually it can be seen if done in all axis as well). It all works fine as long as the locators transform Y stays at 0 or below, but once it is greater than zero then it will not follow the locator when it is moved behind, it then flips and follows in a reverse direction. WTF???




OK, so I read the cryptic help section on history dependencies, up vectors, yada yada and started playing with different settings and the closest I can get is by setting the constraint up vector to the locators rotation and then I can get some very unpredictable results by rotating the locator when the locator moves behind my object. It canít be this hard, I have to be missing something totally obvious, please help me understand before I go insane :)





And if you are interested in exactly what I am trying to do: I have a mech that has a cannon that pitches in the x direction. This is parented to a base that yaws in Y. So I set up two aim constraints (one in x and the other in Y on each object group) so that it follows the locator without rotating in z. Sounds simple until you move the locator behind the mech and it pops to the front. Any help in understanding aim constraints would be very much appreciated.

JohnPark
08-25-2005, 07:14 PM
You should try changing the rotate order of the cannon (or whatever transform node is aim constrained to your target). This often fixes the problem when you aim constrain a single axis.
-JP

Morganism
08-26-2005, 05:52 AM
You could also try aim constraining a locator or something on all axis, and then using that to drive the pitch and yaw with direct connections or orient constraints on individual axis. For that you need to make sure that your rotation orders are correct as well.

john_homer
08-26-2005, 06:20 AM
or set up a single joint IK chain, and do away with the aim constraint altogether...

.j

DataForge
08-26-2005, 12:40 PM
Rotation order did it; I knew it was something completely obvious.



And I will have to play with the single joint IK chain idea, as aim constraints have left a bad taste in my mouth :).



Thanks all...

mestela
08-26-2005, 11:07 PM
or set up a single joint IK chain, and do away with the aim constraint altogether...

.j

aaah, nice tip mr. john! never really trusted those aim constraints, neat way to work around 'em.

cheers,

-matt

CGTalk Moderation
08-26-2005, 11:07 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.