Beispiel #1
0
 public void DestroyPlayer(bool isMario)
 {
     alive             = false;
     GameState.isAlive = false;
     if (!GameState.isLearning)
     {
         GameManager.Instance.Kill();
     }
     else
     {
         InGameGUI.Instance.DieInLearning(isMario);
     }
     powerUp.DeactivateAll();
     Instantiate(destroyedVersion.gameObject, _RBTransform.position, _RBTransform.rotation, transform.parent).GetComponent <ParticleSystem>().Play();
     AudioCenter.Instance.PlaySound("DestroyPlayer");
     ShakeManager.ShakeAfterDeath();
     StopCoroutine("ControllSpeed");
     gameObject.SetActive(false);
 }