diff options
| author | alex <[email protected]> | 2026-11-23 12:00:20 +0100 |
|---|---|---|
| committer | alex <[email protected]> | 2026-11-23 12:00:20 +0100 |
| commit | 7f4bd1856869d7ae10fa8f07708fbd75c5bb7b1e (patch) | |
| tree | e1fa2d87a79bc8bae87da9e62b19521fe27643e5 /scripts/items/ItemDefinition.cs | |
| parent | 45326f4f10ba2af92ff5d35f0f63e1dc35a4f8eb (diff) | |
| download | godot-testing-7f4bd1856869d7ae10fa8f07708fbd75c5bb7b1e.tar.xz godot-testing-7f4bd1856869d7ae10fa8f07708fbd75c5bb7b1e.zip | |
pesitems
Diffstat (limited to 'scripts/items/ItemDefinition.cs')
| -rw-r--r-- | scripts/items/ItemDefinition.cs | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/scripts/items/ItemDefinition.cs b/scripts/items/ItemDefinition.cs new file mode 100644 index 0000000..394cd2d --- /dev/null +++ b/scripts/items/ItemDefinition.cs @@ -0,0 +1,22 @@ +using Godot; +using Godot.Collections; + +[GlobalClass] +public partial class ItemDefinition : Resource +{ + public enum ItemType + { + Passive, + Weapon + } + + [Export] public string Id { get; set; } = "item_id"; + [Export] public string DisplayName { get; set; } = "New Item"; + [Export(PropertyHint.MultilineText)] public string Description { get; set; } = string.Empty; + [Export] public Texture2D? Icon { get; set; } + [Export] public ItemType Type { get; set; } = ItemType.Passive; + + [Export] public PackedScene? WeaponScene { get; set; } + [Export] public Array<StatModifierResource> StatModifiers { get; set; } = new(); + [Export] public Array<EffectModifierResource> EffectModifiers { get; set; } = new(); +} |
