public IEnumerator StartWaitingCount(int inTotalCount) { _curWaitingCount = inTotalCount; while (_curWaitingCount > 0) { yield return(new WaitForSeconds(1.0f)); _curWaitingCount--; showWaitingDotsNext(); } if (_curWaitingCount <= 0) { Debug.Log("Change Scene to InGame"); _rivalProfile.setPlayerInfo("RIVAL!", 99, "THUMB"); //SceneManager.LoadScene("InGame"); } }
// Use this for initialization void Start() { _meProfile.setPlayerInfo("ME!", 1, "THUMB"); StartCoroutine(StartWaitingCount(15)); }