UxrStandardAvatarController ClassUxrAvatarController default implementation provided by UltimateXR to update user-controlled avatars. It is in charge of updating the avatar in the correct order, granting access to all features in the framework. By adding it to a GameObject with an UxrAvatar component, it will automatically update the avatar each frame.
Inheritance Hierarchy
System.Object
Object
Component
Behaviour
MonoBehaviour
UltimateXR.Core.Components.UxrComponent
UltimateXR.Core.Components.UxrComponent(UxrAvatarController)
UltimateXR.Core.Components.Composite.UxrAvatarComponent(UxrAvatarController)
UltimateXR.Avatar.Controllers.UxrAvatarController
UltimateXR.Avatar.Controllers.UxrStandardAvatarController
Namespace: UltimateXR.Avatar.Controllers
Assembly: UltimateXR (in UltimateXR.dll) Version: 0.0.0.0
Syntax
C#
[RequireComponent(typeof(UxrAvatar))]
public sealed class UxrStandardAvatarController : UxrAvatarController
The UxrStandardAvatarController type exposes the following members.
Constructors
Name | Description | |
---|---|---|
UxrStandardAvatarController |
Properties
Name | Description | |
---|---|---|
ArmIKElbowAperture | Gets or sets the arm IK relaxed elbow aperture. The value between range [0.0, 1.0] that determines how tight the elbows are to the body. | |
ControllerEvents | Gets the list of controller events. | |
IsLeftHandInsideFingerPointingVolume | Gets whether the left hand is inside an UxrFingerPointingVolume. | |
IsRightHandInsideFingerPointingVolume | Gets whether the right hand is inside an UxrFingerPointingVolume. | |
LeftControllerEvents | Gets the list of controller events that belong to the left hand. | |
LeftHandDefaultPoseName | Gets the pose name that is used for the default left hand animation. That is, the animation that is played when no other animation is played. | |
LeftHandDefaultPoseNameOverride | Gets or sets the pose name that overrides LeftHandDefaultPoseName if it is other than null. If it is set to null, LeftHandDefaultPoseName is back to being used. | |
LeftHandGrabButtons | Gets the button(s) that is/are required to play the left hand grab animation. That is, the animation that is played for the event that has the LeftHandGrab animation. | |
LeftHandGrabButtonsOverride | Gets or sets the button(s) that override LeftHandGrabButtons if it is other than Everything. If it is set to Everything, LeftHandGrabButtons is back to being used. | |
LeftHandGrabPoseName | Gets the pose name that is used for the left hand grab animation. That is, the animation that is played for the event that has the LeftHandGrab animation. | |
LeftHandGrabPoseNameOverride | Gets or sets the pose name that overrides LeftHandGrabPoseName if it is other than null. If it is set to null, LeftHandGrabPoseName is back to being used. | |
ProcessIgnoredInput | Gets or sets whether to also process ignored input for events. Input can be ignored by using SetIgnoreControllerInput(UxrHandSide, Boolean) and ProcessIgnoredInput tells whether to actually ignore it or not. By default the ignored input is also processed, which may seem counterintuitive but most of the time the input is ignored when specific objects are being grabbed. Since the avatar controller is responsible for triggering the grab events depending on user input, it was chosen that the default behaviour would be to also process ignored input. | |
RightControllerEvents | Gets the list of controller events that belong to the right hand. | |
RightHandDefaultPoseName | Gets the pose name that is used for the default right hand animation. That is, the animation that is played when no other animation is played. | |
RightHandDefaultPoseNameOverride | Gets or sets the pose name that overrides RightHandDefaultPoseName if it is other than null. If it is set to null, RightHandDefaultPoseName is back to being used. | |
RightHandGrabButtons | Gets the button(s) that is/are used to play the right hand grab animation. That is, the animation that is played for the event that has the RightHandGrab animation. | |
RightHandGrabButtonsOverride | Gets or sets the button(s) that override RightHandGrabButtons if it is other than Everything. If it is set to Everything, RightHandGrabButtons is back to being used. | |
RightHandGrabPoseName | Gets the pose name that is used for the right hand grab animation. That is, the animation that is played for the event that has the RightHandGrab animation. | |
RightHandGrabPoseNameOverride | Gets or sets the pose name that overrides RightHandGrabPoseName if it is other than null. If it is set to null, RightHandGrabPoseName is back to being used. | |
UseArmIK | Gets or sets whether the avatar controller is using IK for the arms. | |
UseBodyIK | Gets or sets whether body IK are used. |
Methods
Name | Description | |
---|---|---|
CanHandInteractWithUI | Gets if the hand is available to interact with UI elements, such as pressing buttons. This is used by the UI interaction system to ignore the hand for these events. For example, when the hand is holding an object it could be desirable to not let it interact inadvertently with any user interface. (Overrides UxrAvatarController.CanHandInteractWithUI(UxrHandSide).) | |
SolveBodyIK | Solves the body IK using the current headset and controller positions. |
Extension Methods
Name | Description | |
---|---|---|
CheckSetEnabled | Enables/disabled the component if it isn’t enabled already. (Defined by MonoBehaviourExt.) | |
GetOrAddComponent<T> | Gets the Component of a given type. If it doesn’t exist, it is added to the GameObject. (Defined by ComponentExt.) | |
GetPathUnderScene | Gets the full path under current scene, including all parents, but scene name, for the given component. (Defined by ComponentExt.) | |
GetSceneUid | Gets an unique identifier string for the given component. (Defined by ComponentExt.) | |
GetUniqueScenePath | Gets an unique path in the scene for the given component. It will include scene name, sibling and component indices to make it unique. (Defined by ComponentExt.) | |
LoopCoroutine | Creates a coroutine that simplifies executing a loop during a certain amount of time. (Defined by MonoBehaviourExt.) | |
SafeGetComponentInParent<T> | Gets the Component of a given type in the GameObject or any of its parents. It also works on prefabs, where regular GetComponentInParent(Type, Boolean) will not work: https://issuetracker.unity3d.com/issues/getcomponentinparent-is-returning-null-when-the-gameobject-is-a-prefab (Defined by ComponentExt.) | |
ShowInInspector(Boolean) | Overloaded. Controls whether to show the current object in the inspector. (Defined by ObjectExt.) | |
ShowInInspector(Boolean, Boolean) | Overloaded. Controls whether to show the current object in the inspector and whether it is editable. (Defined by ObjectExt.) | |
ThrowIfNull | Throws an exception if the object is null. (Defined by ObjectExt.) |