Character Setup
The fastest way to set up a character and a camera is the setup tools in the Game Creator menu. You can also pick every part by hand in the Character and Shot Camera inspectors.
It is highly recommended to look at the included examples first. They show a finished player character, camera and weapons. See Examples on the Getting Started page.
Set Up the Character
- Select your player character.
- Run Game Creator > Full Body Awareness Controller > Setup Selected Character.
The setup does the following:
- Sets the Player unit to Full Body Awareness.
- Sets the Rotation unit to Full Body Awareness.
- Adds the Full Body Awareness, Turn In Place and Breathing rigs to the IK list. You find them in the Full Body Awareness Controller folder of the IK rig list.
- Asks where to save a Held Item Profile with all the held item modifiers, and sets it as the rig's Default Profile. Pick an existing profile to share it between characters.
- Removes Shooter's Shooter Human rig if the character has one.
Running the setup again keeps your units, rigs and profile. It only adds what is missing.
Shooter Human Is Not Needed
The Full Body Awareness rig has its own IK for the arms, the held item and leaning. That is the one to use. The setup removes Shooter's Shooter Human rig for you.
If a character still has a Shooter Human rig, it is switched off while the Full Body Awareness rig is active, and switched back on when the rig is disabled. Firing, accuracy, reloads, crosshairs and sights keep working either way.
Keep the Shooter Human rig if your game can switch to a third person camera. It then aims the weapon in third person. See First and Third Person below.
Shooter's own Lean instruction only works through the Shooter Human rig. Use this package's Lean instruction instead.
Other Rigs on the Character
Some rigs fight the Full Body Awareness rig. Check the IK list of the player:
| Rig | What to do |
|---|---|
| Look To | Disable it. It turns the head away from the view. |
| Aim Towards | Disable it. It turns the spine away from the view. |
| Breathing (Game Creator) | Remove it. Use this package's Breathing rig instead, or the chest breathes twice. |
| Lean with Momentum | Keep it if you like. It runs before the Full Body Awareness rig reads the pose. |
| Align Feet with Ground | Remove it from characters with Turn In Place, and turn on Align Feet in Turn In Place instead. |
The setup writes a warning in the Console when it finds one of these rigs.
Set Up the Camera
- Select the Shot Camera used by your Main Camera.
- Run Game Creator > Full Body Awareness Controller > Setup Selected Shot Camera.
- Mark it as the Main Shot.
This sets the shot type to Full Body Awareness, and sets the Main Camera's Near Clip Plane to 0.01 if it is higher. See Camera Shot for its settings.
The Near Clip Plane of the Main Camera must be 0.01. Setup Selected Shot Camera sets it for you. If you set up the camera by hand, set it yourself. Unity's default of 0.3 cuts away anything close to the camera, so walls, your arms, the held item and your own body look like they clip. Most clipping in first person comes from this value.
The camera is kept out of walls on the layers in the rig's Eye > Wall Layers. Walls, ladders, cover and anything else you can walk up to must be on a layer in that list, or the camera can go into them.
Lock the Cursor
Lock the cursor with Game Creator's Cursor Lock instruction when the scene starts, for example in a Trigger with On Start.
Set Up by Hand
| Where | What to pick |
|---|---|
| Character > Player | Full Body Awareness |
| Character > Rotation | Full Body Awareness |
| Character > IK | Full Body Awareness, Turn In Place and Breathing |
| Shot Camera > Shot Type | Full Body Awareness |
Player Unit
The Full Body Awareness Player unit moves the character relative to where you look. Its Input Move field picks the move input, like Game Creator's own Player units.
Rotation Unit
The Full Body Awareness Rotation unit turns the hips under the view. While moving, the body faces the view. While standing still, the upper body twists first, and the hips only turn when the twist gets too large.
| Setting | Default | What it does |
|---|---|---|
| Move Threshold | 0.15 | Speed in m/s above which the character counts as moving. |
| Moving Turn Time | 0.07 | Seconds of smoothing while moving. |
| Idle Turn Threshold | 65 | Degrees the upper body can twist before the legs turn. |
| Idle Turn Time | 0.16 | Seconds of smoothing for a standing turn. |
| Idle Turn Stop Angle | 4 | Degrees from the view at which a standing turn stops. |
| Max Twist | 100 | The largest twist between the hips and the view, in degrees. |
When the Turn In Place rig is on the character, it takes over the standing turns. See Turn In Place.
Facing layers, like instructions that turn a character towards a target, are ignored by this unit, because the view drives the body. Use the Set Look Direction or Look At instructions instead.
First and Third Person
You can switch the player between first and third person by changing the camera shot, with Game Creator's Change to Shot instruction. Nothing else needs to change.
When a shot other than Full Body Awareness is active:
- The Full Body Awareness rig steps back. The head shows again, and the body plays its animation like any Game Creator character.
- The Player unit moves the character relative to the camera, like Game Creator's Directional unit.
- The Rotation unit turns the character towards where it moves. While holding a weapon, it faces where the camera looks.
- A Shooter Human rig on the character aims the weapon. Keep one on the character if you use third person.
When you switch back, the first person view starts facing where the body faces, so you keep moving the same way.
Use a cut, with a Duration of 0, when changing to the Full Body Awareness shot. The head is hidden as soon as that shot is active, so a slow transition would show the body without a head.
Use the Is First Person condition to check which view is active. The Shooter 2 examples and the Combined Example toggle the view with V. See Trigger_Toggle_View in their scenes. Aiming down sights is also limited to first person there, because a Scope Through sight puts the weapon in front of the camera.
NPCs and Other Characters
Full Body Awareness is only for the player. NPCs and other characters don't need it. Keep them on Game Creator's own units and rigs.