Jim is now taking a lot of steps, but he’s still not moving in space! The following directions will show you how to use a constraint to make him follow a path while he walks:
1. Create a path by pressing Shift + A and then click Curve > Path.
2. Edit the points (in Edit Mode) of the curve to describe the path you want Jim to take. In this case, it should be a straight line. You can leave only two points of the curve, set the start point at the origin of the scene where Jim is located, and align the end point on the Y-axis. You might need to change the handles’ direction to make the curve’s interpolation linear; a quick way to do it is to select the vertices and press V: you’ll see a menu where you can pick the interpolation type for the selected vertices, click Linear, and you’ll be left with a straight line.
3. In Object mode, select Jim’s rig and apply a constraint to it. Go to the Constraints tab in the Properties Editor and add a Follow Path constraint to it.
4. In the Follow Path constraint menu, select the path you just created as the path. If it doesn’t work automatically when you play the animation, click the Animate Path button. If you want a curved path, activate the Follow option so the character turns with the path.
5. Select the path and, on the Curve tab of the Properties Editor, adjust the number of Frames that Jim will use to go from the start to the end of the path in the Path Animation panel. Adjust this parameter as well as the length of the curve and the speed of the walking cycle until you get a nice result and Jim’s feet look as planted as possible without sliding over the floor (feet sliding is a common side effect of working with animation cycles, so be aware of this). You can activate the grid on the floor and add more lines to it in the Display panel of the Properties Region in the 3D View to have a reference to how Jim is moving across the floor, as shown in Figure 12.7.
18.116.85.12