mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-06 21:25:42 +12:00
36 lines
786 B
C#
Executable file
36 lines
786 B
C#
Executable file
using System;
|
|
using System.Collections.Generic;
|
|
using HISP.Game.Items;
|
|
|
|
namespace HISP.Game.Inventory
|
|
{
|
|
public class InventoryItem
|
|
{
|
|
public InventoryItem()
|
|
{
|
|
itemInstances = new List<ItemInstance>();
|
|
Infinite = false;
|
|
ItemId = 0;
|
|
}
|
|
|
|
public int ItemId;
|
|
public bool Infinite;
|
|
private List<ItemInstance> itemInstances;
|
|
public void RemoveItem(ItemInstance itm)
|
|
{
|
|
itemInstances.Remove(itm);
|
|
}
|
|
public void AddItem(ItemInstance itm)
|
|
{
|
|
itemInstances.Add(itm);
|
|
}
|
|
public ItemInstance[] ItemInstances
|
|
{
|
|
get
|
|
{
|
|
return itemInstances.ToArray();
|
|
}
|
|
}
|
|
}
|
|
|
|
}
|