public void GameWon() { globalData.isGameOver = true; inGameScreen.gameObject.SetActive(false); gameWonScreen.gameObject.SetActive(true); StopCoroutine(O2CountDown()); if (globalData.rockScore > 0) //create text box that prints this { for (int i = 0; i < globalData.rockScore; i++) { int rockCount = i + 1; print("Calculating rocks collected: " + rockCount); } } print("You gathered " + globalData.rockScore + " rock(s) and had " + globalData.o2Percent * 100 + "% o2 left! " + "You now have $" + globalData.CalculateCashEarned() + " in cash!"); }