Grasping and throwing objects

When animating a scene, you will often have to animate a character interacting with props, such as grasping a cup of tea, a sword, a gun, or a flower bouquet. These props are not part of the main rig, but you need a way to control them easily.

Let's imagine a scene where our character finds a giant diamond and picks it up with his left hand.

How to do it...

  1. Open the file 006-Props.blend. It has our character Otto in front of a stand with a big diamond on top. The character has a very basic animation with three Extreme positions defined to pick the diamond with his left hand. The next screenshot shows the first keyframe:
    How to do it...
  2. Press Alt + A to see the animation. The character reaches out for the diamond with his left hand and tries to take it from the stand, but there's something wrong: the diamond remains still. That's because we need to tell Blender to make the diamond follow the character's hand at a certain point in the animation, and we're going to do this with a constraint.
  3. Go to frame 8, where the character reaches the diamond and closes his hand over it. This is the moment where the "holding" happens, and the diamond needs to start following the hand. This frame is also where we need to set the constraint.
  4. Select the Hand.L bone, hold Shift, and select the Diamond mesh. Blender automatically changes to Object Mode, since you're selecting two objects of different types. Now, press Ctrl + Shift + C and choose the Child Of constraint, as seem in the next screenshot:
    How to do it...
  5. With the Diamond mesh selected, go to the Object Constraints tab in the Properties window and find the constraint you've just added. In the Bone field, select Hand.L. You'll see that the diamond changes its position, so click on the Set Inverse button to make it go back to its original place. That's why we need to set the constraint on the frame where the holding action begins: this is the position Blender has to take into account when evaluating the constraint, and the reason why we clicked on the Set Inverse button.

    Now, if you play the animation again, you'll see that the diamond is attached to the hand even before the hold action happens, which is not what we want. We need to animate the influence of the constraint.

  6. Go to frame 8, where the holding happens, and navigate to the Object Constraints tab in the Properties window for the Diamond object. Right-click over the Influence slider and select the Insert Keyframe option.
  7. Now go back one frame (Left Arrow), set the Influence slider to 0, right-click over it again, and set a new keyframe. If you play the animation again, you'll see that everything works as expected, and our character successfully takes the giant diamond. The file 006-Props.blend has the complete example, and the next screenshot shows the three keyframes of this animation:
How to do it...

How it works...

You can use a Child Of constraint for an object to make it follow a character's bone. By carefully defining the constraint in the frame where the contact takes place and animating its influence on the timeline, you can make your character interact with props.

There's more...

You can use the same principle to throw an object away. You should set a constraint and animate its influence in the opposite way, from 1 to 0 on the frame where the object should be thrown. From that point, you should animate the object independently.

See also

Chapter 8: Animating a Tennis Serve

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.191.181.36