private void InvokeStackSizeChanged(GameInventory GameInventory)
        {
            Action <GameInventory> handler = StackSizeChanged;

            if (handler != null)
            {
                handler(GameInventory);
            }
        }
 private GameInventory(GameInventory other)
 {
     Type                    = other.Type;
     MaxStackSize            = other.MaxStackSize;
     BasePrice               = other.BasePrice;
     Category                = other.Category;
     StackSize               = other.StackSize;
     Locked                  = other.Locked;
     LocalizationName        = other.LocalizationName;
     LocalizationDescription = other.LocalizationDescription;
     claims                  = new List <InventoryClaim>();
 }
 private void ImportPrototypeSettings(int defaulMaxStackSize, float defaultBasePrice, string defaultCategory)
 {
     if (PrototypeManager.Inventory.Has(Type))
     {
         GameInventory prototype = PrototypeManager.Inventory.Get(Type);
         MaxStackSize            = prototype.MaxStackSize;
         BasePrice               = prototype.BasePrice;
         Category                = prototype.Category;
         LocalizationName        = prototype.LocalizationName;
         LocalizationDescription = prototype.LocalizationDescription;
     }
     else
     {
         MaxStackSize = defaulMaxStackSize;
         BasePrice    = defaultBasePrice;
         Category     = defaultCategory;
     }
 }
 public bool CanAccept(GameInventory inv)
 {
     return(inv.Type == Type && inv.StackSize + stackSize <= MaxStackSize);
 }