docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method FindItemsByDefinition

    FindItemsByDefinition(InventoryItemDefinition, ICollection<InventoryItem>)

    Gets items filtered with the specified definition.

    Declaration
    public static int FindItemsByDefinition(InventoryItemDefinition definition, ICollection<InventoryItem> target)
    Parameters
    Type Name Description
    InventoryItemDefinition definition

    The InventoryItemDefinition used to filter the items

    ICollection<InventoryItem> target

    The target collection where filtered items are copied

    Returns
    Type Description
    int

    The number of filtered items.

    FindItemsByDefinition(InventoryItemDefinition)

    Gets items filtered with the specified definition.

    Declaration
    public static InventoryItem[] FindItemsByDefinition(InventoryItemDefinition definition)
    Parameters
    Type Name Description
    InventoryItemDefinition definition

    The InventoryItemDefinition used to filter the items

    Returns
    Type Description
    InventoryItem[]

    The filtered items.

    FindItemsByDefinition(string, ICollection<InventoryItem>)

    Get all items created from the definition with the specified key.

    Declaration
    public static int FindItemsByDefinition(string key, ICollection<InventoryItem> target)
    Parameters
    Type Name Description
    string key

    The identifier of the InventoryItemDefinition used to filter the items

    ICollection<InventoryItem> target

    The target collection where filtered items are copied

    Returns
    Type Description
    int

    The number of filtered items.

    FindItemsByDefinition(string)

    Get all items created from the definition with the specified key.

    Declaration
    public static InventoryItem[] FindItemsByDefinition(string key)
    Parameters
    Type Name Description
    string key

    The identifier of the InventoryItemDefinition used to filter the items

    Returns
    Type Description
    InventoryItem[]

    The filtered items.

    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)