Add stackable items
This commit is contained in:
@@ -320,8 +320,12 @@ public partial class Game : Node3D, IGame
|
||||
Player.HealVT(throwableItem.HealVTAmount);
|
||||
}
|
||||
|
||||
await ToSignal(GetTree().CreateTimer(1f), "timeout");
|
||||
GameRepo.RemoveItemFromInventory(item);
|
||||
await ToSignal(GetTree().CreateTimer(0.3f), "timeout");
|
||||
|
||||
if (item is IStackable stackableItem && stackableItem.Count > 1)
|
||||
stackableItem.SetCount(stackableItem.Count - 1);
|
||||
else
|
||||
GameRepo.RemoveItemFromInventory(item);
|
||||
}
|
||||
|
||||
public void DropItem(InventoryItem item)
|
||||
|
||||
Reference in New Issue
Block a user