diff --git a/Items/Placeables/SulphurousSand.png b/Items/Placeables/SulphurousSand.png index f812055202..a82d997ffc 100644 Binary files a/Items/Placeables/SulphurousSand.png and b/Items/Placeables/SulphurousSand.png differ diff --git a/Items/Weapons/AlphaRay.cs b/Items/Weapons/AlphaRay.cs index 7eec6a8aca..3f713c9d96 100644 --- a/Items/Weapons/AlphaRay.cs +++ b/Items/Weapons/AlphaRay.cs @@ -17,7 +17,7 @@ namespace CalamityMod.Items.Weapons public override void SetDefaults() { - item.damage = 260; + item.damage = 280; item.magic = true; item.mana = 5; item.width = 84; @@ -50,8 +50,7 @@ namespace CalamityMod.Items.Weapons { if (player.altFunctionUse == 2) { - Projectile.NewProjectile(position.X, position.Y, speedX, speedY, mod.ProjectileType("BigBeamofDeath"), (int)((double)damage * 1.7), knockBack, player.whoAmI, 0.0f, 0.0f); - return false; + Projectile.NewProjectile(position.X, position.Y, speedX, speedY, mod.ProjectileType("BigBeamofDeath"), (int)((double)damage * 2.1), knockBack, player.whoAmI, 0.0f, 0.0f); } else { @@ -75,8 +74,8 @@ namespace CalamityMod.Items.Weapons Main.projectile[laser].timeLeft = 120; Main.projectile[laser].tileCollide = false; } - return false; } + return false; } public override void AddRecipes() diff --git a/Items/Weapons/Apotheosis.cs b/Items/Weapons/Apotheosis.cs index 6876f243ed..c759df2f56 100644 --- a/Items/Weapons/Apotheosis.cs +++ b/Items/Weapons/Apotheosis.cs @@ -20,8 +20,8 @@ namespace CalamityMod.Items.Weapons item.mana = 42; item.width = 16; item.height = 16; - item.useTime = 42; - item.useAnimation = 42; + item.useTime = 21; + item.useAnimation = 21; item.useStyle = 5; item.useTurn = false; item.noMelee = true; diff --git a/Items/Weapons/PrimordialAncient.png b/Items/Weapons/PrimordialAncient.png index 3aa592c583..6266debfd4 100644 Binary files a/Items/Weapons/PrimordialAncient.png and b/Items/Weapons/PrimordialAncient.png differ diff --git a/Items/Weapons/SkyGlaze.png b/Items/Weapons/SkyGlaze.png index 226dcd9358..a87f71ca2a 100644 Binary files a/Items/Weapons/SkyGlaze.png and b/Items/Weapons/SkyGlaze.png differ diff --git a/NPCs/CalamityAI.cs b/NPCs/CalamityAI.cs index 3848e248b6..a5decb6959 100644 --- a/NPCs/CalamityAI.cs +++ b/NPCs/CalamityAI.cs @@ -262,12 +262,19 @@ namespace CalamityMod.NPCs npc.TargetClosest(true); float velocityX = 6f + (6f * (1f - lifeRatio)); - npc.velocity.X = velocityX * (float)npc.direction; - npc.velocity.Y = -14.5f; - if (npc.target >= 0 && CalamityWorld.revenge && player.position.Y < npc.position.Y + (float)npc.height) + if (CalamityWorld.revenge) + { + if (Main.player[npc.target].position.Y < npc.position.Y + (float)npc.height) + npc.velocity.Y = -14.5f; + else + npc.velocity.Y = 1f; + npc.noTileCollide = true; + } + else + npc.velocity.Y = -14.5f; npc.ai[0] = 4f; npc.ai[1] = 0f; diff --git a/NPCs/CalamityGlobalAI.cs b/NPCs/CalamityGlobalAI.cs index a01529d511..6169929424 100644 --- a/NPCs/CalamityGlobalAI.cs +++ b/NPCs/CalamityGlobalAI.cs @@ -8670,10 +8670,18 @@ namespace CalamityMod.NPCs velocityX *= 1.5f; npc.velocity.X = velocityX * (float)npc.direction; - npc.velocity.Y = -12.1f; - if (npc.target >= 0 && Main.player[npc.target].position.Y < npc.position.Y + (float)npc.height) + if (CalamityWorld.revenge) + { + if (Main.player[npc.target].position.Y < npc.position.Y + (float)npc.height) + npc.velocity.Y = -12.1f; + else + npc.velocity.Y = 1f; + npc.noTileCollide = true; + } + else + npc.velocity.Y = -12.1f; npc.ai[0] = 1f; npc.ai[1] = 0f; @@ -10366,21 +10374,21 @@ namespace CalamityMod.NPCs npc.knockBackResist = 0f; npc.damage = npc.defDamage; + // Percent life remaining + float lifeRatio = (float)npc.life / (float)npc.lifeMax; + + // Phases + bool phase2 = lifeRatio < 0.4f; + bool phase3 = lifeRatio < 0.1f; + if (!Main.eclipse) npc.ai[0] = -1f; else if (npc.target < 0 || Main.player[npc.target].dead || !Main.player[npc.target].active) { npc.TargetClosest(true); - Vector2 vector235 = Main.player[npc.target].Center - npc.Center; - if (Main.player[npc.target].dead || vector235.Length() > 4000f) + if (Main.player[npc.target].dead) npc.ai[0] = -1f; } - else - { - Vector2 vector236 = Main.player[npc.target].Center - npc.Center; - if (npc.ai[0] > 1f && vector236.Length() > 3000f) - npc.ai[0] = 1f; - } if (npc.ai[0] == -1f) { @@ -10431,7 +10439,7 @@ namespace CalamityMod.NPCs npc.ai[2] = 0f; npc.ai[3] = 0f; } - else if (value38.Length() > 240f) + else if (value38.Length() > 600f) { float scaleFactor15 = 15f; float num1354 = 30f; @@ -10446,7 +10454,7 @@ namespace CalamityMod.NPCs npc.ai[1] += 1f; - if (npc.ai[1] >= 20f && Main.netMode != NetmodeID.MultiplayerClient) + if (npc.ai[1] >= 10f && Main.netMode != NetmodeID.MultiplayerClient) { npc.ai[1] = 0f; npc.ai[2] = 0f; @@ -10456,6 +10464,11 @@ namespace CalamityMod.NPCs while (npc.ai[0] == 0f) { int num1355 = Main.rand.Next(3); + if (phase3) + num1355 = 1; + else if (phase2) + num1355 = Main.rand.Next(2); + if (num1355 == 0 && Collision.CanHit(npc.Center, 1, 1, Main.player[npc.target].Center, 1, 1)) npc.ai[0] = 2f; else if (num1355 == 1) @@ -10636,7 +10649,7 @@ namespace CalamityMod.NPCs { if (npc.ai[0] == 3.2f) { - npc.damage = (int)((double)npc.defDamage * 1.5); + npc.damage = (int)((double)npc.defDamage * 1.2); npc.collideX = false; npc.collideY = false; npc.noTileCollide = true; @@ -10690,7 +10703,7 @@ namespace CalamityMod.NPCs while (!WorldGen.SolidTile(num1361, num1362) && (double)num1362 < Main.worldSurface) num1362++; - if ((new Vector2((float)(num1361 * 16 + 8), (float)(num1362 * 16 + 8)) - Main.player[npc.target].Center).Length() < 3600f) + if ((new Vector2((float)(num1361 * 16 + 8), (float)(num1362 * 16 + 8)) - Main.player[npc.target].Center).Length() < 5600f) { npc.ai[0] = 4.1f; npc.ai[1] = (float)num1361; diff --git a/NPCs/CalamityGlobalNPC.cs b/NPCs/CalamityGlobalNPC.cs index bd162318f5..5a18972d11 100644 --- a/NPCs/CalamityGlobalNPC.cs +++ b/NPCs/CalamityGlobalNPC.cs @@ -678,14 +678,17 @@ namespace CalamityMod.NPCs } else if (npc.type == NPCID.Golem) { - npc.lifeMax = CalamityWorld.death ? (int)(npc.lifeMax * 5.0) : (int)(npc.lifeMax * 2.5); + npc.lifeMax = CalamityWorld.death ? (int)(npc.lifeMax * 7.0) : (int)(npc.lifeMax * 4.0); npc.npcSlots = 64f; } - else if (npc.type == NPCID.GolemHead || npc.type == NPCID.GolemHeadFree) + else if (npc.type == NPCID.GolemHead) { npc.lifeMax = CalamityWorld.death ? (int)(npc.lifeMax * 3.0) : (int)(npc.lifeMax * 2.0); - if (npc.type == NPCID.GolemHeadFree) - npc.dontTakeDamage = false; + } + else if (npc.type == NPCID.GolemHeadFree) + { + npc.lifeMax = CalamityWorld.death ? (int)(npc.lifeMax * 1.25) : (int)(npc.lifeMax * 1.1); + npc.dontTakeDamage = false; } else if (npc.type == NPCID.Plantera) { diff --git a/NPCs/Scavenger/ScavengerBody.cs b/NPCs/Scavenger/ScavengerBody.cs index 34b575c4be..3ffd9b65f0 100644 --- a/NPCs/Scavenger/ScavengerBody.cs +++ b/NPCs/Scavenger/ScavengerBody.cs @@ -102,8 +102,13 @@ namespace CalamityMod.NPCs.Scavenger // Percent life remaining float lifeRatio = (float)npc.life / (float)npc.lifeMax; - Lighting.AddLight((int)(npc.position.X - 100f) / 16, (int)(npc.position.Y - 20f) / 16, 0f, 0.51f, 2f); - Lighting.AddLight((int)(npc.position.X + 100f) / 16, (int)(npc.position.Y - 20f) / 16, 0f, 0.51f, 2f); + // Large fire light + Lighting.AddLight((int)(npc.Center.X - 110f) / 16, (int)(npc.Center.Y - 30f) / 16, 0f, 0.5f, 2f); + Lighting.AddLight((int)(npc.Center.X + 110f) / 16, (int)(npc.Center.Y - 30f) / 16, 0f, 0.5f, 2f); + + // Small fire light + Lighting.AddLight((int)(npc.Center.X - 40f) / 16, (int)(npc.Center.Y - 60f) / 16, 0f, 0.25f, 1f); + Lighting.AddLight((int)(npc.Center.X + 40f) / 16, (int)(npc.Center.Y - 60f) / 16, 0f, 0.25f, 1f); CalamityGlobalNPC.scavenger = npc.whoAmI; @@ -387,12 +392,20 @@ namespace CalamityMod.NPCs.Scavenger { npc.TargetClosest(true); - float speedX = ((enrage || npc.GetGlobalNPC(mod).enraged || (Config.BossRushXerocCurse && CalamityWorld.bossRushActive)) ? 8f : 4f) + (4f * (1f - lifeRatio)); - npc.velocity.X = speedX * (float)npc.direction; - npc.velocity.Y = -15.2f; + float velocityX = ((enrage || npc.GetGlobalNPC(mod).enraged || (Config.BossRushXerocCurse && CalamityWorld.bossRushActive)) ? 8f : 4f) + (4f * (1f - lifeRatio)); + npc.velocity.X = velocityX * (float)npc.direction; + + if (CalamityWorld.revenge) + { + if (Main.player[npc.target].position.Y < npc.position.Y + (float)npc.height) + npc.velocity.Y = -15.2f; + else + npc.velocity.Y = 1f; - if (npc.target >= 0 && CalamityWorld.revenge && Main.player[npc.target].position.Y < npc.position.Y + (float)npc.height) npc.noTileCollide = true; + } + else + npc.velocity.Y = -15.2f; npc.ai[0] = 1f; npc.ai[1] = 0f; diff --git a/Projectiles/Ranged/SulphuricAcidCannon2.cs b/Projectiles/Ranged/SulphuricAcidCannon2.cs index 83ad56f8c7..d02e949825 100644 --- a/Projectiles/Ranged/SulphuricAcidCannon2.cs +++ b/Projectiles/Ranged/SulphuricAcidCannon2.cs @@ -109,19 +109,10 @@ namespace CalamityMod.Projectiles.Ranged if (projectile.ai[0] == 1f) { projectile.tileCollide = false; - int num988 = 15; bool flag54 = false; - bool flag55 = false; - float[] var_2_2CB4E_cp_0 = projectile.localAI; - int var_2_2CB4E_cp_1 = 0; - float num73 = var_2_2CB4E_cp_0[var_2_2CB4E_cp_1]; - var_2_2CB4E_cp_0[var_2_2CB4E_cp_1] = num73 + 1f; - if (projectile.localAI[0] % 30f == 0f) - { - flag55 = true; - } + projectile.localAI[0] += 1f; int num989 = (int)projectile.ai[1]; - if (projectile.localAI[0] >= (float)(60 * num988)) + if (projectile.localAI[0] >= 360f) { flag54 = true; } @@ -133,10 +124,6 @@ namespace CalamityMod.Projectiles.Ranged { projectile.Center = Main.npc[num989].Center - projectile.velocity * 2f; projectile.gfxOffY = Main.npc[num989].gfxOffY; - if (flag55) - { - Main.npc[num989].HitEffect(0, 1.0); - } } else { diff --git a/Tiles/SulphurousSand.png b/Tiles/SulphurousSand.png index 80cf291f2a..68581b302a 100644 Binary files a/Tiles/SulphurousSand.png and b/Tiles/SulphurousSand.png differ diff --git a/UI/BossHealthBarManager.cs b/UI/BossHealthBarManager.cs index 2228be262a..2c22638c6c 100644 --- a/UI/BossHealthBarManager.cs +++ b/UI/BossHealthBarManager.cs @@ -39,7 +39,7 @@ namespace CalamityMod.UI internal static class BossHealthBarManager { - private static readonly int MAX_BARS = 4; //4 + private static readonly int MAX_BARS = 4; public static bool SHOULD_DRAW_SMALLTEXT_HEALTH = true; @@ -96,7 +96,14 @@ namespace CalamityMod.UI OneToMany[NPCID.PrimeCannon] = SkelePrime; OneToMany[NPCID.PrimeLaser] = SkelePrime; - int[] Saucer = new int[] { NPCID.MartianSaucerCore, NPCID.MartianSaucerTurret, NPCID.MartianSaucerCannon }; + int[] Golem = new int[] { NPCID.Golem, NPCID.GolemFistLeft, NPCID.GolemFistRight, NPCID.GolemHead, NPCID.GolemHeadFree }; + OneToMany[NPCID.Golem] = Golem; + OneToMany[NPCID.GolemFistLeft] = Golem; + OneToMany[NPCID.GolemFistRight] = Golem; + OneToMany[NPCID.GolemHead] = Golem; + OneToMany[NPCID.GolemHeadFree] = Golem; + + int[] Saucer = new int[] { NPCID.MartianSaucerCore, NPCID.MartianSaucerTurret, NPCID.MartianSaucerCannon }; OneToMany[NPCID.MartianSaucerCore] = Saucer; OneToMany[NPCID.MartianSaucerTurret] = Saucer; OneToMany[NPCID.MartianSaucerCannon] = Saucer; @@ -239,7 +246,8 @@ namespace CalamityMod.UI MinibossHPBarList.Add(calamity.NPCType("ProvSpawnDefense")); MinibossHPBarList.Add(calamity.NPCType("ProvSpawnOffense")); MinibossHPBarList.Add(calamity.NPCType("ProvSpawnHealer")); - } + MinibossHPBarList.Add(calamity.NPCType("PolterPhantom")); + } } public static void Unload() @@ -281,7 +289,11 @@ namespace CalamityMod.UI { AttemptAddBar(i, NPCID.SkeletronPrime); } - else if (Main.npc[i].type == NPCID.MartianSaucerCore) + else if (Main.npc[i].type == NPCID.Golem) + { + AttemptAddBar(i, NPCID.Golem); + } + else if (Main.npc[i].type == NPCID.MartianSaucerCore) { AttemptAddBar(i, NPCID.MartianSaucerCore); }