From 5b432b076324f10f7a49b63372320d6f39a08f72 Mon Sep 17 00:00:00 2001 From: Amber Sienna Date: Wed, 1 Apr 2020 12:30:45 +0100 Subject: [PATCH 1/8] ColdDivinityPointyThing.cs fix --- Projectiles/Summon/ColdDivinityPointyThing.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Projectiles/Summon/ColdDivinityPointyThing.cs b/Projectiles/Summon/ColdDivinityPointyThing.cs index 0a954f9e0c..a1159ab4ce 100644 --- a/Projectiles/Summon/ColdDivinityPointyThing.cs +++ b/Projectiles/Summon/ColdDivinityPointyThing.cs @@ -91,6 +91,11 @@ namespace CalamityMod.Projectiles.Summon public override bool PreAI() { + if (recharging == -1) + { + recharging = projectile.ai[1] == 0f ? 300 : 0; + dust(30); + } if (projectile.ai[1] == 1f && projectile.timeLeft > 1000) { projectile.ai[1] = 0f; @@ -112,11 +117,6 @@ namespace CalamityMod.Projectiles.Summon projectile.idStaticNPCHitCooldown = 4; projectile.netUpdate = true; } - if (recharging == -1) - { - recharging = projectile.ai[1] == 0f ? 300 : 0; - dust(30); - } if (circlingPlayer) { ProjectileID.Sets.MinionSacrificable[projectile.type] = true; From 6d16d5b53816e63a919a17e48f2763948c10fb14 Mon Sep 17 00:00:00 2001 From: Amber Sienna Date: Wed, 1 Apr 2020 12:40:26 +0100 Subject: [PATCH 2/8] SpentFuelContainer balancing --- Items/Weapons/Rogue/SpentFuelContainer.cs | 2 +- NPCs/CalamityGlobalNPC.cs | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Items/Weapons/Rogue/SpentFuelContainer.cs b/Items/Weapons/Rogue/SpentFuelContainer.cs index cb74c5158e..f89b2a0c58 100644 --- a/Items/Weapons/Rogue/SpentFuelContainer.cs +++ b/Items/Weapons/Rogue/SpentFuelContainer.cs @@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Rogue public override void SafeSetDefaults() { - item.damage = 69; + item.damage = 50; item.width = 22; item.height = 24; item.useAnimation = 29; diff --git a/NPCs/CalamityGlobalNPC.cs b/NPCs/CalamityGlobalNPC.cs index e7dd14b105..1d4b6fd729 100644 --- a/NPCs/CalamityGlobalNPC.cs +++ b/NPCs/CalamityGlobalNPC.cs @@ -3436,10 +3436,14 @@ namespace CalamityMod.NPCs { damage = (int)(damage * 0.75); } - if (projectile.type == ModContent.ProjectileType()) + else if (projectile.type == ModContent.ProjectileType()) { damage = (int)(damage * 0.25); } + else if (projectile.type == ModContent.ProjectileType()) + { + damage /= 3; + } } else if (AquaticScourgeIDs.Contains(npc.type)) { From fd7df2df073d38289d40f891b70478cd3af2ddad Mon Sep 17 00:00:00 2001 From: Amber Sienna Date: Wed, 1 Apr 2020 12:49:27 +0100 Subject: [PATCH 3/8] Adjusted Nuclear Terror's value --- NPCs/CalamityGlobalNPCLoot.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/NPCs/CalamityGlobalNPCLoot.cs b/NPCs/CalamityGlobalNPCLoot.cs index 8c3351739b..3cbe806826 100644 --- a/NPCs/CalamityGlobalNPCLoot.cs +++ b/NPCs/CalamityGlobalNPCLoot.cs @@ -14,6 +14,7 @@ using CalamityMod.Items.Weapons.Ranged; using CalamityMod.Items.Weapons.Rogue; using CalamityMod.Items.Weapons.Summon; using CalamityMod.NPCs.Abyss; +using CalamityMod.NPCs.AcidRain; using CalamityMod.NPCs.AquaticScourge; using CalamityMod.NPCs.Astral; using CalamityMod.NPCs.AstrumDeus; @@ -1613,7 +1614,7 @@ namespace CalamityMod.NPCs if (AcidRainEvent.PossibleMinibossesAS.Select(miniboss => miniboss.Item1).Contains(npc.type) || AcidRainEvent.PossibleMinibossesPolter.Select(miniboss => miniboss.Item1).Contains(npc.type)) { - CalamityWorld.acidRainPoints -= AcidRainEvent.MinibossDeathValue; + CalamityWorld.acidRainPoints -= AcidRainEvent.MinibossDeathValue * (npc.type == ModContent.NPCType() ? 2 : 1); if (CalamityWorld.downedPolterghast) { CalamityWorld.acidRainPoints = (int)MathHelper.Max(2, CalamityWorld.acidRainPoints); // Cap at 2. The last points are for Old Duke. From ea7be9ac049d57b8de47155e7a182657ffcbda81 Mon Sep 17 00:00:00 2001 From: Amber Sienna Date: Wed, 1 Apr 2020 13:01:31 +0100 Subject: [PATCH 4/8] made my prior commit less dum --- Events/AcidRainEvent.cs | 12 +++++------- NPCs/CalamityGlobalNPC.cs | 4 ++-- NPCs/CalamityGlobalNPCLoot.cs | 4 +++- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/Events/AcidRainEvent.cs b/Events/AcidRainEvent.cs index 5e73a3b8d1..4ff11e4435 100644 --- a/Events/AcidRainEvent.cs +++ b/Events/AcidRainEvent.cs @@ -18,8 +18,6 @@ namespace CalamityMod.Events // Any other mods are changing the invasion ID as well. public const int InvasionID = 57; - public const int MinibossDeathValue = 5; - // A partially bright pale-ish cyan with a hint of yellow. public static readonly Color TextColor = new Color(115, 194, 147); @@ -63,15 +61,15 @@ namespace CalamityMod.Events ( ModContent.NPCType(), 1, false ) }; - public static List<(int, bool)> PossibleMinibossesAS = new List<(int, bool)>() + public static List<(int, int, bool)> PossibleMinibossesAS = new List<(int, int, bool)>() { - (ModContent.NPCType(), true) + (ModContent.NPCType(), 5, true) }; - public static List<(int, bool)> PossibleMinibossesPolter = new List<(int, bool)>() + public static List<(int, int, bool)> PossibleMinibossesPolter = new List<(int, int, bool)>() { - (ModContent.NPCType(), true), - (ModContent.NPCType(), false) + (ModContent.NPCType(), 4, true), + (ModContent.NPCType(), 8, false) }; public static readonly List AllMinibosses = PossibleMinibossesAS.Select(miniboss => miniboss.Item1).ToList().Concat(PossibleMinibossesPolter.Select(miniboss => miniboss.Item1)).Distinct().ToList(); diff --git a/NPCs/CalamityGlobalNPC.cs b/NPCs/CalamityGlobalNPC.cs index 1d4b6fd729..968b5f1d4c 100644 --- a/NPCs/CalamityGlobalNPC.cs +++ b/NPCs/CalamityGlobalNPC.cs @@ -3996,7 +3996,7 @@ namespace CalamityMod.NPCs if (!(CalamityWorld.downedPolterghast && CalamityWorld.acidRainPoints == 2)) { List<(int, int, bool)> PossibleEnemies = AcidRainEvent.PossibleEnemiesPreHM; - List<(int, bool)> PossibleMinibosses = new List<(int, bool)>(); + List<(int, int, bool)> PossibleMinibosses = new List<(int, int, bool)>(); if (CalamityWorld.downedAquaticScourge) { PossibleEnemies = AcidRainEvent.PossibleEnemiesAS; @@ -4018,7 +4018,7 @@ namespace CalamityMod.NPCs { foreach (int enemy in PossibleMinibosses.Select(miniboss => miniboss.Item1).ToList()) { - if (spawnInfo.water || !PossibleMinibosses.First(potential => potential.Item1 == enemy).Item2) + if (spawnInfo.water || !PossibleMinibosses.First(potential => potential.Item1 == enemy).Item3) { pool.Add(enemy, 0.05f); } diff --git a/NPCs/CalamityGlobalNPCLoot.cs b/NPCs/CalamityGlobalNPCLoot.cs index 3cbe806826..715a29d73b 100644 --- a/NPCs/CalamityGlobalNPCLoot.cs +++ b/NPCs/CalamityGlobalNPCLoot.cs @@ -1599,6 +1599,7 @@ namespace CalamityMod.NPCs private void AcidRainProgression(NPC npc) { List<(int, int, bool)> PossibleEnemies = AcidRainEvent.PossibleEnemiesPreHM; + List<(int, int, bool)> PossibleMinibosses = new List<(int, int, bool)>(); if (CalamityWorld.downedAquaticScourge) PossibleEnemies = AcidRainEvent.PossibleEnemiesAS; if (CalamityWorld.downedPolterghast) @@ -1611,10 +1612,11 @@ namespace CalamityMod.NPCs CalamityWorld.acidRainPoints = (int)MathHelper.Max(2, CalamityWorld.acidRainPoints); // Cap at 2. The last points are for Old Duke. } } + PossibleMinibosses = CalamityWorld.downedPolterghast ? AcidRainEvent.PossibleMinibossesPolter : PossibleMinibosses; if (AcidRainEvent.PossibleMinibossesAS.Select(miniboss => miniboss.Item1).Contains(npc.type) || AcidRainEvent.PossibleMinibossesPolter.Select(miniboss => miniboss.Item1).Contains(npc.type)) { - CalamityWorld.acidRainPoints -= AcidRainEvent.MinibossDeathValue * (npc.type == ModContent.NPCType() ? 2 : 1); + CalamityWorld.acidRainPoints -= PossibleMinibosses.Find(enemy => enemy.Item1 == npc.type).Item2; if (CalamityWorld.downedPolterghast) { CalamityWorld.acidRainPoints = (int)MathHelper.Max(2, CalamityWorld.acidRainPoints); // Cap at 2. The last points are for Old Duke. From 54b0907b4eac00e8ce7de218b780888cd1fe3d79 Mon Sep 17 00:00:00 2001 From: Amber Sienna Date: Wed, 1 Apr 2020 14:18:23 +0100 Subject: [PATCH 5/8] Cold Divinity Fix --- Items/CalamityGlobalItem.cs | 12 +++++++----- Projectiles/Summon/ColdDivinityPointyThing.cs | 11 +++++++---- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/Items/CalamityGlobalItem.cs b/Items/CalamityGlobalItem.cs index b98cf6d7fd..a6a6957898 100644 --- a/Items/CalamityGlobalItem.cs +++ b/Items/CalamityGlobalItem.cs @@ -673,14 +673,15 @@ namespace CalamityMod.Items { if (Main.projectile[i].active && Main.projectile[i].type == ModContent.ProjectileType() && Main.projectile[i].owner == player.whoAmI) { - if (Main.projectile[i].ai[1] >= 1f) + if (Main.projectile[i].ai[1] > 1f) { canContinue = false; break; } else if (Main.projectile[i].ai[1] == 0f) { - count++; + if (((ColdDivinityPointyThing)Main.projectile[i].modProjectile).circlingPlayer) + count++; } } } @@ -691,14 +692,15 @@ namespace CalamityMod.Items { int height = unluckyTarget.getRect().Height; int width = unluckyTarget.getRect().Width; - float dist = (height > width ? height : width) * 1.5f; //create distance between hitbox and spears. int pointyThingyAmount = count; - pointyThingyAmount += dist > 100 ? (int)dist / 100 : 0; float angleVariance = MathHelper.TwoPi / pointyThingyAmount; float angle = 0f; + for (int i = 0; i < pointyThingyAmount; i++) { - int projj = Projectile.NewProjectile(Main.MouseWorld, Vector2.Zero, ModContent.ProjectileType(), (int)((80 * player.MinionDamage())), 1f, player.whoAmI, angle, 2f); + if (Main.projectile.Length == Main.maxProjectiles) + break; + int projj = Projectile.NewProjectile(Main.MouseWorld, Vector2.Zero, ModContent.ProjectileType(), (int)(80 * player.MinionDamage()), 1f, player.whoAmI, angle, 2f); angle += angleVariance; for (int j = 0; j < 22; j++) { diff --git a/Projectiles/Summon/ColdDivinityPointyThing.cs b/Projectiles/Summon/ColdDivinityPointyThing.cs index a1159ab4ce..5b60feae30 100644 --- a/Projectiles/Summon/ColdDivinityPointyThing.cs +++ b/Projectiles/Summon/ColdDivinityPointyThing.cs @@ -103,7 +103,7 @@ namespace CalamityMod.Projectiles.Summon circling = circlingPlayer = false; projectile.netUpdate = true; } - else if (projectile.ai[1] == 2f && projectile.timeLeft > 900) + else if (projectile.ai[1] >= 2f && projectile.timeLeft > 900) { target = CalamityUtils.MinionHoming(projectile.position, 1000f, Main.player[projectile.owner]); projectile.timeLeft = 800; @@ -111,7 +111,9 @@ namespace CalamityMod.Projectiles.Summon circlingPlayer = false; float height = target.getRect().Height; float width = target.getRect().Width; - floatyDistance = (height > width ? height : width) * 1.15f; + floatyDistance = (height > width ? height : width) * 1.5f; + if (floatyDistance > Main.LogicCheckScreenWidth / 3) + floatyDistance = Main.LogicCheckScreenWidth / 3; projectile.penetrate = -1; projectile.usesIDStaticNPCImmunity = true; projectile.idStaticNPCHitCooldown = 4; @@ -182,10 +184,11 @@ namespace CalamityMod.Projectiles.Summon recharging = 0; projectile.usesIDStaticNPCImmunity = false; projectile.penetrate = 1; + float applicableDist = target.getRect().Width > target.getRect().Height ? target.getRect().Width : target.getRect().Height; if (projectile.timeLeft > 60) - floatyDistance += Main.rand.Next(0, 5); + floatyDistance += Main.rand.Next(0, 10); else - floatyDistance -= Main.rand.Next(5, 10); + floatyDistance -= Main.rand.Next(10, 20); } if (circlingPlayer) { From 0a3c0c4661b86afe9765cc80dd071c12dd2071af Mon Sep 17 00:00:00 2001 From: Amber Sienna Date: Wed, 1 Apr 2020 14:44:48 +0100 Subject: [PATCH 6/8] Old Duke Balancing --- Items/Weapons/Rogue/TheReaper.cs | 2 +- NPCs/CalamityGlobalNPC.cs | 12 ++++++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Rogue/TheReaper.cs b/Items/Weapons/Rogue/TheReaper.cs index 61f9ae178d..7b96d716e7 100644 --- a/Items/Weapons/Rogue/TheReaper.cs +++ b/Items/Weapons/Rogue/TheReaper.cs @@ -18,7 +18,7 @@ namespace CalamityMod.Items.Weapons.Rogue public override void SafeSetDefaults() { item.width = 80; - item.damage = 325; + item.damage = 150; item.noMelee = true; item.noUseGraphic = true; item.useAnimation = 22; diff --git a/NPCs/CalamityGlobalNPC.cs b/NPCs/CalamityGlobalNPC.cs index 968b5f1d4c..fe80788dc4 100644 --- a/NPCs/CalamityGlobalNPC.cs +++ b/NPCs/CalamityGlobalNPC.cs @@ -3480,14 +3480,22 @@ namespace CalamityMod.NPCs { damage = (int)(damage * 0.4); } - if (projectile.type == (ModContent.ProjectileType() | ModContent.ProjectileType() | ModContent.ProjectileType())) + else if (projectile.type == (ModContent.ProjectileType() | ModContent.ProjectileType() | ModContent.ProjectileType())) { damage = (int)(damage * 0.6); } - if (projectile.type == (ModContent.ProjectileType() | ProjectileID.LunarFlare)) + else if (projectile.type == (ModContent.ProjectileType() | ProjectileID.LunarFlare)) { damage = (int)(damage * 0.8); } + else if (projectile.type == (ModContent.ProjectileType() | ModContent.ProjectileType() | ModContent.ProjectileType() | ModContent.ProjectileType())) + { + damage = (int)(damage * 0.75); + } + else if (projectile.type == ModContent.ProjectileType()) + { + damage = (int)(damage * 0.5); + } } if (!projectile.npcProj && !projectile.trap) From 83d609547f8af8464fc5706ce0f611e6d342ada3 Mon Sep 17 00:00:00 2001 From: Amber Sienna Date: Wed, 1 Apr 2020 14:52:20 +0100 Subject: [PATCH 7/8] Nerfed spent fuel container --- Projectiles/Rogue/SulphuricNukesplosion.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Projectiles/Rogue/SulphuricNukesplosion.cs b/Projectiles/Rogue/SulphuricNukesplosion.cs index 7874f6eb53..d590933160 100644 --- a/Projectiles/Rogue/SulphuricNukesplosion.cs +++ b/Projectiles/Rogue/SulphuricNukesplosion.cs @@ -35,6 +35,9 @@ namespace CalamityMod.Projectiles.Rogue projectile.tileCollide = false; projectile.alpha = 255; projectile.Calamity().rogue = true; + projectile.usesLocalNPCImmunity = true; + projectile.localNPCHitCooldown = 4; + } public override bool PreAI() From 33e581c03b5595fdb2bb085255ea0cef7fb70562 Mon Sep 17 00:00:00 2001 From: Amber Sienna Date: Wed, 1 Apr 2020 15:06:24 +0100 Subject: [PATCH 8/8] Cold divinity left click nerf --- Items/Weapons/Summon/ColdDivinity.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Summon/ColdDivinity.cs b/Items/Weapons/Summon/ColdDivinity.cs index ddb0b2acfe..f4ce8dd61c 100644 --- a/Items/Weapons/Summon/ColdDivinity.cs +++ b/Items/Weapons/Summon/ColdDivinity.cs @@ -24,7 +24,7 @@ namespace CalamityMod.Items.Weapons.Summon public override void SetDefaults() { - item.damage = 80; + item.damage = 52; item.mana = 20; item.width = 52; item.height = 50;