Exemplo n.º 1
0
    private void CreateNewItemListing(Food food)
    {
        GameObject  itemListingGO = Instantiate(itemListingPrefab, itemGrid.transform);
        ItemListing itemListing   = itemListingGO.GetComponent <ItemListing>();

        itemListing.ItemName.text  = food.Name;
        itemListing.ItemCount.text = "1";
        itemListing.ApplyIcon();
        itemList.Add(itemListing);
    }