From ec3084ce2b6c2653e47bbb445fd6076a35c8f235 Mon Sep 17 00:00:00 2001 From: mountaindrew10 Date: Thu, 1 May 2025 08:19:23 -0500 Subject: [PATCH] 1 - Rev+ Eye of Cthulhu phase 2 blood shot spreads are now Death-exclusive because Rev having them was a little ridiculous. 2 - Increased debuff durations for some enemy projectiles. --- CalPlayer/CalamityPlayerHitHurt.cs | 28 ++++++++-------- .../Bosses/EyeOfCthulhuAI.cs | 32 +++++++++++-------- 2 files changed, 32 insertions(+), 28 deletions(-) diff --git a/CalPlayer/CalamityPlayerHitHurt.cs b/CalPlayer/CalamityPlayerHitHurt.cs index 8abe73398a..f5c572ea7e 100644 --- a/CalPlayer/CalamityPlayerHitHurt.cs +++ b/CalPlayer/CalamityPlayerHitHurt.cs @@ -1384,11 +1384,11 @@ namespace CalamityMod.CalPlayer } else if (proj.type == ProjectileID.Stinger || proj.type == ProjectileID.QueenBeeStinger) { - // 66.6% chance of Poison for 3 seconds, 1 guaranteed second of Poison otherwise (vanilla also has a 33.3% chance of Poison for 10 seconds) + // 66.6% chance of Poison for 5 seconds, 2 guaranteed seconds of Poison otherwise (vanilla also has a 33.3% chance of Poison for 10 seconds) if (Main.rand.Next(3) > 0) - Player.AddBuff(BuffID.Poisoned, 180); + Player.AddBuff(BuffID.Poisoned, 300); else - Player.AddBuff(BuffID.Poisoned, 60); + Player.AddBuff(BuffID.Poisoned, 120); } else if (proj.type == ProjectileID.PoisonSeedPlantera) { @@ -1400,11 +1400,11 @@ namespace CalamityMod.CalPlayer } else if (proj.type == ProjectileID.ThornBall) { - Player.AddBuff(BuffID.Poisoned, 300); + Player.AddBuff(BuffID.Poisoned, 420); } else if (proj.type == ProjectileID.CultistBossFireBall) { - Player.AddBuff(ModContent.BuffType(), 120); + Player.AddBuff(ModContent.BuffType(), 180); } else if (proj.type == ProjectileID.CultistBossIceMist) { @@ -1415,7 +1415,7 @@ namespace CalamityMod.CalPlayer } else if (proj.type == ProjectileID.CultistBossLightningOrbArc) { - Player.AddBuff(BuffID.Electrified, 120); + Player.AddBuff(BuffID.Electrified, 180); } else if (proj.type == ProjectileID.AncientDoomProjectile) { @@ -1423,15 +1423,15 @@ namespace CalamityMod.CalPlayer } else if (proj.type == ProjectileID.CultistBossFireBallClone) { - Player.AddBuff(ModContent.BuffType(), 120); + Player.AddBuff(ModContent.BuffType(), 180); } else if (proj.type == ProjectileID.PhantasmalBolt || proj.type == ProjectileID.PhantasmalEye) { - Player.AddBuff(ModContent.BuffType(), 60); + Player.AddBuff(ModContent.BuffType(), 120); } else if (proj.type == ProjectileID.PhantasmalSphere) { - Player.AddBuff(ModContent.BuffType(), 120); + Player.AddBuff(ModContent.BuffType(), 210); } else if (proj.type == ProjectileID.PhantasmalDeathray) { @@ -1439,23 +1439,23 @@ namespace CalamityMod.CalPlayer } else if ((proj.type == ProjectileID.FairyQueenLance || proj.type == ProjectileID.HallowBossRainbowStreak || proj.type == ProjectileID.HallowBossSplitShotCore) && NPC.ShouldEmpressBeEnraged()) { - Player.AddBuff(ModContent.BuffType(), 60); + Player.AddBuff(ModContent.BuffType(), 120); } else if (proj.type == ProjectileID.HallowBossLastingRainbow && NPC.ShouldEmpressBeEnraged()) { - Player.AddBuff(ModContent.BuffType(), 120); + Player.AddBuff(ModContent.BuffType(), 210); } else if (proj.type == ProjectileID.FairyQueenSunDance && NPC.ShouldEmpressBeEnraged()) { - Player.AddBuff(ModContent.BuffType(), 180); + Player.AddBuff(ModContent.BuffType(), 300); } else if (proj.type == ProjectileID.BloodNautilusShot) { - Player.AddBuff(ModContent.BuffType(), 120); + Player.AddBuff(ModContent.BuffType(), 240); } else if (proj.type == ProjectileID.BloodShot) { - Player.AddBuff(ModContent.BuffType(), 60); + Player.AddBuff(ModContent.BuffType(), 180); } else if (proj.type == ProjectileID.RuneBlast && Main.zenithWorld) { diff --git a/NPCs/VanillaNPCAIOverrides/Bosses/EyeOfCthulhuAI.cs b/NPCs/VanillaNPCAIOverrides/Bosses/EyeOfCthulhuAI.cs index a44b972fce..4d6bd4d2b2 100644 --- a/NPCs/VanillaNPCAIOverrides/Bosses/EyeOfCthulhuAI.cs +++ b/NPCs/VanillaNPCAIOverrides/Bosses/EyeOfCthulhuAI.cs @@ -469,23 +469,27 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses npc.SimpleFlyMovement(idealHoverVelocity, hoverAcceleration + (timeToCharge ? ((npc.ai[2] - phaseLimit) * 0.001f) : 0f)); npc.ai[2] += 1f; - float projectileGateValue = (lifeRatio < 0.5f && death) ? 40f : (death ? 60f : 80f); - if (npc.ai[2] % projectileGateValue == 0f && shootProjectile) + + if (death) { - Vector2 projectileVelocity = (Main.player[npc.target].Center - npc.Center).SafeNormalize(Vector2.UnitY) * servantAndProjectileVelocity * 2f; - Vector2 projectileSpawnCenter = npc.Center + projectileVelocity; - if (Main.netMode != NetmodeID.MultiplayerClient) + float projectileGateValue = lifeRatio < 0.5f ? 40f : 60f; + if (npc.ai[2] % projectileGateValue == 0f && shootProjectile) { - int type = ProjectileID.BloodNautilusShot; - int damage = npc.GetProjectileDamage(type); - int numProj = death ? 4 : 3; - int spread = death ? 12 : 10; - float rotation = MathHelper.ToRadians(spread); - for (int i = 0; i < numProj; i++) + Vector2 projectileVelocity = (Main.player[npc.target].Center - npc.Center).SafeNormalize(Vector2.UnitY) * servantAndProjectileVelocity * 2f; + Vector2 projectileSpawnCenter = npc.Center + projectileVelocity; + if (Main.netMode != NetmodeID.MultiplayerClient) { - Vector2 perturbedSpeed = projectileVelocity.RotatedBy(MathHelper.Lerp(-rotation, rotation, i / (float)(numProj - 1))); - int proj = Projectile.NewProjectile(npc.GetSource_FromAI(), npc.Center + perturbedSpeed.SafeNormalize(Vector2.UnitY) * ProjectileOffset, perturbedSpeed, type, damage, 0f, Main.myPlayer); - Main.projectile[proj].timeLeft = 600; + int type = ProjectileID.BloodNautilusShot; + int damage = npc.GetProjectileDamage(type); + int numProj = 3; + int spread = 10; + float rotation = MathHelper.ToRadians(spread); + for (int i = 0; i < numProj; i++) + { + Vector2 perturbedSpeed = projectileVelocity.RotatedBy(MathHelper.Lerp(-rotation, rotation, i / (float)(numProj - 1))); + int proj = Projectile.NewProjectile(npc.GetSource_FromAI(), npc.Center + perturbedSpeed.SafeNormalize(Vector2.UnitY) * ProjectileOffset, perturbedSpeed, type, damage, 0f, Main.myPlayer); + Main.projectile[proj].timeLeft = 600; + } } } }