Aquatic Scourge global piercing resist

This commit is contained in:
Ozzatron committed 2019-07-28 17:23:26 -04:00
1 parent bf93848e19
commit ae3bee6b9f
4 files changed
+53 -36

No files matched your search

+10 -6
View File
@@ -24,7 +24,7 @@ namespace CalamityMod.NPCs.AbyssNPCs
npc.damage = 100; //70
npc.width = 32; //36
npc.height = 32;
npc.defense = 60;
npc.defense = 35;
npc.aiStyle = -1; //new
aiType = -1; //new
npc.knockBackResist = 0f;
@@ -337,11 +337,15 @@ namespace CalamityMod.NPCs.AbyssNPCs
public override void ModifyHitByProjectile(Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
{
if ((projectile.type == ProjectileID.HallowStar || projectile.type == ProjectileID.CrystalShard) && projectile.ranged)
{
damage /= 2;
}
}
if (projectile.penetrate == -1 && !projectile.minion)
{
damage = (int)((double)damage * 0.2);
}
else if (projectile.penetrate > 1)
{
damage /= projectile.penetrate;
}
}
public override bool? CanBeHitByProjectile(Projectile projectile)
{
+16 -12
View File
@@ -1,10 +1,10 @@
using System;
using System.IO;
using CalamityMod.World;
using Microsoft.Xna.Framework;
using System;
using System.IO;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using CalamityMod.World;
namespace CalamityMod.NPCs.AbyssNPCs
{
@@ -24,7 +24,7 @@ namespace CalamityMod.NPCs.AbyssNPCs
npc.damage = 100; //70
npc.width = 32; //36
npc.height = 32;
npc.defense = 60;
npc.defense = 25;
npc.aiStyle = -1; //new
aiType = -1; //new
npc.knockBackResist = 0f;
@@ -333,15 +333,19 @@ namespace CalamityMod.NPCs.AbyssNPCs
}
}
public override void ModifyHitByProjectile(Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
{
if ((projectile.type == ProjectileID.HallowStar || projectile.type == ProjectileID.CrystalShard) && projectile.ranged)
{
damage /= 2;
}
}
public override void ModifyHitByProjectile(Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
{
if (projectile.penetrate == -1 && !projectile.minion)
{
damage = (int)((double)damage * 0.2);
}
else if (projectile.penetrate > 1)
{
damage /= projectile.penetrate;
}
}
public override bool? CanBeHitByProjectile(Projectile projectile)
public override bool? CanBeHitByProjectile(Projectile projectile)
{
if (projectile.minion)
{
+14 -9
View File
@@ -30,7 +30,7 @@ namespace CalamityMod.NPCs.AbyssNPCs
npc.damage = 100;
npc.width = 100; //36
npc.height = 90; //20
npc.defense = 40;
npc.defense = 20;
npc.aiStyle = -1;
aiType = -1;
npc.lifeMax = CalamityWorld.revenge ? 85000 : 73000;
@@ -545,15 +545,19 @@ namespace CalamityMod.NPCs.AbyssNPCs
}
}
public override void ModifyHitByProjectile(Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
{
if ((projectile.type == ProjectileID.HallowStar || projectile.type == ProjectileID.CrystalShard) && projectile.ranged)
{
damage /= 2;
}
}
public override void ModifyHitByProjectile(Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
{
if (projectile.penetrate == -1 && !projectile.minion)
{
damage = (int)((double)damage * 0.2);
}
else if (projectile.penetrate > 1)
{
damage /= projectile.penetrate;
}
}
public override bool? CanBeHitByProjectile(Projectile projectile)
public override bool? CanBeHitByProjectile(Projectile projectile)
{
if (projectile.minion)
{
@@ -586,6 +590,7 @@ namespace CalamityMod.NPCs.AbyssNPCs
int closestSegmentID = DropHelper.FindClosestWormSegment(npc,
mod.NPCType("AquaticScourgeHead"),
mod.NPCType("AquaticScourgeBody"),
mod.NPCType("AquaticScourgeBodyAlt"),
mod.NPCType("AquaticScourgeTail"));
npc.position = Main.npc[closestSegmentID].position;
return false;
+13 -9
View File
@@ -23,7 +23,7 @@ namespace CalamityMod.NPCs.AbyssNPCs
npc.damage = 100; //70
npc.width = 30; //28
npc.height = 50; //28
npc.defense = 90;
npc.defense = 45;
npc.aiStyle = -1; //new
aiType = -1; //new
npc.knockBackResist = 0f;
@@ -304,15 +304,19 @@ namespace CalamityMod.NPCs.AbyssNPCs
}
}
public override void ModifyHitByProjectile(Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
{
if ((projectile.type == ProjectileID.HallowStar || projectile.type == ProjectileID.CrystalShard) && projectile.ranged)
{
damage /= 2;
}
}
public override void ModifyHitByProjectile(Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
{
if (projectile.penetrate == -1 && !projectile.minion)
{
damage = (int)((double)damage * 0.2);
}
else if (projectile.penetrate > 1)
{
damage /= projectile.penetrate;
}
}
public override bool? CanBeHitByProjectile(Projectile projectile)
public override bool? CanBeHitByProjectile(Projectile projectile)
{
if (projectile.minion)
{