docs.unity3d.com
    Show / Hide Table of Contents

    Class InputActionManager

    Use this class to automatically enable or disable all the inputs of type in a list of assets of type .

    Inheritance
    Object
    InputActionManager
    Namespace: UnityEngine.XR.Interaction.Toolkit.Inputs
    Syntax
    public class InputActionManager : MonoBehaviour
    Remarks

    Actions are initially disabled, meaning they do not listen/react to input yet. This class is used to mass enable actions so that they actively listen for input and run callbacks.

    Properties

    actionAssets

    Input action assets to affect when inputs are enabled or disabled.

    Declaration
    public List<InputActionAsset> actionAssets { get; set; }
    Property Value
    Type Description
    List<InputActionAsset>

    Methods

    DisableInput()

    Disable all actions referenced by this component.

    Declaration
    public void DisableInput()
    Remarks

    This function will automatically be called when this InputActionManager component is disabled. However, this method can be called to disable input manually, such as after enabling it with EnableInput().
    Note that disabling inputs will only disable the action maps contained within the referenced action map assets (see actionAssets).

    See Also
    EnableInput()

    EnableInput()

    Enable all actions referenced by this component.

    Declaration
    public void EnableInput()
    Remarks

    This function will automatically be called when this InputActionManager component is enabled. However, this method can be called to enable input manually, such as after disabling it with DisableInput().
    Note that enabling inputs will only enable the action maps contained within the referenced action map assets (see actionAssets).

    See Also
    DisableInput()

    OnDisable()

    See .

    Declaration
    protected void OnDisable()

    OnEnable()

    See .

    Declaration
    protected void OnEnable()
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023