Example #1
0
 /// <summary>
 /// When a letter is clicked, remove it object, pass it value to the game master and increment index
 /// </summary>
 private void OnMouseDown()
 {
     index = gM.index;
     string currentLetter = letters.transform.GetChild(0).GetComponent<TextMesh>().text;
     GameObject.Find(indexEmpty[index].ToString()).transform.GetChild(0).GetComponent<TextMesh>().text = currentLetter;
     gM.IncIndex();
     gM.AddCharToAnswer(currentLetter);
     Destroy(letters);
 }