public IEnumerator RespawnPlayer() { audioManager.PlaySound(spawnSoundName); yield return(new WaitForSeconds(spawnDelay)); Instantiate(playerPrefab, spawnPoint.position, spawnPoint.rotation); }