// Update is called once per frame void Update() { // Update Progression bar m_progressionSlider.value = m_levelDesigner.GetProgression(); // Update Combo m_comboText.text = "X" + m_levelDesigner.GetCombo(); // Update Score m_scoreText.text = "Score : " + m_levelDesigner.GetScore(); }
private void OnCollisionEnter(Collision collision) { if (m_levelDesigner.GetCombo() > 3) { Destroy(collision.collider.gameObject); } else if (collision.collider.gameObject.tag == "Trap") { Lose(); } else if (collision.collider.gameObject.tag == "Arrival") { Win(); } m_levelDesigner.ResetCombo(); }