HomeGuides
HomeGuidesLearn about the Immerse SDK installerLog In

Physical Hands

It can be useful for the avatar's hands to interact physically with the world e.g. hand not going through the wall, instead of the hand matching the controller position and going through everything. The physical hands feature of the SDK enables this physical behaviour on the hands.

XR Controller Physics

The XRControllerPhysics component should be placed on the tracked part of the hand and sets the visual part of the hand's position depending on how it is set up. When IsPhysical is set to true the visual part of the hand will react as part of Unity's physics system according to the Physics Settings set on the component.

776776

XR Controller Physics component

Description
HandThe visual part of the hand to match with the transform this component is on
XR InteractorThe interactor on this Hand
Physics SettingsThe settings configuration for when the hands are physical
Is PhysicalTrue if the hands should be in physical mode

Toggle Physical State

The physical state of the hands can be toggled at runtime in code by getting a reference to XRControllerPhysics and setting IsPhysical to true.

public void TogglePhysicalHand(XRControllerPhysics xrControllerPhysics)
{
    xrControllerPhysics.IsPhysical = true;
}

Related pages