docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method TryGetColorFromInstanceId

    TryGetColorFromInstanceId(uint, out Color32)

    Retrieve the color that is mapped to the passed in ID. If the ID is 0 or 255 false will be returned, and color will be set to black.

    Declaration
    public static bool TryGetColorFromInstanceId(uint id, out Color32 color)
    Parameters
    Type Name Description
    uint id

    The ID of interest.

    Color32 color

    Will be set to the color associated with the passed in ID.

    Returns
    Type Description
    bool

    Returns true if the ID was mapped to a non-black color, otherwise returns false

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