UnityTowerDefense/Assets/_Project/Scripts/Gameplay/BuffCategory.cs

23 lines
811 B
C#

// Assets/_Project/Scripts/Gameplay/BuffCategory.cs
using UnityEngine;
namespace TD.Gameplay
{
/// <summary>
/// A purchasable category of buffs. The player pays <see cref="Cost"/> gold
/// and receives a randomly chosen <see cref="BuffDefinition"/> from <see cref="Pool"/>.
/// </summary>
[CreateAssetMenu(fileName = "BuffCategory", menuName = "TD/Buffs/Buff Category")]
public class BuffCategory : ScriptableObject
{
[Tooltip("Name shown on the buff menu purchase button.")]
public string DisplayName;
[Tooltip("Gold cost to purchase one random buff from this category.")]
[Min(0)]
public int Cost;
[Tooltip("Set of buffs the player can receive. One is chosen uniformly at random.")]
public BuffDefinition[] Pool;
}
}