Fix up item usage

This commit is contained in:
2025-03-07 18:40:14 -08:00
parent 93c04440d4
commit fe3c539a62
15 changed files with 125 additions and 65 deletions

View File

@@ -2,6 +2,7 @@
using Chickensoft.GodotNodeInterfaces;
using Chickensoft.Introspection;
using Godot;
using Zennysoft.Game.Abstractions;
namespace Zennysoft.Game.Ma;
@@ -23,12 +24,12 @@ public partial class DroppedItem : RigidBody3D, IDroppedItem
[Node] private Area3D Pickup { get; set; } = default!;
public InventoryItem Item { get; set; }
public IInventoryItem Item { get; set; }
public void OnResolved()
{
ContactMonitor = true;
Sprite.Texture = Item.ItemStats.Texture;
Sprite.Texture = ((InventoryItem)Item).ItemStats.Texture;
}
public async void Drop()