Esempio n. 1
0
    public void TakeDamage(int amount)
    {
        if (!isServer)
        {
            return;
        }

        currentHealth -= amount;
        if (currentHealth <= 0)
        {
            currentHealth = 100;
            RpcRespawn();
            Debug.Log("Dead!");

            UIScore.AddScore(GetComponent <PlayerController>().playerID);
        }
    }
Esempio n. 2
0
 private void AddOneScore()
 {
     showScore.AddScore();
 }