// Step Way 2 private IEnumerator DelayedGenerateBiomesRooms() { for (int i = 0; i < myBiomes.Length; i++) { DEBUGCANVAS.SelectMap(myBiomes[i].myX, myBiomes[i].myY); myBiomes[i].GenerateRooms(); } FindBiomesExtremeRooms(); LinkBiomesWithRooms(); for (int i = 0; i < myBiomes.Length; i++) { myBiomes[i].InstantiateRoom(); while (!myBiomes[i].myGenerationDone) { yield return(null); } } yield return(new WaitForSeconds(1)); DEBUGCANVAS.gameObject.SetActive(false); SpawnPlayer(); }