diff --git a/Projectiles/DraedonsArsenal/CountermeasureMittHoldout.cs b/Projectiles/DraedonsArsenal/CountermeasureMittHoldout.cs index 6ab5de6adc..1afbee1b94 100644 --- a/Projectiles/DraedonsArsenal/CountermeasureMittHoldout.cs +++ b/Projectiles/DraedonsArsenal/CountermeasureMittHoldout.cs @@ -154,6 +154,13 @@ namespace CalamityMod.Projectiles.DraedonsArsenal if (hitTimer > 0) hitTimer--; + if (Owner.dead) + { + EndSounds(); + Projectile.Kill(); + return; + } + Owner.SetCompositeArmBack(true, Player.CompositeArmStretchAmount.Full, (alteredRotation + MathHelper.PiOver2 * -Projectile.direction) + (Owner.direction == -1 ? MathHelper.Pi : 0)); Vector2 handPos = Owner.GetBackHandPosition(CompositeArmStretchAmount.None, Owner.compositeBackArm.rotation) + (Owner.compositeBackArm.rotation + MathHelper.PiOver2).ToRotationVector2() * 4; diff --git a/Projectiles/DraedonsArsenal/PulseGrenadeProjectile.cs b/Projectiles/DraedonsArsenal/PulseGrenadeProjectile.cs index c5979fa23a..2349a8ebe1 100644 --- a/Projectiles/DraedonsArsenal/PulseGrenadeProjectile.cs +++ b/Projectiles/DraedonsArsenal/PulseGrenadeProjectile.cs @@ -55,6 +55,11 @@ namespace CalamityMod.Projectiles.DraedonsArsenal public override bool? CanDamage() => (flung ? null : false); public override void AI() { + if (Owner.dead && !flung) + { + Projectile.Kill(); + return; + } if (Owner.HeldItem.type != ModContent.ItemType()) { Projectile.Kill(); diff --git a/Projectiles/DraedonsArsenal/VulcanHoldout.cs b/Projectiles/DraedonsArsenal/VulcanHoldout.cs index 25b30502fa..d86259fbd3 100644 --- a/Projectiles/DraedonsArsenal/VulcanHoldout.cs +++ b/Projectiles/DraedonsArsenal/VulcanHoldout.cs @@ -46,6 +46,12 @@ namespace CalamityMod.Projectiles.DraedonsArsenal } public override void HoldoutAI() { + if (Owner.dead) + { + Projectile.Kill(); + return; + } + if (flashVis1 > 0) flashVis1 -= 0.2f; if (flashVis1 < 0) flashVis1 = 0; if (flashVis2 > 0) flashVis2 -= 0.2f; if (flashVis2 < 0) flashVis2 = 0; diff --git a/Projectiles/Rogue/DoomsdayDeviceProjectile.cs b/Projectiles/Rogue/DoomsdayDeviceProjectile.cs index 265b3e9638..ebdf68342e 100644 --- a/Projectiles/Rogue/DoomsdayDeviceProjectile.cs +++ b/Projectiles/Rogue/DoomsdayDeviceProjectile.cs @@ -55,6 +55,11 @@ namespace CalamityMod.Projectiles.Rogue public override bool? CanDamage() => (flung && tileHits == 0 ? null : false); public override void AI() { + if (Owner.dead && !flung) + { + Projectile.Kill(); + return; + } // The main color shifting float rate = (Main.GlobalTimeWrappedHourly * 6); List eColors = new List() diff --git a/Projectiles/Rogue/ExorcismProj.cs b/Projectiles/Rogue/ExorcismProj.cs index 86e4795ad8..80d124066f 100644 --- a/Projectiles/Rogue/ExorcismProj.cs +++ b/Projectiles/Rogue/ExorcismProj.cs @@ -55,6 +55,11 @@ namespace CalamityMod.Projectiles.Rogue public override bool? CanDamage() => ((flung && !inSky && !hitTiles && impaleDist == Vector2.Zero) ? null : false); public override void AI() { + if (Owner.dead && !flung) + { + Projectile.Kill(); + return; + } if (stealth && Projectile.ai[2] != 5) // Multiplayer Syncing? { Projectile.ai[2] = 5; @@ -426,6 +431,7 @@ namespace CalamityMod.Projectiles.Rogue Color glowColor = Color.Lerp(mainColor, Color.Khaki, glowUp - 1); Texture2D tex = TextureAssets.Projectile[Type].Value; Asset glowBlade = ModContent.Request("CalamityMod/Particles/GlowBlade"); + Asset glowBottom = ModContent.Request("CalamityMod/Particles/SquareRotated"); Asset woosh = ModContent.Request("CalamityMod/Particles/VerticalSmearLarge"); if (hitTiles || falling || stealth) @@ -453,6 +459,9 @@ namespace CalamityMod.Projectiles.Rogue for (int y = 0; y < 2; y++) Main.EntitySpriteDraw(glowBlade.Value, fxPos - Main.screenPosition, null, (y != 0 ? Color.White : mainColor) with { A = 0 } * (0.3f * glowUp), fxVel.ToRotation() + MathHelper.PiOver2, glowBlade.Size() / 2f, new Vector2(0.4f * (y != 0 ? 0.65f : 1f), 1f * throwCompletion * glowUp * (i == 0 ? 1.5f : 1)) * Projectile.scale * 0.04f, SpriteEffects.None, 0); + float softGlowUp = (float)Math.Pow(glowUp, 0.15f); + for (int y = 0; y < 3; y++) + Main.EntitySpriteDraw(glowBottom.Value, fxPos - Main.screenPosition - fxVel * 0.55f, null, (y != 0 ? Color.White : mainColor) with { A = 0 } * (0.1f * glowUp), fxVel.ToRotation() + MathHelper.PiOver2, glowBottom.Size() / 2f, new Vector2(1f * (y != 0 ? 0.65f : 1f) * softGlowUp, 1.7f * throwCompletion * softGlowUp * (i == 0 ? 1.5f : 1)) * Projectile.scale * (y == 2 ? 0.3f : 0.25f), SpriteEffects.None, 0); } }