diff --git a/NPCs/ProfanedGuardians/ProfanedGuardianBoss.cs b/NPCs/ProfanedGuardians/ProfanedGuardianBoss.cs index fc6f9b95f2..56476e1ba0 100644 --- a/NPCs/ProfanedGuardians/ProfanedGuardianBoss.cs +++ b/NPCs/ProfanedGuardians/ProfanedGuardianBoss.cs @@ -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(); 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(); 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; diff --git a/NPCs/ProfanedGuardians/ProfanedGuardianBoss2.cs b/NPCs/ProfanedGuardians/ProfanedGuardianBoss2.cs index bcb7dd1624..d7e2f2b227 100644 --- a/NPCs/ProfanedGuardians/ProfanedGuardianBoss2.cs +++ b/NPCs/ProfanedGuardians/ProfanedGuardianBoss2.cs @@ -166,12 +166,12 @@ namespace CalamityMod.NPCs.ProfanedGuardians Main.PlaySound(SoundID.Item20, npc.position); int type = ModContent.ProjectileType(); 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(), 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++) diff --git a/NPCs/ProfanedGuardians/ProfanedGuardianBoss3.cs b/NPCs/ProfanedGuardians/ProfanedGuardianBoss3.cs index 815276f31f..f9709b672b 100644 --- a/NPCs/ProfanedGuardians/ProfanedGuardianBoss3.cs +++ b/NPCs/ProfanedGuardians/ProfanedGuardianBoss3.cs @@ -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(), 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++) diff --git a/UI/BossHealthBarManager.cs b/UI/BossHealthBarManager.cs index c3f552f8e2..1264a7f32b 100644 --- a/UI/BossHealthBarManager.cs +++ b/UI/BossHealthBarManager.cs @@ -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(), NPCType(), NPCType(), - NPCType() + NPCType(), + NPCType(), + NPCType() }; MinibossHPBarList.AddRange(AcidRainEvent.AllMinibosses); } diff --git a/Utilities/NPCStats.cs b/Utilities/NPCStats.cs index cbe5a3efb6..4de8e8cbb4 100644 --- a/Utilities/NPCStats.cs +++ b/Utilities/NPCStats.cs @@ -258,8 +258,6 @@ namespace CalamityMod { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, - { ModContent.NPCType(), 0.8 }, - { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, @@ -477,8 +475,8 @@ namespace CalamityMod { ModContent.NPCType(), new int[] { 80, 128, 160, 168, 192 } }, { ModContent.NPCType(), new int[] { 140, 224, 256, 280, 336 } }, - { ModContent.NPCType(), new int[] { 110, 176, 200, 216, 264 } }, - { ModContent.NPCType(), new int[] { 90, 144, 168, 184, 216 } }, + { ModContent.NPCType(), new int[] { 120, 240, 264, 278, 336 } }, + { ModContent.NPCType(), new int[] { 100, 200, 220, 232, 270 } }, { ModContent.NPCType(), new int[] { 160, 256, 288, 304, 384 } }, { ModContent.NPCType(), new int[] { 110, 220, 242, 256, 330 } }, @@ -696,9 +694,9 @@ namespace CalamityMod { new Tuple(NPCID.MoonLordFreeEye, ProjectileID.PhantasmalSphere), new int[] { 110, 220, 260, 284, 390 } }, // 330 in non-rev master mode { new Tuple(NPCID.MoonLordFreeEye, ProjectileID.PhantasmalDeathray), new int[] { 100, 200, 260, 284, 390 } }, // 300 in non-rev master mode - { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120, 200, 220, 232, 330 } }, + { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 140, 220, 244, 256, 366 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 140, 220, 244, 256, 366 } }, - { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120, 200, 220, 232, 330 } }, + { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 140, 220, 244, 256, 366 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 140, 220, 244, 256, 366 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200, 300, 332, 356, 498 } },