From f0a84548bc6237a5c1d711a781afa0e2a67c8559 Mon Sep 17 00:00:00 2001 From: IbanPlay <56191483+IbanPlay@users.noreply.github.com> Date: Thu, 20 Jan 2022 21:15:48 +0100 Subject: [PATCH] Lifesteal passive --- Items/Weapons/Melee/OmegaBiomeBlade.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Items/Weapons/Melee/OmegaBiomeBlade.cs b/Items/Weapons/Melee/OmegaBiomeBlade.cs index dac5b2194b..70ca04edd6 100644 --- a/Items/Weapons/Melee/OmegaBiomeBlade.cs +++ b/Items/Weapons/Melee/OmegaBiomeBlade.cs @@ -49,6 +49,7 @@ namespace CalamityMod.Items.Weapons.Melee public static int SuperPogoAttunement_SlashIFrames = 60; public static float SuperPogoAttunement_ShotDamageBoost = 2f; + public static float SuperPogoAttunement_PassiveLifeStealChance = 0.2f; public static int SuperPogoAttunement_PassiveLifeSteal = 10; @@ -390,8 +391,11 @@ namespace CalamityMod.Items.Weapons.Melee case Attunement.SuperPogo: if (OnHitProc) { - player.statLife += SuperPogoAttunement_PassiveLifeSteal; - player.HealEffect(SuperPogoAttunement_PassiveLifeSteal); + if (Main.rand.Next() <= SuperPogoAttunement_PassiveLifeStealChance) + { + player.statLife += SuperPogoAttunement_PassiveLifeSteal; + player.HealEffect(SuperPogoAttunement_PassiveLifeSteal); + } OnHitProc = false; } break;