True BB moonleech check
This commit is contained in:
1 parent
0f5b03a498
commit
4cecd9e151
4 files changed
+15
-6
No files matched your search
@@ -625,8 +625,11 @@ namespace CalamityMod.DataStructures
|
||||
{
|
||||
if (Procced)
|
||||
{
|
||||
player.statLife += OmegaBiomeBlade.SuperPogoAttunement_PassiveLifeSteal;
|
||||
player.HealEffect(OmegaBiomeBlade.SuperPogoAttunement_PassiveLifeSteal);
|
||||
if (!player.moonLeech)
|
||||
{
|
||||
player.statLife += OmegaBiomeBlade.SuperPogoAttunement_PassiveLifeSteal;
|
||||
player.HealEffect(OmegaBiomeBlade.SuperPogoAttunement_PassiveLifeSteal);
|
||||
}
|
||||
|
||||
Procced = false;
|
||||
}
|
||||
|
||||
@@ -224,9 +224,6 @@ namespace CalamityMod.Projectiles.Melee
|
||||
//Since the iframes vary, adjust the damage to be consistent no matter the iframes. The true scaling happens between the BaseDamage and the FulLChargeDamage
|
||||
public override void ModifyHitNPC(NPC target, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
|
||||
{
|
||||
if (Owner.HeldItem.ModItem is OmegaBiomeBlade sword && Main.rand.NextFloat() <= OmegaBiomeBlade.SuperPogoAttunement_ShredderProc)
|
||||
sword.OnHitProc = true;
|
||||
|
||||
float deviationFromBaseDamage = damage / (float)OmegaBiomeBlade.SuperPogoAttunement_BaseDamage;
|
||||
float currentDamage = (int)(MathHelper.Lerp(OmegaBiomeBlade.SuperPogoAttunement_BaseDamage * deviationFromBaseDamage, OmegaBiomeBlade.SuperPogoAttunement_FullChargeDamage * deviationFromBaseDamage, ShredRatio));
|
||||
|
||||
@@ -256,6 +253,9 @@ namespace CalamityMod.Projectiles.Melee
|
||||
if (Main.myPlayer != Owner.whoAmI)
|
||||
return;
|
||||
|
||||
if (Owner.HeldItem.ModItem is OmegaBiomeBlade sword && Main.rand.NextFloat() <= OmegaBiomeBlade.SuperPogoAttunement_ShredderProc)
|
||||
sword.OnHitProc = true;
|
||||
|
||||
Owner.fallStart = (int)(Owner.position.Y / 16f);
|
||||
// get lifted up
|
||||
if (PogoCooldown <= 0)
|
||||
|
||||
@@ -42,7 +42,10 @@ namespace CalamityMod.Projectiles.Melee
|
||||
public override void ModifyHitNPC(NPC target, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
|
||||
{
|
||||
crit = true;
|
||||
}
|
||||
|
||||
public override void OnHitNPC(NPC target, int damage, float knockback, bool crit)
|
||||
{
|
||||
if (Owner.HeldItem.ModItem is OmegaBiomeBlade sword && Main.rand.NextFloat() <= OmegaBiomeBlade.SuperPogoAttunement_DashProc)
|
||||
sword.OnHitProc = true;
|
||||
|
||||
@@ -56,6 +59,9 @@ namespace CalamityMod.Projectiles.Melee
|
||||
GeneralParticleHandler.SpawnParticle(Spark);
|
||||
}
|
||||
|
||||
if (!target.canGhostHeal || Owner.moonLeech)
|
||||
return;
|
||||
|
||||
Owner.statLife += OmegaBiomeBlade.SuperPogoAttunementSlashLifesteal;
|
||||
Owner.HealEffect(OmegaBiomeBlade.SuperPogoAttunementSlashLifesteal);
|
||||
}
|
||||
|
||||
@@ -82,7 +82,7 @@ namespace CalamityMod.Projectiles.Melee
|
||||
|
||||
}
|
||||
|
||||
public override void ModifyHitNPC(NPC target, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
|
||||
public override void OnHitNPC(NPC target, int damage, float knockback, bool crit)
|
||||
{
|
||||
if (Owner.HeldItem.ModItem is OmegaBiomeBlade sword && Main.rand.NextFloat() <= OmegaBiomeBlade.SuperPogoAttunement_WheelProc)
|
||||
sword.OnHitProc = true;
|
||||
|
||||
Reference in new issue
Block a user