using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; public class QuestOptionControl : MonoBehaviour { bool isRight = false; GameObject border; public int answersID; private void Start() { GameObject obj = transform.GetChild(1).gameObject; border = obj; obj.SetActive(false); } public void SetRightQuestion(bool teacher) { isRight = true; if (teacher) { Text txt = GetComponentInChildren(); txt.color = new Color(0, .75f, 0, 1); StartCoroutine(AnswerWait()); } } IEnumerator AnswerWait() { yield return new WaitForFixedUpdate(); Answer(true); yield break; } public void SetInfoNoImage(string question, int answerid) { Text txt = GetComponentInChildren(); txt.text = question; answersID = answerid; } public void SetColor(Color color, bool teacher) { if (teacher) { Image img = GetComponent(); img.color = new Color(0, 0, 0, 0); Text txt = GetComponentInChildren(); txt.color = new Color(0, 0, 0, 1); Button btn = GetComponent