private IEnumerator ResetGame(bool reset) { m_started = false; iTween.MoveBy(m_showReelItems[m_currentPicture], new Vector3(Constants.SHOWREEL_ITEM_XOFFSET, 0, 0), Constants.SHOWREEL_MOVE_TIME); yield return(new WaitForSeconds(Constants.SHOWREEL_MOVE_TIME)); if (!reset) { m_currentPicture = 0; m_rowsManager.DestroyRows(); m_started = false; } if (Global.state == Global.State.ShowReel) { yield return(new WaitForSeconds(Constants.COVER_MOVE_TIME)); this.gameObject.transform.position = Vector3.zero; m_currentPicture = 0; // reset game. m_rowsManager.DestroyRows(); if (reset == true) { m_rowsManager.ReSet(); Global.state = Global.State.Playing; } else { Global.state = Global.State.Menu; } } if (reset) { if (Global.state == Global.State.ShowImg && Game.SuperMode != Game.Difficulty.Hard) { StartCoroutine(m_rowsManager.OntoNextRow()); Global.state = Global.State.Playing; } else if (Global.state == Global.State.ShowImg && Game.SuperMode == Game.Difficulty.Hard) { Global.state = Global.State.Timer; } } }