Пример #1
0
    public ItemStashData(ItemStash stash)
    {
        this.count    = stash.GetNumItems();
        this.capacity = stash.GetCapacity();

        this.itemData = new ItemData[capacity];
        for (int i = 0; i < capacity; i++)
        {
            Item item = stash.GetItem(i);
            if (item == null)
            {
                itemData[i] = null;
            }
            else
            {
                itemData[i] = new ItemData(item);
            }
        }
    }
Пример #2
0
 internal void OrderItemStashList()
 {
     ItemStash = ItemStash.OrderBy(x => x.GetType().Name).ThenByDescending(y => y.Level).ToList();
 }
Пример #3
0
 public void SetItem(Item item, ItemStash parent)
 {
     SetParentStash(parent);
     SetItem(item);
 }
Пример #4
0
 public void SetParentStash(ItemStash parent)
 {
     parentStash = parent;
 }