Class TapInteraction | Input System | 1.0.2
docs.unity3d.com
    Show / Hide Table of Contents

    Class TapInteraction

    Performs the action if the control is pressed held for at least the set duration (which defaults to defaultTapTime) and then released.

    Inheritance
    Object
    TapInteraction
    Namespace: UnityEngine.InputSystem.Interactions
    Syntax
    [Preserve]
    public class TapInteraction : IInputInteraction

    Fields

    duration

    The time in seconds within which the control needs to be pressed and released to perform the interaction.

    Declaration
    public float duration
    Field Value
    Type Description
    Single
    Remarks

    If this value is equal to or smaller than zero, the input system will use (defaultTapTime) instead.

    pressPoint

    The press point required to perform the interaction.

    Declaration
    public float pressPoint
    Field Value
    Type Description
    Single
    Remarks

    For analog controls (such as trigger axes on a gamepad), the control needs to be engaged by at least this value to perform the interaction. If this value is equal to or smaller than zero, the input system will use (defaultButtonPressPoint) instead.

    Methods

    Process(ref InputInteractionContext)

    Declaration
    public void Process(ref InputInteractionContext context)
    Parameters
    Type Name Description
    InputInteractionContext context
    Implements
    IInputInteraction.Process(ref InputInteractionContext)

    Reset()

    Declaration
    public void Reset()
    Implements
    IInputInteraction.Reset()
    In This Article
    • Fields
      • duration
      • pressPoint
    • Methods
      • Process(ref InputInteractionContext)
      • Reset()
    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