// Recreate the Scene Environment for the next question private IEnumerator ResetLevel(float waitTime, nextLevelDecision dec) // Time to delay is based on the Olly animation time { soundManager.stopAudioList(); PG_SoundManager.playIntroClip = false; enableTouchesFlag = false; yield return(new WaitForSeconds(waitTime)); removeAllPlatforms(); removeAllLandmasses(); this.StopAllCoroutines(); removeALLIslands(); removeAllShapes(); if (dec == nextLevelDecision.loadQuestion) { loadQuestion(); } else if (dec == nextLevelDecision.loadLevel) { loadLevel(); } }
// Time to delay is based on the Olly animation time // Recreate the Scene Environment for the next question private IEnumerator ResetLevel(float waitTime,nextLevelDecision dec) { soundManager.stopAudioList(); PG_SoundManager.playIntroClip =false; enableTouchesFlag = false; yield return new WaitForSeconds(waitTime); removeAllPlatforms(); removeAllLandmasses(); this.StopAllCoroutines(); removeALLIslands(); removeAllShapes(); if(dec==nextLevelDecision.loadQuestion) loadQuestion(); else if(dec==nextLevelDecision.loadLevel) loadLevel(); }