Working with Unity's multi-purpose camera rig
Unity provides some Camera rigs, which can make setting up scenes much faster and help to test out ideas. In this recipe, you'll use a 3rd Person Character and the multi-purpose camera rig from the default Unity asset packages to quickly create a scene with a camera that automatically follows a character as it moves, smoothing rotating behind the character as the character changes direction:

How to do it...
To work with Unity's multi-purpose camera rig, just follow these steps:
- Create a new Unity 3D scene.
- Import the Characters and Cameras Asset Packages: use menu: Assets | Import Package ... | Cameras & Characters.
- You should now have a
Standard Assets
folder in your Project panel, containing theCameras
andCharacters
folders (and possibly some others, such asCrossPlatformInput
,Editor
, and so on). - Create a 3D Plane in your Scene.
- Add a clone of the
ThirdPersonController Prefab
to your Scene. Do this by dragging theThirdPersonController Prefab...