// Update is called once per frame void Update() { if (TimeAccumulation > WaitingTime) { Upgrades.CurrentScore = cg.getCoins(); Upgrades.CurrentHighScore = (Upgrades.CurrentHighScore < Upgrades.CurrentScore) ? Upgrades.CurrentScore : Upgrades.CurrentHighScore; SceneManager.LoadScene("scene_hub"); } if (cg) { if (cg.getCoins() > 0) { IsEnabled = true; } } }
// Update is called once per frame void Update() { __text.text = "COINS : " + __coinGrabber.getCoins().ToString(); }