Example #1
0
    public void PromoteUnit()
    {
        int manaCost = Adventurer.GetPromoteCostForClass(setClass);

        if (GameDataManager.Instance.SpendManaIfPossible(manaCost))
        {
            adv.PromoteToTier2(setClass);
            shell.Close();
        }
        else
        {
            shell.SurrenderFocus();
            insufficientResourcesPopup.Open();
        }
    }