public void AddScore(int scorePoints, int addTime) { timeLeft += addTime; score += scorePoints; scoreText.text = score.ToString(); onScoreChangedEvent.Invoke(score); }
private void RaiseScoreChangedEvent(int score) { ScoreChangedEvent?.Invoke(score); }
public void IncreaseScore(int points) { score += points; OnScoreChange.Invoke(score); }
void Update() { distance = player.transform.position.x - startX; onScoreChanged.Invoke(distance); }
public void AddScore(int value) { _score += value; ScoreChangedEvent?.Invoke(_score); }