docs.unity.cn
Search Results for

    Show / Hide Table of Contents

    Property hitClosestOnly

    hitClosestOnly

    Whether Unity considers only the closest Interactable as a valid target for interaction.

    Declaration
    public bool hitClosestOnly { get; set; }
    Property Value
    Type Description
    bool
    Remarks

    Enable this to make only the closest Interactable receive hover events. Otherwise, all hit Interactables will be considered valid and this Interactor will multi-hover.

    See Also
    GetValidTargets(List<IXRInteractable>)
    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)