Exemplo n.º 1
0
 /// <summary>
 /// Set currently selected tower and activate hovering effect for this tower.
 /// </summary>
 /// <param name="towerBtn">TowerBtn to select.</param>
 public static void SelectTowerAndHover(TowerBtn towerBtn)
 {
     Hover.Activate(towerBtn.TowerPrefab.GetComponent <Tower>().Range, towerBtn.TowerHoverSprite);
     GameManager.SelectedTower = towerBtn.TowerPrefab.GetComponent <Tower>();
     GameManager.rangeIndicatorRenderer.transform.localScale = new Vector3(SelectedTower.Range * .66f, SelectedTower.Range * .66f, 1);
     GameManager.rangeIndicatorRenderer.transform.position   = SelectedTower.transform.position;
     GameManager.rangeIndicatorRenderer.enabled = true;
 }