Ejemplo n.º 1
0
 public void NotifyBtnClicked(ButtonShopTurret btn, GameObject turretToBuild)
 {
     buildManager.SetTurretToBuild(turretToBuild);
     if (lastBtn != null)
     {
         lastBtn.ResetColor();
     }
     lastBtn = btn;
 }
Ejemplo n.º 2
0
 private void InitShop()
 {
     foreach (GameObject turretGO in listTurretPrefab)
     {
         GameObject       btnGO  = Instantiate(buttonShopTurretPrefab, transform);
         ButtonShopTurret button = btnGO.GetComponent <ButtonShopTurret>();
         button.InitWith(turretGO, this);
         listBtn.Add(button);
     }
 }