To test my slowly growing knowledge I made a 16x16 UV sphere, selected a few faces on one side of it, popped them off into a separate mesh § then tried to make that mesh into a hinged hatch or door into the sphere. Of course most edges of a UV sphere are at odd angles, and this was the challenge I was setting up for myself.
I tried this two different ways.
A)
- create an empty axis object.
- glue the axis object to an edge of the opening in the sphere
- rotate the axis object until one of its axes aligns with that edge.
- parent the axis object to the sphere.
- parent the hatch object to the axis (hinge).
- rotate the hinge object in local coords (on whatever axis seems to work) and the hatch opens and closes smoothly.
B)
- make a single bone
- carefully align the bone to one edge of the opening in the sphere.
- parent the bone to the sphere.
- parent the hatch to the bone
- rotate the bone in the appropriate local axis and hooray, the hatch opens and closes smoothly.
Then I want to place a rotation constraint on the hinge or bone, so that the hatch can only swing in the desired direction and only through a limited arc.
Here all hell breaks loose I select the hinge or bone, I impose a Rotation Constraint, selecting Local from the menu at bottom of the editor panel. As soon as I click on, say, X (limited by default 0-0), the hatch object twists wildly out of place. I then say to myself, ‘aha, I did have to rotate the hinge or bone object to line it up with the parent sphere edge, so I could read its rotation position in the data panel (n) and make the limits match its default position in the 2 unused axes’. So I try this… which sort of works, I can get the hatch object back into place; but when I try to place a constraint on the final axis (the actual hatch rotation action), I get very weird results; the hatch opens a few degrees then blinks back into place, or suddenly blinks into the interior of the sphere…
I am just a few Aha moments away from understanding the interactions of the coordinate systems, but not quite there yet – can someone help me figure this out? What I was hoping was to set up a rotation constraint in coordinate space that was entirely local to the repositioned empty axis object. So if my hatch is rotating with Y axis rotation of the empty, I wanted to limit X and Z to 0, and Y to a range of 0 to 90 degrees. I thought that this was how it would work, if I selected Local in the constraint editor (which I did).
I have been watching tutorials and reading the manual, trying to figure out where I went wrong, but am still in the dark. I think I followed instructions exactly, yet I can’t get a reasonable rotation constraint onto my hatches. [Therefore somewhere along the way I did not follow instructions exactly :-)] A zillion people must have solved this problem (or never even got confused in the first place) because of all the spacecraft and airplane modellers out there so I am hoping this is a classic n00b error and someone can put me right in one or two sentences.