using System; using Godot; namespace ColdMint.scripts.item; public readonly struct ItemType(string id, Func newItemFunc, Texture2D? icon, int maxStackQuantity) { /// /// Item id of this type /// public string Id { get; init; } = id; /// /// A function returns a new item instance of this type /// public Func NewItemFunc { get; init; } = newItemFunc; /// /// Default icon of items of this type /// public Texture2D? Icon { get; init; } = icon; /// /// Max number in item stack of this type /// public int MaxStackQuantity { get; init; } = maxStackQuantity; }