Example #1
0
    void Buy(ShopItem item, int cost)
    {
        if (!item.Owned)
        {
            item.Buy();
            player.AddCurrency(-cost);
        }

        GenerateItems();
        GenerateButtons();
        gm.Save();
    }