1 - Profaned Guardian adjustments.

This commit is contained in:
mountaindrew10 committed 2022-03-26 00:12:50 -05:00
1 parent 0d5a4135b7
commit fcd37f786c
5 files changed
+53 -39

No files matched your search

+37 -13
View File
@@ -118,9 +118,17 @@ namespace CalamityMod.NPCs.ProfanedGuardians
// Defense
if (defenderAlive)
npc.defense = npc.defDefense * 4;
{
npc.Calamity().DR = 0.9f;
npc.Calamity().unbreakableDR = true;
npc.Calamity().CurrentlyIncreasingDefenseOrDR = true;
}
else
npc.defense = npc.defDefense;
{
npc.Calamity().DR = 0.3f;
npc.Calamity().unbreakableDR = false;
npc.Calamity().CurrentlyIncreasingDefenseOrDR = false;
}
// Healing
if (healerAlive)
@@ -209,9 +217,9 @@ namespace CalamityMod.NPCs.ProfanedGuardians
float inertia = (malice || biomeEnraged) ? 45f : death ? 50f : revenge ? 52f : expertMode ? 55f : 60f;
if (lifeRatio < 0.5f)
inertia *= 0.9f;
inertia *= 0.8f;
if (!phase1)
inertia *= 0.9f;
inertia *= 0.8f;
float num1006 = 0.111111117f * inertia;
@@ -224,10 +232,10 @@ namespace CalamityMod.NPCs.ProfanedGuardians
npc.spriteDirection = npc.direction;
}
float velocity = (malice || biomeEnraged) ? 18f : death ? 16f : revenge ? 15f : expertMode ? 14f : 12f;
float velocity = (malice || biomeEnraged) ? 20f : death ? 18f : revenge ? 17f : expertMode ? 16f : 14f;
Vector2 targetVector = player.Center - vectorCenter;
targetVector = Vector2.Normalize(targetVector) * velocity;
float phaseGateValue = (malice || biomeEnraged) ? 120f : death ? 160f : revenge ? 180f : expertMode ? 200f : 240f;
float phaseGateValue = (malice || biomeEnraged) ? 60f : death ? 80f : revenge ? 90f : expertMode ? 100f : 120f;
if (defenderAlive)
phaseGateValue *= 1.25f;
@@ -247,7 +255,23 @@ namespace CalamityMod.NPCs.ProfanedGuardians
Main.PlaySound(SoundID.Item20, npc.position);
int type = ModContent.ProjectileType<FlareDust>();
int damage = npc.GetProjectileDamage(type);
Projectile.NewProjectile(vectorCenter, Vector2.Normalize(player.Center - vectorCenter) * npc.velocity.Length() * 1.5f, type, damage, 0f, Main.myPlayer, 2f, 0f);
Vector2 projectileVelocity = Vector2.Normalize(player.Center - vectorCenter);
int numProj = death ? 3 : 2;
int spread = death ? 30 : 20;
if (!phase1)
{
numProj *= 2;
spread *= 2;
}
float rotation = MathHelper.ToRadians(spread);
for (int i = 0; i < numProj; i++)
{
Vector2 perturbedSpeed = projectileVelocity.RotatedBy(MathHelper.Lerp(-rotation, rotation, i / (float)(numProj - 1)));
Vector2 normalizedPerturbedSpeed = Vector2.Normalize(perturbedSpeed);
Projectile.NewProjectile(vectorCenter, normalizedPerturbedSpeed * npc.velocity.Length() * 1.25f, type, damage, 0f, Main.myPlayer, 2f, 0f);
}
}
}
}
@@ -300,8 +324,8 @@ namespace CalamityMod.NPCs.ProfanedGuardians
Main.PlaySound(SoundID.Item20, npc.position);
int totalProjectiles = 10;
float velocity = 5f;
int totalProjectiles = phase1 ? 6 : 10;
float velocity = phase1 ? 5f : 6f;
int type = ModContent.ProjectileType<ProfanedSpear>();
int damage = npc.GetProjectileDamage(type);
@@ -310,12 +334,12 @@ namespace CalamityMod.NPCs.ProfanedGuardians
case 0:
break;
case 1:
totalProjectiles = 12;
velocity = 5.5f;
totalProjectiles = phase1 ? 10 : 15;
velocity = phase1 ? 4f : 5f;
break;
case 2:
totalProjectiles = 8;
velocity = 6f;
totalProjectiles = phase1 ? 5 : 7;
velocity = phase1 ? 6f : 7f;
break;
default:
break;
@@ -166,12 +166,12 @@ namespace CalamityMod.NPCs.ProfanedGuardians
Main.PlaySound(SoundID.Item20, npc.position);
int type = ModContent.ProjectileType<FlareDust>();
int damage = npc.GetProjectileDamage(type);
Projectile.NewProjectile(npc.Center, Vector2.Normalize(player.Center - npc.Center) * npc.velocity.Length() * 1.25f, type, damage, 0f, Main.myPlayer, 2f, 0f);
Projectile.NewProjectile(npc.Center, Vector2.Normalize(player.Center - npc.Center) * npc.velocity.Length() * 1.5f, type, damage, 0f, Main.myPlayer, 2f, 0f);
}
}
Vector2 targetVector = player.Center - npc.Center;
float phaseGateValue = (malice || biomeEnraged) ? 120f : death ? 160f : revenge ? 180f : expertMode ? 200f : 240f;
float phaseGateValue = (malice || biomeEnraged) ? 60f : death ? 80f : revenge ? 90f : expertMode ? 100f : 120f;
if (npc.ai[3] >= phaseGateValue && !healerAlive)
{
npc.ai[0] = 1f;
@@ -185,9 +185,9 @@ namespace CalamityMod.NPCs.ProfanedGuardians
float num785 = Main.npc[CalamityGlobalNPC.doughnutBoss].Center.Y - vector96.Y;
float num786 = (float)Math.Sqrt(num784 * num784 + num785 * num785);
if (num786 > 320f)
if (num786 > (healerAlive ? 160f : 80f))
{
num786 = (Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 3f) / num786;
num786 = (Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 5f) / num786;
num784 *= num786;
num785 *= num786;
npc.velocity.X = (npc.velocity.X * 25f + num784) / 26f;
@@ -195,7 +195,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
return;
}
if (npc.velocity.Length() < Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 3f)
if (npc.velocity.Length() < Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 5f)
npc.velocity *= 1.1f;
}
else if (npc.ai[0] == 1f)
@@ -370,11 +370,6 @@ namespace CalamityMod.NPCs.ProfanedGuardians
player.AddBuff(ModContent.BuffType<HolyFlames>(), 240, true);
}
public override void ScaleExpertStats(int numPlayers, float bossLifeScale)
{
npc.damage = (int)(npc.damage * npc.GetExpertDamageMultiplier());
}
public override void HitEffect(int hitDirection, double damage)
{
for (int k = 0; k < 5; k++)
@@ -118,9 +118,9 @@ namespace CalamityMod.NPCs.ProfanedGuardians
float num785 = Main.npc[CalamityGlobalNPC.doughnutBoss].Center.Y - vector96.Y;
float num786 = (float)Math.Sqrt(num784 * num784 + num785 * num785);
if (num786 > 160f)
if (num786 > 320f)
{
num786 = (Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 5f) / num786;
num786 = (Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 3f) / num786;
num784 *= num786;
num785 *= num786;
npc.velocity.X = (npc.velocity.X * 25f + num784) / 26f;
@@ -128,7 +128,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
return;
}
if (npc.velocity.Length() < Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 5f)
if (npc.velocity.Length() < Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 3f)
npc.velocity *= 1.1f;
}
@@ -219,11 +219,6 @@ namespace CalamityMod.NPCs.ProfanedGuardians
player.AddBuff(ModContent.BuffType<HolyFlames>(), 180, true);
}
public override void ScaleExpertStats(int numPlayers, float bossLifeScale)
{
npc.damage = (int)(npc.damage * npc.GetExpertDamageMultiplier());
}
public override void HitEffect(int hitDirection, double damage)
{
for (int k = 0; k < 5; k++)
+4 -2
View File
@@ -12,8 +12,8 @@ using CalamityMod.NPCs.ExoMechs.Thanatos;
using CalamityMod.NPCs.GreatSandShark;
using CalamityMod.NPCs.NormalNPCs;
using CalamityMod.NPCs.Perforator;
using CalamityMod.NPCs.PlaguebringerGoliath;
using CalamityMod.NPCs.PlagueEnemies;
using CalamityMod.NPCs.ProfanedGuardians;
using CalamityMod.NPCs.Providence;
using CalamityMod.NPCs.Ravager;
using CalamityMod.NPCs.SlimeGod;
@@ -262,7 +262,9 @@ namespace CalamityMod.UI
NPCType<SupremeCatastrophe>(),
NPCType<ProvSpawnDefense>(),
NPCType<ProvSpawnOffense>(),
NPCType<ProvSpawnHealer>()
NPCType<ProvSpawnHealer>(),
NPCType<ProfanedGuardianBoss2>(),
NPCType<ProfanedGuardianBoss3>()
};
MinibossHPBarList.AddRange(AcidRainEvent.AllMinibosses);
}
+4 -6
View File
@@ -258,8 +258,6 @@ namespace CalamityMod
{ ModContent.NPCType<AstrumDeusTailSpectral>(), 0.8 },
{ ModContent.NPCType<ProfanedGuardianBoss>(), 0.8 },
{ ModContent.NPCType<ProfanedGuardianBoss2>(), 0.8 },
{ ModContent.NPCType<ProfanedGuardianBoss3>(), 0.8 },
{ ModContent.NPCType<Bumblefuck>(), 0.8 },
@@ -477,8 +475,8 @@ namespace CalamityMod
{ ModContent.NPCType<AstrumDeusTailSpectral>(), new int[] { 80, 128, 160, 168, 192 } },
{ ModContent.NPCType<ProfanedGuardianBoss>(), new int[] { 140, 224, 256, 280, 336 } },
{ ModContent.NPCType<ProfanedGuardianBoss2>(), new int[] { 110, 176, 200, 216, 264 } },
{ ModContent.NPCType<ProfanedGuardianBoss3>(), new int[] { 90, 144, 168, 184, 216 } },
{ ModContent.NPCType<ProfanedGuardianBoss2>(), new int[] { 120, 240, 264, 278, 336 } },
{ ModContent.NPCType<ProfanedGuardianBoss3>(), new int[] { 100, 200, 220, 232, 270 } },
{ ModContent.NPCType<Bumblefuck>(), new int[] { 160, 256, 288, 304, 384 } },
{ ModContent.NPCType<Bumblefuck2>(), new int[] { 110, 220, 242, 256, 330 } },
@@ -696,9 +694,9 @@ namespace CalamityMod
{ new Tuple<int, int>(NPCID.MoonLordFreeEye, ProjectileID.PhantasmalSphere), new int[] { 110, 220, 260, 284, 390 } }, // 330 in non-rev master mode
{ new Tuple<int, int>(NPCID.MoonLordFreeEye, ProjectileID.PhantasmalDeathray), new int[] { 100, 200, 260, 284, 390 } }, // 300 in non-rev master mode
{ new Tuple<int, int>(ModContent.NPCType<ProfanedGuardianBoss>(), ModContent.ProjectileType<ProfanedSpear>()), new int[] { 120, 200, 220, 232, 330 } },
{ new Tuple<int, int>(ModContent.NPCType<ProfanedGuardianBoss>(), ModContent.ProjectileType<ProfanedSpear>()), new int[] { 140, 220, 244, 256, 366 } },
{ new Tuple<int, int>(ModContent.NPCType<ProfanedGuardianBoss>(), ModContent.ProjectileType<FlareDust>()), new int[] { 140, 220, 244, 256, 366 } },
{ new Tuple<int, int>(ModContent.NPCType<ProfanedGuardianBoss2>(), ModContent.ProjectileType<ProfanedSpear>()), new int[] { 120, 200, 220, 232, 330 } },
{ new Tuple<int, int>(ModContent.NPCType<ProfanedGuardianBoss2>(), ModContent.ProjectileType<ProfanedSpear>()), new int[] { 140, 220, 244, 256, 366 } },
{ new Tuple<int, int>(ModContent.NPCType<Bumblefuck>(), ModContent.ProjectileType<RedLightningFeather>()), new int[] { 140, 220, 244, 256, 366 } },
{ new Tuple<int, int>(ModContent.NPCType<Bumblefuck>(), ModContent.ProjectileType<BirbAuraFlare>()), new int[] { 200, 300, 332, 356, 498 } },