コード例 #1
0
 private void OnCollisionEnter(Collision collision)
 {
     if (collision.gameObject.name.Contains("SquareTarget"))
     {
         ScoreBehavior.UpdateScore(1);
     }
     else if (collision.gameObject.name == "right")
     {
         UISelection.OnRightSelected();
     }
     else if (collision.gameObject.name == "left")
     {
         UISelection.OnLeftSelected();
     }
     else
     {
         HealthBehavior.UpdateHealth();
     }
 }