Exemple #1
0
 public void IncRound()
 {
     roundDone = false;
     roundNum++;
     roundTime   += 5;
     roundCounter = 0;
     predSpawner.UpdateRound(roundNum);
     foodSpawner.SetCurrRound(roundNum);
     roundText.text = "ROUND " + (roundNum + 1) + "/10";
     roundFlash.Flash();
 }
Exemple #2
0
    public void UnlockSkin(int skinIndex)
    {
        if (isRealMoney[skinIndex])
        {
        }
        else
        {
            if (mutationManager.GetExp() >= skinCosts[skinIndex])
            {
                mutationManager.AddExp(-1 * skinCosts[skinIndex]);
                PlayerPrefs.SetInt("Skin:" + skinIndex, 1);
                PlayerPrefs.Save();

                audioManager.PlaySound(5);
                skinBubbles[skinIndex].Play("Pop");
                skinCostTexts[skinIndex].text = "";

                ChangeSkin(skinIndex);
            }
            else
            {
                radCountFlash.Flash();
                radFoodFlash.SelfFlashWhite();
            }
        }
    }
Exemple #3
0
    public void AddCurrency(int add)
    {
        totalCurrency += add;

        PlayerPrefs.SetInt("Currency", totalCurrency);
        PlayerPrefs.Save();
        UpdateCurrencyText();
        currencyFlash.Flash();
    }
Exemple #4
0
 void UpdateText()
 {
     radCount.text = sessionExp + "";
     while (radCount.text.Length < 4)
     {
         radCount.text = "0" + radCount.text;
     }
     radFlash.Flash();
     radFoodFlash.SelfFlashWhite();
     if (mutationCanvas.activeSelf)
     {
         shopRadFlash.Flash();
         shopFoodFlash.SelfFlashWhite();
     }
     shopRadCount.text = currExp + "";
     while (shopRadCount.text.Length < 4)
     {
         shopRadCount.text = "0" + shopRadCount.text;
     }
 }