docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method GetRefROOptional

    GetRefROOptional(Entity)

    Obsolete. Use TryGetRefRO(Entity, out RefRO<T>) instead.

    Declaration
    [Obsolete("This function was not intended to be in the public API, and it will be removed in a future release.")]
    public RefRO<T> GetRefROOptional(Entity entity)
    Parameters
    Type Name Description
    Entity entity

    The referenced entity

    Returns
    Type Description
    RefRO<T>

    Returns a safe reference to the component data, or an invalid reference if entity does not have component T.

    In This Article
    Back to top
    Copyright © 2025 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)