示例#1
0
 public void Upgrade()
 {
     tower.Upgrade();
     if (tower.IsMaxLevel())
     {
         upgradeButton.interactable = false;
     }
     ShowStats();
 }
示例#2
0
    public void Activate(BaseTower tower)
    {
        this.tower = tower;
        canvas.transform.position = tower.transform.position + tower.transform.rotation * new Vector3(0, 0.5f, 0);

        ShowStats();

        if (tower.IsMaxLevel())
        {
            upgradeButton.interactable = false;
        }
        else
        {
            upgradeButton.interactable = true;
        }

        canvas.gameObject.SetActive(true);
    }