Beispiel #1
0
 private void OnTriggerExit2D(Collider2D other)
 {
     if (other.gameObject.tag == "Player")
     {
         player.transform.position = reverse[ClosestSpawn].transform.position;
         cameraFollow.ResetCamera();
         m_health.pHealth = m_health.pHealth - fallDamage;
         //SoundManager.PlaySound("respawn_jiggle");
         //AudioSource.PlayClipAtPoint(SoundManager.respawnJiggle, new Vector3(player.transform.position.x,player.transform.position.y,player.transform.position.z));
         StartCoroutine(playerMovement.DamageFlash());
         StartCoroutine(FadeAfterTime(0.5f));
         //StartCoroutine(FadeBlack.GetComponent<FadeBlack>().ScreenFadeBlack(false));
     }
 }