public void setChallenge(GenericChallenge challenge)
 {
     this.challenge = challenge;
     challenge.setChallengePauseDisplay(this);
     setGoal(challenge.getGoal());
     setReward(challenge.getBoosterRewards());
 }
예제 #2
0
 public void setChallenge(GenericChallenge challenge)
 {
     this.challenge = challenge;
     challenge.setChallengePauseDisplay(this);
     setGoal(challenge.getGoal());
     setReward(challenge.getBoosterRewards());
 }
예제 #3
0
 public void setChallenge(GenericChallenge challenge)
 {
     this.challenge = challenge;
     if (challenge == null)
     {
         StopCoroutine(timerCoroutine);
         timerCoroutine = timer();
         goal.text      = "NO ACTIVE CHALLENGE";
         progress.text  = "";
         reward.gameObject.SetActive(false);
     }
     else
     {
         GameManager.changeGameState(false);
         goal.text = challenge.getGoal();
         int b = (int)challenge.getBoosterRewards();
         reward.sprite = Resources.LoadAll <Sprite>("GUI/Boosters/Booster_" + b)[0];
         reward.gameObject.SetActive(true);
         StartCoroutine(timerCoroutine);
     }
 }
    public void setChallenge(GenericChallenge challenge)
    {
        this.challenge = challenge;
        if (challenge == null)
        {
            StopCoroutine(timerCoroutine);
            timerCoroutine = timer();
            goal.text = "NO ACTIVE CHALLENGE";
            progress.text = "";
            reward.gameObject.SetActive(false);

        }
        else
        {
            GameManager.changeGameState(false);
            goal.text = challenge.getGoal();
            int b = (int)challenge.getBoosterRewards();
            reward.sprite = Resources.LoadAll<Sprite>("GUI/Boosters/Booster_" + b)[0];
            reward.gameObject.SetActive(true);
            StartCoroutine(timerCoroutine);
        }
    }