示例#1
0
 private void OnCollisionEnter(Collision collision)
 {
     Debug.Log("Collided with:" + collision.collider.name);
     GroundController.Die();
     isAlive = false;
     SoundController.PlayDieSound();
     replayButton.SetActive(true);
     instance.gameState = GameState.death;
     if (points > highScore)
     {
         highScore = points;
         highSoreText.GetComponent <Text>().text = "Highscore: " + highScore;
     }
 }