public void OnPointerEnter(PointerEventData eventData)
 {
     tower = GameManager.instance.targetTower;
     if (tower != null)
     {
         ShowTooltip();
     }
 }
示例#2
0
 public void SetTowerStatus()
 {
     tower            = GameManager.instance.targetTower;
     towerName.text   = tower.towerName;
     image.sprite     = tower.GetComponent <SpriteRenderer>().sprite;
     resellCost.text  = (tower.price / 2).ToString();
     upgradeCost.text = tower.upgradeCost.ToString();
     upgrade.text     = "Upgrade : " + tower.upgradePhase;
     attackPower.text = "Power : " + tower.GetComponent <TowerCtrl>().power;
     killCount.text   = "Kill Count : " + tower.killCount;
     mode.text        = tower.mode.ToString();
     skill1.sprite    = tower.skill1Sprite;
     skill2.sprite    = tower.skill2Sprite;
     cooldown1.sprite = tower.skill1Sprite;
     cooldown2.sprite = tower.skill2Sprite;
     InitCooldown(cooldown1);
     InitCooldown(cooldown2);
     cooldown1.fillAmount = tower.GetCooltime(1);
     cooldown2.fillAmount = tower.GetCooltime(2);
 }