diff --git a/Items/Tools/InfernaCutter.cs b/Items/Tools/InfernaCutter.cs index 44429ca5dd..dd8eaa1695 100644 --- a/Items/Tools/InfernaCutter.cs +++ b/Items/Tools/InfernaCutter.cs @@ -1,7 +1,9 @@ using CalamityMod.Items.Materials; +using CalamityMod.Projectiles.Melee; using CalamityMod.Projectiles.Typeless; using Microsoft.Xna.Framework; using Terraria; +using Terraria.DataStructures; using Terraria.ID; using Terraria.ModLoader; @@ -14,14 +16,14 @@ namespace CalamityMod.Items.Tools { Item.width = 80; Item.height = 66; - Item.damage = 110; + Item.damage = 55; Item.crit = 10; Item.knockBack = 7f; Item.useTime = 8; Item.useAnimation = 12; Item.axe = 135 / 5; Item.tileBoost += 1; - + Item.shoot = ProjectileID.Spark; // Dummy argument to ensure it doesn't get set to true melee Item.DamageType = DamageClass.Melee; Item.useTurn = true; Item.useStyle = ItemUseStyleID.Swing; @@ -31,6 +33,8 @@ namespace CalamityMod.Items.Tools Item.autoReuse = true; } + public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) => false; + public override void UseItemHitbox(Player player, ref Rectangle hitbox, ref bool noHitbox) { hitbox = CalamityUtils.FixSwingHitbox(54, 54); @@ -112,7 +116,7 @@ namespace CalamityMod.Items.Tools sparkXSpawn *= (float)player.direction; sparkYSpawn *= player.gravDir; var source = player.GetSource_ItemUse(Item); - int damage = (int)player.GetTotalDamage().ApplyTo(Item.damage * 0.2f); + int damage = (int)player.GetTotalDamage().ApplyTo(Item.damage * 0.5f); int spark = Projectile.NewProjectile(source, (float)(hitbox.X + hitbox.Width / 2) + sparkXSpawn, (float)(hitbox.Y + hitbox.Height / 2) + sparkYSpawn, (float)player.direction * sparkXVel, sparkYVel * player.gravDir, ProjectileID.Spark, damage, 0f, player.whoAmI); if (spark.WithinBounds(Main.maxProjectiles)) Main.projectile[spark].DamageType = DamageClass.Melee; @@ -129,9 +133,10 @@ namespace CalamityMod.Items.Tools if (hit.Crit) { var source = player.GetSource_ItemUse(Item); - int boom = Projectile.NewProjectile(source, target.Center, Vector2.Zero, ModContent.ProjectileType(), Item.damage, Item.knockBack, player.whoAmI, 0f, 0.85f + Main.rand.NextFloat() * 1.15f); - if (boom.WithinBounds(Main.maxProjectiles)) - Main.projectile[boom].DamageType = DamageClass.Melee; + Projectile.NewProjectile(source, target.Center, Vector2.Zero, ModContent.ProjectileType(), 0, Item.knockBack, player.whoAmI, 0f, 0.85f + Main.rand.NextFloat() * 1.15f); + int onHitDamage = player.CalcIntDamage(Item.damage * 0.5f); + Projectile blast = Projectile.NewProjectileDirect(Item.GetSource_FromThis(), target.Center, Vector2.Zero, ModContent.ProjectileType(), onHitDamage, 0f, player.whoAmI, target.whoAmI); + blast.DamageType = Item.DamageType; } target.AddBuff(BuffID.OnFire3, 300); } diff --git a/Items/Weapons/Magic/EventHorizon.cs b/Items/Weapons/Magic/EventHorizon.cs index a84120af62..3215eaa9db 100644 --- a/Items/Weapons/Magic/EventHorizon.cs +++ b/Items/Weapons/Magic/EventHorizon.cs @@ -16,13 +16,13 @@ namespace CalamityMod.Items.Weapons.Magic { Item.width = 40; Item.height = 46; - Item.damage = 77; + Item.damage = 120; Item.knockBack = 3.5f; Item.noMelee = true; Item.DamageType = DamageClass.Magic; - Item.mana = 32; + Item.mana = 45; - Item.useAnimation = Item.useTime = 32; + Item.useAnimation = Item.useTime = 45; Item.useStyle = ItemUseStyleID.Shoot; Item.autoReuse = true; diff --git a/Localization/en-US/Mods.CalamityMod.Items.Misc.hjson b/Localization/en-US/Mods.CalamityMod.Items.Misc.hjson index eae8af8c7e..dd1317d330 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Misc.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Misc.hjson @@ -330,8 +330,7 @@ LegendaryShortTooltip: [c/BABABA:Hold Shift to listen closer] ''' -// Add "Can be extractinated" line in 1.4.5 port DisgustingSlop: { DisplayName: Disgusting Slop - Tooltip: "" + Tooltip: Can be extractinated } diff --git a/Localization/en-US/Mods.CalamityMod.Items.Potions.hjson b/Localization/en-US/Mods.CalamityMod.Items.Potions.hjson index 3e8ffb860e..8d861a4e6f 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Potions.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Potions.hjson @@ -582,7 +582,11 @@ Mangosteen: { QualitySlop: { DisplayName: Quality Slop - Tooltip: "{$CommonItemTooltip.MajorStats}" + Tooltip: + ''' + "{$CommonItemTooltip.MajorStats}" + 'You only like it because it's good' + ''' } Salak: { diff --git a/Localization/en-US/Mods.CalamityMod.Items.Tools.hjson b/Localization/en-US/Mods.CalamityMod.Items.Tools.hjson index c80e1430d7..ea1ac9b35e 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Tools.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Tools.hjson @@ -240,11 +240,11 @@ HurriedVoucher: { InfernaCutter: { DisplayName: Inferna Cutter - Tooltip: - ''' - Critical hits with the blade cause small explosions - Generates a number of small sparks when swung - ''' + Tooltip: + ''' + Critical hits with the blade cause small explosions + Generates a number of small sparks when swung + ''' } MarniteDeconstructor: { diff --git a/NPCs/SupremeCalamitas/SupremeCalamitas.cs b/NPCs/SupremeCalamitas/SupremeCalamitas.cs index 1d1ac7c046..01165da0e4 100644 --- a/NPCs/SupremeCalamitas/SupremeCalamitas.cs +++ b/NPCs/SupremeCalamitas/SupremeCalamitas.cs @@ -164,6 +164,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas public int preventionPause = 15; // Helps prevent telefragging public int attackPause = 0; public bool respawnBro = true; // Master Mode change + public bool teleport = false; //Used to teleport SCal to the center of the arena at the start of each bullet hell public float shieldOpacity = 1f; public float shieldRotation = 0f; @@ -490,9 +491,6 @@ namespace CalamityMod.NPCs.SupremeCalamitas bool revenge = CalamityWorld.revenge || BossRushEvent.BossRushActive; bool death = CalamityWorld.death || BossRushEvent.BossRushActive; - // Used for Scal's teleport at the start of brothers phase - bool teleport = false; - // permafrost and zenith scal are mutually exclusive bool zenithAI = Main.zenithWorld && !permafrost; @@ -1046,7 +1044,17 @@ namespace CalamityMod.NPCs.SupremeCalamitas NPC.damage = 0; NPC.chaseable = false; NPC.dontTakeDamage = true; - + //At the start of the bullet hell, teleport Scal to the center of the arena + if (!teleport) + { + Vector2 goalPos = new Vector2(spawnX + (death ? 1000 : 1250), spawnY + (death ? 1000 : 1250)); // player.Center + new Vector2(0, -175) + Dust.QuickDustLine(NPC.Center, goalPos + new Vector2(0, -20), 500f, permafrost ? Color.Cyan : Color.Red); + NPC.velocity = Vector2.Zero; + NPC.Center = goalPos; + Particle pulse = new DirectionalPulseRing(NPC.Center, Vector2.Zero, Color.Red, new Vector2(1f, 1f), 0, 0.1f, 5f, 15); + GeneralParticleHandler.SpawnParticle(pulse); + teleport = true; + } #region BulletHellEndTelegraphBH2 if (bulletHellCounter2 == (SecondBulletHellEndValue - 360)) BulletHellRumbleSlot = SoundEngine.PlaySound(BulletHellSound, player.Center); @@ -1073,6 +1081,8 @@ namespace CalamityMod.NPCs.SupremeCalamitas GeneralParticleHandler.SpawnParticle(pulse2); SoundEngine.PlaySound(BulletHellEndSound, NPC.Center); + //Reset the teleport bool for the next bullet hell + teleport = false; } #endregion @@ -1177,7 +1187,17 @@ namespace CalamityMod.NPCs.SupremeCalamitas NPC.damage = 0; NPC.chaseable = false; NPC.dontTakeDamage = true; - + //At the start of the bullet hell, teleport Scal to the center of the arena + if (!teleport) + { + Vector2 goalPos = new Vector2(spawnX + (death ? 1000 : 1250), spawnY + (death ? 1000 : 1250)); // player.Center + new Vector2(0, -175) + Dust.QuickDustLine(NPC.Center, goalPos + new Vector2(0, -20), 500f, permafrost ? Color.Cyan : Color.Red); + NPC.velocity = Vector2.Zero; + NPC.Center = goalPos; + Particle pulse = new DirectionalPulseRing(NPC.Center, Vector2.Zero, Color.Red, new Vector2(1f, 1f), 0, 0.1f, 5f, 15); + GeneralParticleHandler.SpawnParticle(pulse); + teleport = true; + } #region BulletHellEndTelegraphBH3 if (bulletHellCounter2 == (ThirdBulletHellEndValue - 360)) BulletHellRumbleSlot = SoundEngine.PlaySound(BulletHellSound, player.Center); @@ -1204,6 +1224,8 @@ namespace CalamityMod.NPCs.SupremeCalamitas GeneralParticleHandler.SpawnParticle(pulse2); SoundEngine.PlaySound(BulletHellEndSound, NPC.Center); + //Reset the teleport bool for the next bullet hell + teleport = false; } #endregion @@ -1353,6 +1375,17 @@ namespace CalamityMod.NPCs.SupremeCalamitas NPC.damage = 0; NPC.chaseable = false; NPC.dontTakeDamage = true; + //At the start of the bullet hell, teleport Scal to the center of the arena + if (!teleport) + { + Vector2 goalPos = new Vector2(spawnX + (death ? 1000 : 1250), spawnY + (death ? 1000 : 1250)); // player.Center + new Vector2(0, -175) + Dust.QuickDustLine(NPC.Center, goalPos + new Vector2(0, -20), 500f, permafrost ? Color.Cyan : Color.Red); + NPC.velocity = Vector2.Zero; + NPC.Center = goalPos; + Particle pulse = new DirectionalPulseRing(NPC.Center, Vector2.Zero, Color.Red, new Vector2(1f, 1f), 0, 0.1f, 5f, 15); + GeneralParticleHandler.SpawnParticle(pulse); + teleport = true; + } #region BulletHellEndTelegraphBH4 if (bulletHellCounter2 == (FourthBulletHellEndValue - 360)) @@ -1380,6 +1413,8 @@ namespace CalamityMod.NPCs.SupremeCalamitas GeneralParticleHandler.SpawnParticle(pulse2); SoundEngine.PlaySound(BulletHellEndSound, NPC.Center); + //Reset the teleport bool for the next bullet hell + teleport = false; } #endregion @@ -1508,7 +1543,17 @@ namespace CalamityMod.NPCs.SupremeCalamitas NPC.damage = 0; NPC.chaseable = false; NPC.dontTakeDamage = true; - + //At the start of the bullet hell, teleport Scal to the center of the arena + if (!teleport) + { + Vector2 goalPos = new Vector2(spawnX + (death ? 1000 : 1250), spawnY + (death ? 1000 : 1250)); // player.Center + new Vector2(0, -175) + Dust.QuickDustLine(NPC.Center, goalPos + new Vector2(0, -20), 500f, permafrost ? Color.Cyan : Color.Red); + NPC.velocity = Vector2.Zero; + NPC.Center = goalPos; + Particle pulse = new DirectionalPulseRing(NPC.Center, Vector2.Zero, Color.Red, new Vector2(1f, 1f), 0, 0.1f, 5f, 15); + GeneralParticleHandler.SpawnParticle(pulse); + teleport = true; + } #region BulletHellEndTelegraphBH5 if (bulletHellCounter2 == (FifthBulletHellEndValue - 360)) BulletHellRumbleSlot = SoundEngine.PlaySound(BulletHellSound, player.Center); @@ -1535,6 +1580,9 @@ namespace CalamityMod.NPCs.SupremeCalamitas GeneralParticleHandler.SpawnParticle(pulse2); SoundEngine.PlaySound(BulletHellEndSound, NPC.Center); + //Reset the teleport bool for the next bullet hell + //Technically not needed but I wanted to be safe + teleport = false; } #endregion @@ -2134,37 +2182,6 @@ namespace CalamityMod.NPCs.SupremeCalamitas enteredBrothersPhase = true; attackCastDelay = brothersSpawnCastTime; NPC.netUpdate = true; - if (!teleport) - { - Vector2 goalPos = new Vector2(spawnX + (death ? 1000 : 1250), spawnY + (death ? 1000 : 1250)); // player.Center + new Vector2(0, -175) - Dust.QuickDustLine(NPC.Center, goalPos + new Vector2(0, -20), 500f, permafrost ? Color.Cyan : Color.Red); - NPC.velocity = Vector2.Zero; - NPC.Center = goalPos; - Particle pulse = new DirectionalPulseRing(NPC.Center, Vector2.Zero, Color.Red, new Vector2(1f, 1f), 0, 0.1f, 5f, 15); - GeneralParticleHandler.SpawnParticle(pulse); - for (int x = 0; x < Main.maxProjectiles; x++) - { - Projectile projectile = Main.projectile[x]; - if (projectile.active) - { - if (projectile.type == bulletHellblast || - projectile.type == barrage || - projectile.type == wave) - { - if (projectile.timeLeft > 60) - projectile.timeLeft = 60; - } - else if (projectile.type == fireblast || projectile.type == gigablast) - { - projectile.ai[2] = 1f; - - if (projectile.timeLeft > 15) - projectile.timeLeft = 15; - } - } - } - teleport = true; - } } else { @@ -2743,13 +2760,14 @@ namespace CalamityMod.NPCs.SupremeCalamitas if (!canDespawn) { - NPC.velocity *= 0.98f; + NPC.velocity *= 0f; if (NPC.velocity.X > -0.1 && NPC.velocity.X < 0.1) NPC.velocity.X = 0f; if (NPC.velocity.Y > -0.1 && NPC.velocity.Y < 0.1) NPC.velocity.Y = 0f; } + FrameType = FrameAnimationType.Casting; } #endregion #region LastStage @@ -3458,6 +3476,14 @@ namespace CalamityMod.NPCs.SupremeCalamitas SoundEngine.PlaySound(new SoundStyle("CalamityMod/Sounds/NPCKilled/RavagerDeath2") with { Pitch = -0.2f }, catastropheSpawnPosition); hasSummonedBrothers = true; } + + NPC.velocity *= 0f; + if (NPC.velocity.X > -0.1 && NPC.velocity.X < 0.1) + NPC.velocity.X = 0f; + if (NPC.velocity.Y > -0.1 && NPC.velocity.Y < 0.1) + NPC.velocity.Y = 0f; + + FrameType = FrameAnimationType.Casting; } public void ConnectAllBrimstoneHearts(List heartIndices) diff --git a/NPCs/SupremeCalamitas/SupremeCalamitasHooded.png b/NPCs/SupremeCalamitas/SupremeCalamitasHooded.png index 0d99e8edfa..eae9fb6ec7 100644 Binary files a/NPCs/SupremeCalamitas/SupremeCalamitasHooded.png and b/NPCs/SupremeCalamitas/SupremeCalamitasHooded.png differ diff --git a/Projectiles/Environment/MurkySteam.cs b/Projectiles/Environment/MurkySteam.cs index 7a08be9d5c..d98779f782 100644 --- a/Projectiles/Environment/MurkySteam.cs +++ b/Projectiles/Environment/MurkySteam.cs @@ -42,7 +42,9 @@ namespace CalamityMod.Projectiles.Environment public override void OnHitPlayer(Player target, Player.HurtInfo info) { - if (info.Damage <= 0) + // CIT 23MAY2026: Vanilla's logic for granting "Burning immunity" is incredibly stupid because Player.fireWalk actually just prevents running hot tile touch code. + // Thus we must add a manual check for Player.fireWalk here too. + if (info.Damage <= 0 || target.fireWalk) return; target.AddBuff(BuffID.Burning, 180); diff --git a/Projectiles/Environment/ThermalSteam.cs b/Projectiles/Environment/ThermalSteam.cs index 4539d420a9..84c4fdeeb2 100644 --- a/Projectiles/Environment/ThermalSteam.cs +++ b/Projectiles/Environment/ThermalSteam.cs @@ -42,7 +42,9 @@ namespace CalamityMod.Projectiles.Environment public override void OnHitPlayer(Player target, Player.HurtInfo info) { - if (info.Damage <= 0) + // CIT 23MAY2026: Vanilla's logic for granting "Burning immunity" is incredibly stupid because Player.fireWalk actually just prevents running hot tile touch code. + // Thus we must add a manual check for Player.fireWalk here too. + if (info.Damage <= 0 || target.fireWalk) return; target.AddBuff(BuffID.Burning, 180);