Пример #1
0
        public override void UpdateLifeRegen(NPC npc, ref int damage)
        {
            if (!SomeUtils.HasBleeding(npc))
            {
                Bleed = 0;
            }

            if (Bleed > 0)
            {
                if (npc.lifeRegen > 0)
                {
                    npc.lifeRegen = 0;
                }
                npc.lifeRegen -= Bleed * TwilightData.BleedingDamage;
                if (damage < Bleed * TwilightData.BleedingDamage / 4)
                {
                    damage = Bleed * TwilightData.BleedingDamage / 4;
                }
                if (Main.rand.Next(15) == 1)
                {
                    Bleed--;
                }
            }
        }