First Person Lean

Note: This ability is only available with the first person perspective.

The Lean ability will rotate the first person camera to mimic the character leaning left or right. This ability does not change the actual rotation of the character.  This allows the character to peak around a corner without exposing their body. The ability can use a collider to prevent the camera from intersecting with other objects as it leans.

Setup

  1. Select the + button in the ability list under the “Abilities” foldout of the Ultimate Character Locomotion component.
  2. Add the First Person Lean ability
  3. A Capsule Collider will automatically be added under the Character/Colliders Game Object. This Capsule Collider should be adjusted to account for the amount of collision detection that the ability does. When another object enters this collider the Lean ability will reduce the amount that it leans.

Inspected Fields

Distance

The distance that the camera should lean.

Tilt

The amount of tilt to apply while leaning (in degrees).

Item Tilt Multiplier

A tilt multiplier applied to the items.

Collider

An optional collider that can be used for collision detection and hit points.

Collider Offset Multiplier

Optionally modify the distance that the collider leans.

Max Collision Count

The maximum number of collisions that can be detected by the collider.