docs.unity.cn
    Show / Hide Table of Contents

    Class RewardConfig

    Configurator for a RewardDefinition instance.

    Inheritance
    Object
    CatalogItemConfig
    CatalogItemConfig<RewardDefinition>
    RewardConfig
    Inherited Members
    CatalogItemConfig<RewardDefinition>.CompileGeneric()
    CatalogItemConfig<RewardDefinition>.LinkGeneric(CatalogItem, Dictionary<String, CatalogItem>)
    CatalogItemConfig<RewardDefinition>.Compile()
    CatalogItemConfig<RewardDefinition>.Link(RewardDefinition, Dictionary<String, CatalogItem>)
    CatalogItemConfig<RewardDefinition>.DoRequireDisplayName()
    CatalogItemConfig.key
    CatalogItemConfig.displayName
    CatalogItemConfig.tags
    CatalogItemConfig.staticProperties
    Namespace: UnityEngine.GameFoundation.Configs
    Syntax
    public sealed class RewardConfig : CatalogItemConfig<RewardDefinition>, IBuildable<RewardDefinition>

    Fields

    cooldownSeconds

    The amount of time, in seconds, between when a RewardItem is claimed and when the next one will become available.

    Declaration
    public int cooldownSeconds
    Field Value
    Type Description
    Int32

    expirationSeconds

    The amount of time, in seconds, that a RewardItem will be claimable before either moving on to the next RewardItem, or resetting back to the first RewardItem.

    Declaration
    public int expirationSeconds
    Field Value
    Type Description
    Int32

    resetIfExpired

    If a RewardItem expires, this determines whether the next RewardItem will become available, or if the Reward is reset back to the first RewardItem.

    Declaration
    public bool resetIfExpired
    Field Value
    Type Description
    Boolean

    rewardItemConfigs

    The reward items to add to the resulting RewardDefinition.

    Declaration
    public readonly List<RewardItemConfig> rewardItemConfigs
    Field Value
    Type Description
    List<RewardItemConfig>

    Methods

    CompileItem(Rejectable)

    Create a new TRuntimeObject.

    Declaration
    protected override RewardDefinition CompileItem(Rejectable rejectable)
    Parameters
    Type Name Description
    Rejectable rejectable
    Returns
    Type Description
    RewardDefinition

    Return a promise handle to report how the operation went. The handle's result is the compiled item if the compilation was successful.

    Overrides
    UnityEngine.GameFoundation.Configs.CatalogItemConfig<UnityEngine.GameFoundation.RewardDefinition>.CompileItem(UnityEngine.Promise.Rejectable)

    LinkItem(RewardDefinition, Dictionary<String, CatalogItem>, Rejectable)

    Resolves the references from the given runtimeObject using the given compiledItems.

    Declaration
    protected override void LinkItem(RewardDefinition runtimeObject, Dictionary<string, CatalogItem> compiledItems, Rejectable rejectable)
    Parameters
    Type Name Description
    RewardDefinition runtimeObject
    Dictionary<String, CatalogItem> compiledItems
    Rejectable rejectable
    Overrides
    UnityEngine.GameFoundation.Configs.CatalogItemConfig<UnityEngine.GameFoundation.RewardDefinition>.LinkItem(UnityEngine.GameFoundation.RewardDefinition, System.Collections.Generic.Dictionary<System.String, UnityEngine.GameFoundation.CatalogItem>, UnityEngine.Promise.Rejectable)
    Back to top Copyright © 2020 Unity Technologies
    Generated by DocFX
    on 16 June 2021