> For the complete documentation index, see [llms.txt](https://earnest-robot.gitbook.io/auto-hand-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://earnest-robot.gitbook.io/auto-hand-docs/auto-hand/auto-hand-player.md).

# Auto Hand Player

## Player Movement

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FZWBQ5ad4sYY8ADIT1HMM%2Fimage.png?alt=media&amp;token=31d0d538-a78d-4888-a42c-848933944199" alt="Where this components is found on the demo hands"></div>

Auto Hand Player is an optional rigidbody movement system that is compatible with auto hand. This system includes smooth movement, turning, grounding, platforming, climbing, and pushing

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FfpHhmJXM08wSH1pGYl0i%2Fimage.png?alt=media&amp;token=361a4b4b-0584-4f95-927d-4e925f778641" alt=""></div>

### Setup

`Head Camera` is the tracked VR camera

`Forward Follow` is what determines the forward direction of your movement axis. Recommend using the camera or controller. Using the camera as forward transform: pushing the thumbstick forward will move the direction the camera is facing

`Tracking Container` this should be an empty object containing the Hands, Controllers, Tracked Camera and [Fullbody ](/auto-hand-docs/auto-hand/full-body-vrik.md)(if used). This tracking container should NOT be placed under the Auto Hand Player but should be under the same parent as the Auto Hand Player

`Hand Right` Right hand the player is using

`Hand Left` Left hand the player is using

### Movement

`Max Move Speed` the maximum speed the movement can go

`Move Acceleration` the rate at which the player accelerates to match the target move speed.&#x20;

* Turn this up high if you want the player to instantly be at the max speed when they start moving lower for slower transition between starting and stopping movement

`Grounded Drag` the amount of drag to apply while the player is grounded. This will act as the extra stiffness someone would have while standing on the ground vs falling when a force is applied

`Height Smooth Speed` Height smoothing occurs when walking up a staircase or ramp. Height smoothing speed helps replace jarring height changes in VR with smoother steps like would occur while walking

### Snap Turning

Turning off the snap turning toggle will enable smooth turning and reveal smooth turn speed

`Snap Turning Angle` the angle around the y-axis to rotate on a snap turn input 0-360

`Smooth Turn Speed` the smooth turning speed for

### Height

`Height Offset` takes a positive or negative value and will offset the height of the player by that amount&#x20;

`Crouching` toggleable, will reduce/add the crouch height when enabled/disabled

`Crouch Height` the amount of height to reduce the player when crouch is enabled

`Auto Adjust Collider Height` if true the local capsule collider will automatically adjust its height to match the head height

`Min Max Height` the min max height of the capsule collider. Good for preventing players from getting to places they shouldn't my crawling on the floor or maxing their height

`Use Head Collision` Whether or not the head camera should use collision to prevent the camera from going through objects or not. Head will collide with same collisions as body

`Head Radius` The radius of the head collision

### Grounding

You can disable grounding to enable flying

Grounding will keep the player locked on the ground. It manages stepping up slopes and stairs.

`Max Step Height` the maximum allowed step height

`Max Step Angle` the maximum allowed surface angle in degrees to walk on: 0 is flat, 45 is a half angled slope 70 is a very steep slope and 90 is a vertical surface&#x20;

`Ground Layer Mask` grounding will only occur when touching objects in these physics layers

## Climbing

If climbing is enabled on the Auto Hand Player and the player is holding a grabbable with the climbable component, climbing will be activated. While climbing is activated the player body will try to move to fill the difference between the controller and the hand(s).

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2F0Cpb7etlDa0qrHJ7tDIs%2Fimage.png?alt=media&amp;token=9fc3ed43-5a4f-4d44-b765-b3090baa9d55" alt="Goes onto a grabbable object to activate climbing      Climbing can also be activated by a connected stabber"></div>

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2F2OgVBIqMpEVqDB3CRULt%2Fimage.png?alt=media&amp;token=806efda7-7f12-4dca-8e05-abeeb240bbd5" alt=""></div>

`Allow Climbing Movement` if true, the player can move with the thumbstick movement while climbing is activated

`Climbing Strength` scales the target velocity by this vector3

`Climbing Acceleration` how quickly the velocity can move to the target velocity (prevents jitter, do not turn too high)

`Climbing Drag` the drag applied to the player body&#x20;

## Pushing

Works similarly to climbing but activates from hand collision with an object that has the **Pushable** component. Pushing is not recommended on dynamic objects

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FvfIuZjLzACiv5SpI8UwQ%2Fimage.png?alt=media&amp;token=4c14c7c0-f4f9-4f20-ac62-000d67b2fa8a" alt="Goes on an object to activate pushing with hand collision"></div>

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FjQvbBcv5ngonlFqtFM3y%2Fimage.png?alt=media&amp;token=fc8cca43-a765-41dc-a32d-a603d30755b3" alt=""></div>

`Pushing Strength` scales the target velocity by this vector3

`Pushing Acceleration` how quickly the velocity can move to the target velocity (prevents jitter, do not turn too high)

`Pushing Drag` the drag applied to the player body&#x20;

## Platforming

If enabled, the auto hand player will automatically platform any ground it's currently grounded to that also exists in the platforming layer mask. Platforming will move/rotate the player with whatever it's standing on

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FqnZo9Ss2NS1GQR3YqFB0%2Fimage.png?alt=media&amp;token=48da9c00-7bcd-4b84-9c10-b16da36fefee" alt=""></div>

`Platforming Layer Mask` the physics layers to enable automatic platforming on

## Jumping

The Auto Hand Player script includes a simple Jump function that works by temporarily disabling grounding and applying an upward velocity force to the player rigidbody

```
AutoHandPlayer player = GetComponent<AutoHandPlayer>();
player.Jump(strength);
```

## Controller Input

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FvSOAYkCowEPmOs2VFJHu%2Fimage.png?alt=media&amp;token=edabe0df-10c5-483f-91fd-ef2e71804f5d" alt="Where this components is found on the demo hands"></div>

Manages input for the Auto Hand Player movement and turning axis

{% tabs %}
{% tab title="OpenXR" %}

## OpenXRHandPlayerControllerLink

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FhQmAo6tKzGPmqwrSag4e%2Fimage.png?alt=media&amp;token=85c76e66-2aff-4b12-a1a5-09ee53ef9bc2" alt=""></div>
{% endtab %}

{% tab title="XR" %}

## XRHandPlayerControllerLink

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FrWI3Jx5EfPDp839JDv8V%2Fimage.png?alt=media&amp;token=29a77570-5789-4fd3-8521-7f3225f3cdec" alt=""></div>
{% endtab %}

{% tab title="Oculus Integration" %}

## OVRHandPlayerControllerLink

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FCbDl8repwrim9d2hMfjT%2Fimage.png?alt=media&amp;token=362d5cef-da4f-4898-8cb0-10c5c16946b6" alt=""></div>
{% endtab %}

{% tab title="SteamVR" %}

## SteamVRHandPlayerLink

<div align="left"><img src="https://2959669391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5zKO0EvOjzUDeT2aiFk3%2Fuploads%2FeyEiI0KPZAYgiWv32Aza%2Fimage.png?alt=media&amp;token=f6f08e2b-bd1e-4fbb-9767-a66e6da3a952" alt=""></div>
{% endtab %}
{% endtabs %}
