// Update is called once per frame void Update() { if (deliveries.DeliveriesLeft() == 0) { LevelCleared(); } else if (inkLevel.getInkLevel() < 0) { GameOver(); } else if (Input.GetButtonDown("Cancel") && !gameOver) { if (paused) { Resume(); } else { Pause(); } } // otherwise just go on }
// Start is called before the first frame update void Start() { txt = gameObject.GetComponent <Text>(); txt.text = "DELIVERIES: " + deliveries.DeliveriesLeft() + "/" + deliveries.TotalDeliveries(); }