Exemplo n.º 1
0
 public ResourcesItem[] GetAllResourcesOfType(ResourcesManager.ResourcesType resourcesType)
 {
     ResourcesItem[] resourcesItemsOfType = resourcesItems.Where(a => a.GetResourcesType() == resourcesType).ToArray();
     resourcesItems = resourcesItems.Except <ResourcesItem>(resourcesItemsOfType.ToList()).ToList();
     isFull         = inventoryMaxCount <= resourcesItems.Count;
     if (isStorage)
     {
         ResourcesManager.instance.UpdateResourcesInfo();
     }
     return(resourcesItemsOfType);
 }
Exemplo n.º 2
0
 public int GetCountOfResourcesType(ResourcesManager.ResourcesType resourcesType)
 {
     return(resourcesItems.Where(a => a.GetResourcesType() == resourcesType).ToArray().Length);
 }