From the course: Blender: Tips, Tricks and Techniques

Fun with constraints: Elevator and Pivot - Blender Tutorial

From the course: Blender: Tips, Tricks and Techniques

Fun with constraints: Elevator and Pivot

- [David] Constraints can be really useful inside of Blender, and in this week's Blender Tips, Tricks, and Techniques, we're going to take a look at a few that I really like, the floor and pivot. Let me show you. First, let's open up this area, here, and let's get rid of the camera and the lamp, hit X, and then enter to delete, then hit Shift + A, and let's add a plane, S to scale it, and then let's take this cube and just put it right about here, little floaty and above the plane. Now, with the cube selected, I'm going to go ahead and go to constraint, floor, plane, and for the most part, nothing seems to happen until, well, until I hit the floor. Then you can see that my pivot, here, stops me from going further, and if I want to be really clever, I can hit Tab, Control + Tab, click on this face, Shift + S, cursor to selected, Tab to get out of edit mode, set origin, so Spacebar, set origin, or Shift + Control + Alt + C, Enter, origin to 3D cursor, and now, I can move my cube down, and hey, I'm hitting the floor. What do you know? Now, on top of that, I can grab said floor and now it's an elevator. Isn't that pretty neat? And of course, whatever default position it was at, so I can just zero it out, and I can just hit I, let's go to LocRocScale, come over here, G, Z, hit I, location rotation scale, and now I can hit play, A to unselect, and look at that, I have now made an elevator with just two or three clicks. Pretty handy. Now, let's make a new scene, Control + N, and let's delete the lamp and camera again, and let's show you the pivot constraint. So, to do that, let's pick anywhere in 3D space. Doesn't really matter where. Now, before I get a little further, you can just quickly use your 3D cursor, click on here, 3D cursor, and then rotate around an object, and that does give you a pivot the moment I hit R, and I can hit I, location rotation scale, and then rotate it back down, about here, hit I, location rotation scale, but it's not going to correctly translate through space. See that? Even though it looks like it does when I do this. So, let's make a brand new scene. Control + N, delete our camera and lamp. Again, come out to 3D space, click here, select our cube, bring it open, constraint, let's go to pivot, Shift + A, let's add an empty, plane axis is okay, back in our cube, empty, and now, with this on, I can specify always or different kind of range, so, let's just say I left it on negative X. R, negative X, look at that. At the moment I hit positive X, it won't rotate. Or, I could go to, say, Y, so now R X always rotates, but R Y only rotates when it's in the positive, or if I want to, I could just set the always and hit R R, and it's always rotating, and unlike our previous example, if I hit I, here, key that, and then come over here, hit R, and then hit I, in this case, it actually does correctly rotate. Isn't that pretty neat? So, the pivot constraint actually correctly rotates how you would imagine it, and if you're really crazy, you can select this empty, hit I, location, move it, move it over here, hit I, location, and now you got a really weird thing where it's rotating wherever this empty is going. Pretty cool, huh? And there you go, you now have a pretty cool rotating pivot constraint cube thing happening here. Like all things in Blender, there's an infinite amount of things that you can do with it, and tons to explore with all the different options inside of the constraint, so when you get in there, have some fun, and until next time, this is David for Blender's Tips, Tricks, and Techniques.

Contents