Example #1
0
    public void Damage(int damage)
    {
        if (UnityEngine.Random.value > (Evasion + Dexterity.Value) / 40)
        {
            var dam = damage - (Block + Stamina.Value + Armor);

            if (dam < 0)
            {
                dam = 0;
            }
            HP.DecreaseQuanity(dam);
        }
    }