docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method AdjustIntValue

    AdjustIntValue(GameItem, string, int)

    Adjusts specified Stat on specified gameItem by specified amount.

    Declaration
    public static int AdjustIntValue(GameItem gameItem, string statDefinitionId, int change)
    Parameters
    Type Name Description
    GameItem gameItem

    GameItem upon which Stat is to be adjusted.

    string statDefinitionId

    StatDefinition's Id to change.

    int change

    Adjustment (positive or negative) to Stat.

    Returns
    Type Description
    int

    The new value of Stat on GameItem.

    AdjustIntValue(GameItem, int, int)

    Adjusts specified Stat on specified gameItem by specified amount.

    Declaration
    public static int AdjustIntValue(GameItem gameItem, int statDefinitionHash, int change)
    Parameters
    Type Name Description
    GameItem gameItem

    GameItem upon which Stat is to be adjusted.

    int statDefinitionHash

    StatDefinition's Hash to change.

    int change

    Adjustment (positive or negative) to Stat.

    Returns
    Type Description
    int

    The new value of Stat on GameItem.

    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)