// This needs work private IEnumerator checkCardType() { yield return(new WaitForSeconds(.5f)); firstReveal.Unreveal(); firstReveal = null; secondReveal = null; allow = true; }
private IEnumerator checkIDs() { if (firstReveal.getId() == secondReveal.getId()) { int playThisOne = Random.Range(0, congratulations.Length); // randomize the sounds played each time playAudio.PlayOneShot(congratulations[playThisOne]); score++; Debug.Log("Score: " + score); if (score == userChoicePictures.Count) { Debug.Log("u win"); // } } else { yield return(new WaitForSeconds(.5f)); firstReveal.Unreveal(); secondReveal.Unreveal(); } firstReveal = null; secondReveal = null; }