Search Unity

How do I track score on collision

Discussion in 'Unity UI & TextMesh Pro' started by unity_Zyyu3r55v1L9ag, Nov 5, 2018.

  1. unity_Zyyu3r55v1L9ag

    unity_Zyyu3r55v1L9ag

    Joined:
    Nov 5, 2018
    Posts:
    3
    Hello,
    I am a bit of a beginner on coding in c# but I was wondering if anyone could help me with keeping score with text but on collision, like the game Beat Saber.

    Thanks,
     
  2. leftshoe18

    leftshoe18

    Joined:
    Jul 29, 2017
    Posts:
    34
    Have some sort of score manager. When any action occurs that you want to give the player points (in your case a collision event of some sort) make a call to the score manager to add to the player's score and then update your text object to reflect the new score.