Ejemplo n.º 1
0
    void GetStarReward(GameObject healthParent)
    {
        //if we've destroyed an attacker, we want some stars
        if (healthParent.GetComponent <Attacker> ())
        {
            starDisplay.AddStars(20);
        }
        //if we're on easy difficulty, we want more stars when a defender is destroyed too
        int difficulty = Mathf.RoundToInt(PlayerPrefsManager.GetDifficulty());

        if (difficulty == 1 && healthParent.GetComponent <Defender> ())
        {
            starDisplay.AddStars(50);
        }
    }
Ejemplo n.º 2
0
 public void AddStars(int amount)
 {
     if (starDisplay)
     {
         starDisplay.AddStars(amount);
     }
 }
 private void TrySpawnDefender(Vector2 gridPos)
 {
     if (starDisplay.HaveEnoughStars(defender.GetStarCost()))
     {
         SpawnDefender(gridPos);
         starDisplay.AddStars(-defender.GetStarCost());
     }
 }
Ejemplo n.º 4
0
    private void UpdateCurrency()
    {
        var attacker = GetComponent <Attacker>();

        if (attacker)
        {
            _starDisplay.AddStars(attacker.StarReward);
        }
    }
Ejemplo n.º 5
0
    private IEnumerator AddStars()
    {
        do
        {
            yield return(new WaitForSeconds(Random.Range(mintime, maxtime)));

            starDisplay.AddStars(stars);
            PlayVFX();
        }while (looping);
    }
Ejemplo n.º 6
0
    public void AddStars(int amountToAdd)
    {
        StarDisplay temp = FindObjectOfType <StarDisplay>();

        if (temp != null)
        {
            Debug.Log("Adding Stars");
            temp.AddStars(amountToAdd);
        }
    }
Ejemplo n.º 7
0
 public void AddStars(int amount)
 {
     display.AddStars(amount);
 }
Ejemplo n.º 8
0
 void addSomeStars(int stars)
 {
     starDisplay.AddStars(stars);
 }
Ejemplo n.º 9
0
 public void AddStars(int amount)
 {
     _starDisplay.AddStars(amount);
 }
Ejemplo n.º 10
0
 public void AddStar()
 {
     _starDisplay.AddStars(baseStarsToAdd - PlayerPrefsController.GetDifficulty());
 }
Ejemplo n.º 11
0
 public void AddStars(int amount)
 {
     print(amount);
     StarDisplay.AddStars(amount);
 }
Ejemplo n.º 12
0
 public void AddStars()
 {
     starDisplay.AddStars(starAmount);
     Instantiate(starPrefab, starSpawnPoint);
 }
Ejemplo n.º 13
0
 public void AddStars()
 {
     starDisplay.AddStars();
 }
Ejemplo n.º 14
0
 //This method is tied to the animation of the star creation and passes in the int 10 for value of a star
 public void AddStars(int amount)
 {
     //This calls the starDisplay script method and passes the 10 int from animation variable
     starDisplay.AddStars(amount);
 }
Ejemplo n.º 15
0
 void AddStars(int amount)
 {
     //Debug.Log (amount + "stars added");
     starDisplay.AddStars(amount);
 }
Ejemplo n.º 16
0
 public void AddStars(int amount)
 {
     starDisplay.AddStars(10);
 }
Ejemplo n.º 17
0
 void AddStars(int starsCount)
 {
     starDisplay.AddStars(starsCount);
 }
Ejemplo n.º 18
0
    public void AddStars(int amount)
    {
        StarDisplay starDisplay = FindObjectOfType <StarDisplay>();

        starDisplay.AddStars(amount);
    }
Ejemplo n.º 19
0
 public void AddStars(int stars)
 {
     starDisplay.AddStars(stars);
     //Debug.Log(stars);
 }
Ejemplo n.º 20
0
 public void AddStars(int numStars)
 {
     starDisplay.AddStars(numStars);
 }
Ejemplo n.º 21
0
 public void MakeStars(int stars)
 {
     starDisplay.AddStars(stars);
 }
Ejemplo n.º 22
0
 public void AddStars(int amount)
 {
     starDisp.AddStars(amount);
 }
Ejemplo n.º 23
0
 public void AddStars(int number)
 {
     starDisplay.AddStars(number);
 }
Ejemplo n.º 24
0
 void OnMouseDown()
 {
     starDisplay.AddStars(value);
     animator.SetTrigger("Picked");
 }
Ejemplo n.º 25
0
 void AddStars(int amount)
 {
     starDisplay.AddStars(amount);
 }
Ejemplo n.º 26
0
 //Just a tag
 public void AddStarts(int amount)
 {
     Debug.Log("Opa, add estrelas!");
     starDisplay.AddStars(amount);
 }
 private void AddStars(int amount)
 {
     _starDisplay.AddStars(amount);
 }
Ejemplo n.º 28
0
 //this method called from the animation
 public void AddStars(int amount)
 {  //then pass the value to text diaplay thru StarDisplay.cs AddStars method
     starDisplay.AddStars(amount);
 }
Ejemplo n.º 29
0
 public void AddStars(int amount)
 {
     //Star Amount in the Star Fire Animation Currently Set to 10
     starDisplay.AddStars(amount);
 }
Ejemplo n.º 30
0
 public void AddStars(int amount)
 {
     starDisplay.AddStars(amount);
     //print (amount + " stars added");
 }