docs.unity3d.com
    Show / Hide Table of Contents

    Interface IXRActivateInteractor

    An interface that represents an Interactor component that can activate an Interactable component. Not to be confused with the active state of a GameObject, an activate event in this context refers to a contextual command action, such as toggling a flashlight on and off.

    Inherited Members
    IXRInteractor.registered
    IXRInteractor.unregistered
    IXRInteractor.interactionLayers
    IXRInteractor.transform
    IXRInteractor.GetAttachTransform(IXRInteractable)
    IXRInteractor.GetValidTargets(List<IXRInteractable>)
    IXRInteractor.OnRegistered(InteractorRegisteredEventArgs)
    IXRInteractor.OnUnregistered(InteractorUnregisteredEventArgs)
    IXRInteractor.PreprocessInteractor(XRInteractionUpdateOrder.UpdatePhase)
    IXRInteractor.ProcessInteractor(XRInteractionUpdateOrder.UpdatePhase)
    Namespace: UnityEngine.XR.Interaction.Toolkit
    Syntax
    public interface IXRActivateInteractor : IXRInteractor

    Properties

    shouldActivate

    (Read Only) Indicates whether this interactor is in a state where it should send the activate event this frame.

    Declaration
    bool shouldActivate { get; }
    Property Value
    Type Description
    Boolean

    shouldDeactivate

    (Read Only) Indicates whether this interactor is in a state where it should send the deactivate event this frame.

    Declaration
    bool shouldDeactivate { get; }
    Property Value
    Type Description
    Boolean

    Methods

    GetActivateTargets(List<IXRActivateInteractable>)

    Retrieve the list of Interactables that this Interactor could possibly activate or deactivate this frame.

    Declaration
    void GetActivateTargets(List<IXRActivateInteractable> targets)
    Parameters
    Type Name Description
    List<IXRActivateInteractable> targets

    The results list to populate with Interactables that are valid for activate or deactivate.

    Remarks

    When implementing this method, Unity expects you to clear targets before adding to it.

    See Also

    IXRActivateInteractable
    Back to top
    Terms of use
    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