Exemple #1
0
 private void OnMouseOver()
 {
     if (Input.GetMouseButton(0) && isPlaceable)
     {
         towerFactory.AddTower(this);
     }
 }
Exemple #2
0
 private void OnMouseDown()
 {
     if (isPlaceable)
     {
         towerFactory.AddTower(this);
     }
     else
     {
         print("Can't place here!");
     }
 }
Exemple #3
0
 private void HandPlayerNewTower()
 {
     if (isCarrying)
     {
         print("You can only carry one tower at a time");
     }
     else
     {
         towerFactory.AddTower();
     }
 }
Exemple #4
0
 void OnMouseDown()
 {
     if (isPlaceable)
     {
         towerFactory.AddTower(this);
     }
     else
     {
         return;
     }
 }
 private void OnMouseOver()
 {
     if (Input.GetMouseButtonDown(0))
     {
         if (!isOccupied)
         {
             factory.AddTower(this);
         }
         else
         {
             Debug.Log("Max tower limit reaced!");
         }
     }
 }
Exemple #6
0
 private void OnMouseOver()
 {
     if (Input.GetMouseButtonDown(0))
     {
         if (isPlaceable)
         {
             towerFactory.AddTower(this);
         }
         else
         {
             print("Can't touch this.");
         }
     }
 }
Exemple #7
0
 public void TowerOne()
 {
     towerFactory = new TowerFactory();
     towerFactory.AddTower(towerOne);
 }