private void OnMouseDown() { audioSource.PlayOneShot(audioClip); TextControl.selectedAnswer = gameObject.name; TextControl.playerChoices.Add(choiceInt); // Debug.Log(TextControl.selectedAnswer); Debug.Log("The current question index is: " + TextControl.currentQuestionIndex); Debug.Log("The player's choice is " + TextControl.selectedAnswer); // Analytics.CustomEvent(idOfPlayer, new Dictionary<string, object> //{ // { "Index of the current Question: " + TextControl.currentQuestionIndex.ToString(), // "Player's Choice: " + TextControl.selectedAnswer} //}); if (TextControl.currentQuestionIndex < TextControl.numberOfQuestions - 1) { TextControl.currentQuestionIndex++; } else if (TextControl.currentQuestionIndex == TextControl.numberOfQuestions - 1) { tc.DoStuffWhenQuizEnds(); } }