diff --git a/NPCs/Yharon/Yharon.cs b/NPCs/Yharon/Yharon.cs index 51db4b46fb..b9e4c6216d 100644 --- a/NPCs/Yharon/Yharon.cs +++ b/NPCs/Yharon/Yharon.cs @@ -1566,12 +1566,12 @@ namespace CalamityMod.NPCs.Yharon { npc.dontTakeDamage = phase5Check; npc.chaseable = false; - if (npc.alpha < 255) + if (npc.alpha < 225) { npc.alpha += 25; - if (npc.alpha > 255) + if (npc.alpha > 225) { - npc.alpha = 255; + npc.alpha = 225; } } if (npc.ai[1] == 0f) @@ -1704,12 +1704,12 @@ namespace CalamityMod.NPCs.Yharon { npc.dontTakeDamage = true; npc.chaseable = false; - if (npc.alpha < 255) + if (npc.alpha < 225) { npc.alpha += 17; - if (npc.alpha > 255) + if (npc.alpha > 225) { - npc.alpha = 255; + npc.alpha = 225; } } npc.velocity *= 0.98f; diff --git a/Projectiles/Melee/BiomeOrb.cs b/Projectiles/Melee/BiomeOrb.cs index 0248efd731..96af722566 100644 --- a/Projectiles/Melee/BiomeOrb.cs +++ b/Projectiles/Melee/BiomeOrb.cs @@ -1,97 +1,150 @@ using CalamityMod.Buffs.DamageOverTime; using CalamityMod.Buffs.StatDebuffs; using Microsoft.Xna.Framework; +using Microsoft.Xna.Framework.Graphics; using Terraria; using Terraria.ID; using Terraria.ModLoader; + namespace CalamityMod.Projectiles.Melee { public class BiomeOrb : ModProjectile { + private int dustType = 3; + Color color = default; + public override void SetStaticDefaults() { DisplayName.SetDefault("Biome Orb"); - } + ProjectileID.Sets.TrailCacheLength[projectile.type] = 2; + ProjectileID.Sets.TrailingMode[projectile.type] = 0; + } public override void SetDefaults() { - projectile.width = 6; - projectile.height = 6; - projectile.friendly = true; - projectile.alpha = 255; + projectile.width = 20; + projectile.height = 20; + projectile.aiStyle = 27; + aiType = 156; + projectile.friendly = true; projectile.penetrate = 1; projectile.timeLeft = 300; projectile.melee = true; } - public override void AI() - { - Player player = Main.player[projectile.owner]; - bool jungle = player.ZoneJungle; - bool snow = player.ZoneSnow; - bool beach = player.ZoneBeach; - bool corrupt = player.ZoneCorrupt; - bool crimson = player.ZoneCrimson; - bool dungeon = player.ZoneDungeon; - bool desert = player.ZoneDesert; - bool glow = player.ZoneGlowshroom; - bool hell = player.ZoneUnderworldHeight; - bool sky = player.ZoneSkyHeight; - int dustType; - if (jungle) - { - dustType = 39; - } - else if (snow) - { - dustType = 51; - } - else if (beach) - { - dustType = 33; - } - else if (corrupt) - { - dustType = 14; - } - else if (crimson) - { - dustType = 5; - } - else if (dungeon) - { - dustType = 29; - } - else if (desert) - { - dustType = 32; - } - else if (glow) - { - dustType = 56; - } - else if (hell) - { - dustType = 6; - } - else if (sky) - { - dustType = 213; - } - else - { - dustType = 3; - } - for (int num457 = 0; num457 < 5; num457++) - { - int num458 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, dustType, 0f, 0f, 100, default, 1.2f); - Main.dust[num458].noGravity = true; - Main.dust[num458].velocity *= 0.5f; - Main.dust[num458].velocity += projectile.velocity * 0.1f; - } - } + public override void AI() + { + Player player = Main.player[projectile.owner]; + bool jungle = player.ZoneJungle; + bool snow = player.ZoneSnow; + bool beach = player.ZoneBeach; + bool corrupt = player.ZoneCorrupt; + bool crimson = player.ZoneCrimson; + bool dungeon = player.ZoneDungeon; + bool desert = player.ZoneDesert; + bool glow = player.ZoneGlowshroom; + bool hell = player.ZoneUnderworldHeight; + bool sky = player.ZoneSkyHeight; + bool holy = player.ZoneHoly; + if (jungle) + { + dustType = 39; + color = new Color(128, 255, 128, projectile.alpha); + } + else if (snow) + { + dustType = 51; + color = new Color(128, 255, 255, projectile.alpha); + } + else if (beach) + { + dustType = 33; + color = new Color(0, 0, 128, projectile.alpha); + } + else if (corrupt) + { + dustType = 14; + color = new Color(128, 64, 255, projectile.alpha); + } + else if (crimson) + { + dustType = 5; + color = new Color(128, 0, 0, projectile.alpha); + } + else if (dungeon) + { + dustType = 29; + color = new Color(64, 0, 128, projectile.alpha); + } + else if (desert) + { + dustType = 32; + color = new Color(255, 255, 128, projectile.alpha); + } + else if (glow) + { + dustType = 56; + color = new Color(0, 255, 255, projectile.alpha); + } + else if (hell) + { + dustType = 6; + color = new Color(255, 128, 0, projectile.alpha); + } + else if (sky) + { + dustType = 213; + color = new Color(255, 255, 255, projectile.alpha); + } + else if (holy) + { + dustType = 57; + color = new Color(255, 255, 0, projectile.alpha); + } + else + { + color = new Color(0, 128, 0, projectile.alpha); + } + int num458 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, dustType, 0f, 0f, 100, default, 0.9f); + Main.dust[num458].noGravity = true; + Main.dust[num458].velocity *= 0.5f; + Main.dust[num458].velocity += projectile.velocity * 0.1f; + } - public override void OnHitNPC(NPC target, int damage, float knockback, bool crit) + public override Color? GetAlpha(Color lightColor) + { + return color; + } + + public override bool PreDraw(SpriteBatch spriteBatch, Color lightColor) + { + if (projectile.timeLeft > 295) + return false; + + CalamityGlobalProjectile.DrawCenteredAndAfterimage(projectile, lightColor, ProjectileID.Sets.TrailingMode[projectile.type], 1); + return false; + } + + public override void Kill(int timeLeft) + { + Main.PlaySound(SoundID.Item10, projectile.position); + int num3; + for (int num795 = 4; num795 < 31; num795 = num3 + 1) + { + float num796 = projectile.oldVelocity.X * (30f / (float)num795); + float num797 = projectile.oldVelocity.Y * (30f / (float)num795); + int num798 = Dust.NewDust(new Vector2(projectile.oldPosition.X - num796, projectile.oldPosition.Y - num797), 8, 8, dustType, projectile.oldVelocity.X, projectile.oldVelocity.Y, 100, default, 1.8f); + Main.dust[num798].noGravity = true; + Dust dust = Main.dust[num798]; + dust.velocity *= 0.5f; + num798 = Dust.NewDust(new Vector2(projectile.oldPosition.X - num796, projectile.oldPosition.Y - num797), 8, 8, dustType, projectile.oldVelocity.X, projectile.oldVelocity.Y, 100, default, 1.4f); + dust = Main.dust[num798]; + dust.velocity *= 0.05f; + num3 = num795; + } + } + + public override void OnHitNPC(NPC target, int damage, float knockback, bool crit) { Player player = Main.player[projectile.owner]; bool jungle = player.ZoneJungle; @@ -101,7 +154,8 @@ namespace CalamityMod.Projectiles.Melee bool desert = player.ZoneDesert; bool glow = player.ZoneGlowshroom; bool hell = player.ZoneUnderworldHeight; - if (jungle) + bool holy = player.ZoneHoly; + if (jungle) { target.AddBuff(ModContent.BuffType(), 180); } @@ -129,7 +183,11 @@ namespace CalamityMod.Projectiles.Melee { target.AddBuff(ModContent.BuffType(), 180); } - else + else if (holy) + { + target.AddBuff(ModContent.BuffType(), 180); + } + else { target.AddBuff(ModContent.BuffType(), 180); } diff --git a/Projectiles/Melee/BiomeOrb.png b/Projectiles/Melee/BiomeOrb.png index a3192f9461..9e55e98a87 100644 Binary files a/Projectiles/Melee/BiomeOrb.png and b/Projectiles/Melee/BiomeOrb.png differ diff --git a/Projectiles/Melee/OmegaBiomeOrb.cs b/Projectiles/Melee/OmegaBiomeOrb.cs index 7f709b12cd..64de8a73de 100644 --- a/Projectiles/Melee/OmegaBiomeOrb.cs +++ b/Projectiles/Melee/OmegaBiomeOrb.cs @@ -1,156 +1,209 @@ using CalamityMod.Buffs.DamageOverTime; using CalamityMod.Buffs.StatDebuffs; using Microsoft.Xna.Framework; +using Microsoft.Xna.Framework.Graphics; using System; using Terraria; using Terraria.ID; using Terraria.ModLoader; + namespace CalamityMod.Projectiles.Melee { public class OmegaBiomeOrb : ModProjectile { - public override void SetStaticDefaults() + private int dustType = 3; + Color color = default; + + public override void SetStaticDefaults() { - DisplayName.SetDefault("Orb"); - } + DisplayName.SetDefault("Omega Biome Orb"); + ProjectileID.Sets.TrailCacheLength[projectile.type] = 6; + ProjectileID.Sets.TrailingMode[projectile.type] = 0; + } public override void SetDefaults() { - projectile.width = 10; - projectile.height = 10; - projectile.friendly = true; - projectile.alpha = 255; + projectile.width = 20; + projectile.height = 20; + projectile.aiStyle = 27; + aiType = 156; + projectile.friendly = true; projectile.penetrate = 1; projectile.timeLeft = 240; projectile.melee = true; } - public override void AI() - { - Player player = Main.player[projectile.owner]; - bool jungle = player.ZoneJungle; - bool snow = player.ZoneSnow; - bool beach = player.ZoneBeach; - bool corrupt = player.ZoneCorrupt; - bool crimson = player.ZoneCrimson; - bool dungeon = player.ZoneDungeon; - bool desert = player.ZoneDesert; - bool glow = player.ZoneGlowshroom; - bool hell = player.ZoneUnderworldHeight; - bool sky = player.ZoneSkyHeight; - bool holy = player.ZoneHoly; - bool nebula = player.ZoneTowerNebula; - bool stardust = player.ZoneTowerStardust; - bool solar = player.ZoneTowerSolar; - bool vortex = player.ZoneTowerVortex; - int dustType; - if (jungle) - { - dustType = 39; - } - else if (snow) - { - dustType = 51; - } - else if (beach) - { - dustType = 33; - } - else if (corrupt) - { - dustType = 14; - } - else if (crimson) - { - dustType = 5; - } - else if (dungeon) - { - dustType = 29; - } - else if (desert) - { - dustType = 32; - } - else if (glow) - { - dustType = 56; - } - else if (hell) - { - dustType = 6; - } - else if (sky) - { - dustType = 213; - } - else if (holy) - { - dustType = 57; - } - else if (nebula) - { - dustType = 242; - } - else if (stardust) - { - dustType = 206; - } - else if (solar) - { - dustType = 244; - } - else if (vortex) - { - dustType = 107; - } - else - { - dustType = 3; - } - for (int num457 = 0; num457 < 5; num457++) - { - int num458 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, dustType, 0f, 0f, 100, default, 1.2f); - Main.dust[num458].noGravity = true; - Main.dust[num458].velocity *= 0.5f; - Main.dust[num458].velocity += projectile.velocity * 0.1f; - } - float num472 = projectile.Center.X; - float num473 = projectile.Center.Y; - float num474 = 400f; - bool flag17 = false; - for (int num475 = 0; num475 < 200; num475++) - { - if (Main.npc[num475].CanBeChasedBy(projectile, false) && Collision.CanHit(projectile.Center, 1, 1, Main.npc[num475].Center, 1, 1)) - { - float num476 = Main.npc[num475].position.X + (float)(Main.npc[num475].width / 2); - float num477 = Main.npc[num475].position.Y + (float)(Main.npc[num475].height / 2); - float num478 = Math.Abs(projectile.position.X + (float)(projectile.width / 2) - num476) + Math.Abs(projectile.position.Y + (float)(projectile.height / 2) - num477); - if (num478 < num474) - { - num474 = num478; - num472 = num476; - num473 = num477; - flag17 = true; - } - } - } - if (flag17) - { - float num483 = 15f; - Vector2 vector35 = new Vector2(projectile.position.X + (float)projectile.width * 0.5f, projectile.position.Y + (float)projectile.height * 0.5f); - float num484 = num472 - vector35.X; - float num485 = num473 - vector35.Y; - float num486 = (float)Math.Sqrt((double)(num484 * num484 + num485 * num485)); - num486 = num483 / num486; - num484 *= num486; - num485 *= num486; - projectile.velocity.X = (projectile.velocity.X * 20f + num484) / 21f; - projectile.velocity.Y = (projectile.velocity.Y * 20f + num485) / 21f; - } - } + public override void AI() + { + Player player = Main.player[projectile.owner]; + bool jungle = player.ZoneJungle; + bool snow = player.ZoneSnow; + bool beach = player.ZoneBeach; + bool corrupt = player.ZoneCorrupt; + bool crimson = player.ZoneCrimson; + bool dungeon = player.ZoneDungeon; + bool desert = player.ZoneDesert; + bool glow = player.ZoneGlowshroom; + bool hell = player.ZoneUnderworldHeight; + bool sky = player.ZoneSkyHeight; + bool holy = player.ZoneHoly; + bool nebula = player.ZoneTowerNebula; + bool stardust = player.ZoneTowerStardust; + bool solar = player.ZoneTowerSolar; + bool vortex = player.ZoneTowerVortex; + if (jungle) + { + dustType = 39; + color = new Color(128, 255, 128, projectile.alpha); + } + else if (snow) + { + dustType = 51; + color = new Color(128, 255, 255, projectile.alpha); + } + else if (beach) + { + dustType = 33; + color = new Color(0, 0, 128, projectile.alpha); + } + else if (corrupt) + { + dustType = 14; + color = new Color(128, 64, 255, projectile.alpha); + } + else if (crimson) + { + dustType = 5; + color = new Color(128, 0, 0, projectile.alpha); + } + else if (dungeon) + { + dustType = 29; + color = new Color(64, 0, 128, projectile.alpha); + } + else if (desert) + { + dustType = 32; + color = new Color(255, 255, 128, projectile.alpha); + } + else if (glow) + { + dustType = 56; + color = new Color(0, 255, 255, projectile.alpha); + } + else if (hell) + { + dustType = 6; + color = new Color(255, 128, 0, projectile.alpha); + } + else if (sky) + { + dustType = 213; + color = new Color(255, 255, 255, projectile.alpha); + } + else if (holy) + { + dustType = 57; + color = new Color(255, 255, 0, projectile.alpha); + } + else if (nebula) + { + dustType = 242; + color = new Color(255, 0, 255, projectile.alpha); + } + else if (stardust) + { + dustType = 206; + color = new Color(0, 255, 255, projectile.alpha); + } + else if (solar) + { + dustType = 244; + color = new Color(255, 128, 0, projectile.alpha); + } + else if (vortex) + { + dustType = 107; + color = new Color(0, 255, 0, projectile.alpha); + } + else + { + color = new Color(0, 128, 0, projectile.alpha); + } + int num458 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, dustType, 0f, 0f, 100, default, 1.2f); + Main.dust[num458].noGravity = true; + Main.dust[num458].velocity *= 0.5f; + Main.dust[num458].velocity += projectile.velocity * 0.1f; - public override void OnHitNPC(NPC target, int damage, float knockback, bool crit) + float num472 = projectile.Center.X; + float num473 = projectile.Center.Y; + float num474 = 400f; + bool flag17 = false; + for (int num475 = 0; num475 < 200; num475++) + { + if (Main.npc[num475].CanBeChasedBy(projectile, false) && Collision.CanHit(projectile.Center, 1, 1, Main.npc[num475].Center, 1, 1)) + { + float num476 = Main.npc[num475].position.X + (float)(Main.npc[num475].width / 2); + float num477 = Main.npc[num475].position.Y + (float)(Main.npc[num475].height / 2); + float num478 = Math.Abs(projectile.position.X + (float)(projectile.width / 2) - num476) + Math.Abs(projectile.position.Y + (float)(projectile.height / 2) - num477); + if (num478 < num474) + { + num474 = num478; + num472 = num476; + num473 = num477; + flag17 = true; + } + } + } + if (flag17) + { + float num483 = 15f; + Vector2 vector35 = new Vector2(projectile.position.X + (float)projectile.width * 0.5f, projectile.position.Y + (float)projectile.height * 0.5f); + float num484 = num472 - vector35.X; + float num485 = num473 - vector35.Y; + float num486 = (float)Math.Sqrt((double)(num484 * num484 + num485 * num485)); + num486 = num483 / num486; + num484 *= num486; + num485 *= num486; + projectile.velocity.X = (projectile.velocity.X * 20f + num484) / 21f; + projectile.velocity.Y = (projectile.velocity.Y * 20f + num485) / 21f; + } + } + + public override Color? GetAlpha(Color lightColor) + { + return color; + } + + public override bool PreDraw(SpriteBatch spriteBatch, Color lightColor) + { + if (projectile.timeLeft > 235) + return false; + + CalamityGlobalProjectile.DrawCenteredAndAfterimage(projectile, lightColor, ProjectileID.Sets.TrailingMode[projectile.type], 1); + return false; + } + + public override void Kill(int timeLeft) + { + Main.PlaySound(SoundID.Item10, projectile.position); + int num3; + for (int num795 = 4; num795 < 31; num795 = num3 + 1) + { + float num796 = projectile.oldVelocity.X * (30f / (float)num795); + float num797 = projectile.oldVelocity.Y * (30f / (float)num795); + int num798 = Dust.NewDust(new Vector2(projectile.oldPosition.X - num796, projectile.oldPosition.Y - num797), 8, 8, dustType, projectile.oldVelocity.X, projectile.oldVelocity.Y, 100, default, 1.8f); + Main.dust[num798].noGravity = true; + Dust dust = Main.dust[num798]; + dust.velocity *= 0.5f; + num798 = Dust.NewDust(new Vector2(projectile.oldPosition.X - num796, projectile.oldPosition.Y - num797), 8, 8, dustType, projectile.oldVelocity.X, projectile.oldVelocity.Y, 100, default, 1.4f); + dust = Main.dust[num798]; + dust.velocity *= 0.05f; + num3 = num795; + } + } + + public override void OnHitNPC(NPC target, int damage, float knockback, bool crit) { Player player = Main.player[projectile.owner]; bool jungle = player.ZoneJungle; diff --git a/Projectiles/Melee/OmegaBiomeOrb.png b/Projectiles/Melee/OmegaBiomeOrb.png index ead80128fa..9e55e98a87 100644 Binary files a/Projectiles/Melee/OmegaBiomeOrb.png and b/Projectiles/Melee/OmegaBiomeOrb.png differ diff --git a/Projectiles/Melee/TrueBiomeOrb.cs b/Projectiles/Melee/TrueBiomeOrb.cs index c60dd388cc..57fc9340d6 100644 --- a/Projectiles/Melee/TrueBiomeOrb.cs +++ b/Projectiles/Melee/TrueBiomeOrb.cs @@ -1,103 +1,150 @@ using CalamityMod.Buffs.DamageOverTime; using CalamityMod.Buffs.StatDebuffs; using Microsoft.Xna.Framework; +using Microsoft.Xna.Framework.Graphics; using Terraria; using Terraria.ID; using Terraria.ModLoader; + namespace CalamityMod.Projectiles.Melee { public class TrueBiomeOrb : ModProjectile { - public override void SetStaticDefaults() + private int dustType = 3; + Color color = default; + + public override void SetStaticDefaults() { - DisplayName.SetDefault("Orb"); - } + DisplayName.SetDefault("True Biome Orb"); + ProjectileID.Sets.TrailCacheLength[projectile.type] = 4; + ProjectileID.Sets.TrailingMode[projectile.type] = 0; + } public override void SetDefaults() { - projectile.width = 8; - projectile.height = 8; - projectile.friendly = true; - projectile.alpha = 255; + projectile.width = 20; + projectile.height = 20; + projectile.aiStyle = 27; + aiType = 156; + projectile.friendly = true; projectile.penetrate = 1; projectile.timeLeft = 300; projectile.melee = true; } - public override void AI() - { - Player player = Main.player[projectile.owner]; - bool jungle = player.ZoneJungle; - bool snow = player.ZoneSnow; - bool beach = player.ZoneBeach; - bool corrupt = player.ZoneCorrupt; - bool crimson = player.ZoneCrimson; - bool dungeon = player.ZoneDungeon; - bool desert = player.ZoneDesert; - bool glow = player.ZoneGlowshroom; - bool hell = player.ZoneUnderworldHeight; - bool sky = player.ZoneSkyHeight; - bool holy = player.ZoneHoly; - int dustType; - if (jungle) - { - dustType = 39; - } - else if (snow) - { - dustType = 51; - } - else if (beach) - { - dustType = 33; - } - else if (corrupt) - { - dustType = 14; - } - else if (crimson) - { - dustType = 5; - } - else if (dungeon) - { - dustType = 29; - } - else if (desert) - { - dustType = 32; - } - else if (glow) - { - dustType = 56; - } - else if (hell) - { - dustType = 6; - } - else if (sky) - { - dustType = 213; - } - else if (holy) - { - dustType = 57; - } - else - { - dustType = 3; - } - for (int num457 = 0; num457 < 10; num457++) - { - int num458 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, dustType, 0f, 0f, 100, default, 1.2f); - Main.dust[num458].noGravity = true; - Main.dust[num458].velocity *= 0.5f; - Main.dust[num458].velocity += projectile.velocity * 0.1f; - } - return; - } + public override void AI() + { + Player player = Main.player[projectile.owner]; + bool jungle = player.ZoneJungle; + bool snow = player.ZoneSnow; + bool beach = player.ZoneBeach; + bool corrupt = player.ZoneCorrupt; + bool crimson = player.ZoneCrimson; + bool dungeon = player.ZoneDungeon; + bool desert = player.ZoneDesert; + bool glow = player.ZoneGlowshroom; + bool hell = player.ZoneUnderworldHeight; + bool sky = player.ZoneSkyHeight; + bool holy = player.ZoneHoly; + if (jungle) + { + dustType = 39; + color = new Color(128, 255, 128, projectile.alpha); + } + else if (snow) + { + dustType = 51; + color = new Color(128, 255, 255, projectile.alpha); + } + else if (beach) + { + dustType = 33; + color = new Color(0, 0, 128, projectile.alpha); + } + else if (corrupt) + { + dustType = 14; + color = new Color(128, 64, 255, projectile.alpha); + } + else if (crimson) + { + dustType = 5; + color = new Color(128, 0, 0, projectile.alpha); + } + else if (dungeon) + { + dustType = 29; + color = new Color(64, 0, 128, projectile.alpha); + } + else if (desert) + { + dustType = 32; + color = new Color(255, 255, 128, projectile.alpha); + } + else if (glow) + { + dustType = 56; + color = new Color(0, 255, 255, projectile.alpha); + } + else if (hell) + { + dustType = 6; + color = new Color(255, 128, 0, projectile.alpha); + } + else if (sky) + { + dustType = 213; + color = new Color(255, 255, 255, projectile.alpha); + } + else if (holy) + { + dustType = 57; + color = new Color(255, 255, 0, projectile.alpha); + } + else + { + color = new Color(0, 128, 0, projectile.alpha); + } + int num458 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, dustType, 0f, 0f, 100, default, 1.2f); + Main.dust[num458].noGravity = true; + Main.dust[num458].velocity *= 0.5f; + Main.dust[num458].velocity += projectile.velocity * 0.1f; + } - public override void OnHitNPC(NPC target, int damage, float knockback, bool crit) + public override Color? GetAlpha(Color lightColor) + { + return color; + } + + public override bool PreDraw(SpriteBatch spriteBatch, Color lightColor) + { + if (projectile.timeLeft > 295) + return false; + + CalamityGlobalProjectile.DrawCenteredAndAfterimage(projectile, lightColor, ProjectileID.Sets.TrailingMode[projectile.type], 1); + return false; + } + + public override void Kill(int timeLeft) + { + Main.PlaySound(SoundID.Item10, projectile.position); + int num3; + for (int num795 = 4; num795 < 31; num795 = num3 + 1) + { + float num796 = projectile.oldVelocity.X * (30f / (float)num795); + float num797 = projectile.oldVelocity.Y * (30f / (float)num795); + int num798 = Dust.NewDust(new Vector2(projectile.oldPosition.X - num796, projectile.oldPosition.Y - num797), 8, 8, dustType, projectile.oldVelocity.X, projectile.oldVelocity.Y, 100, default, 1.8f); + Main.dust[num798].noGravity = true; + Dust dust = Main.dust[num798]; + dust.velocity *= 0.5f; + num798 = Dust.NewDust(new Vector2(projectile.oldPosition.X - num796, projectile.oldPosition.Y - num797), 8, 8, dustType, projectile.oldVelocity.X, projectile.oldVelocity.Y, 100, default, 1.4f); + dust = Main.dust[num798]; + dust.velocity *= 0.05f; + num3 = num795; + } + } + + public override void OnHitNPC(NPC target, int damage, float knockback, bool crit) { Player player = Main.player[projectile.owner]; bool jungle = player.ZoneJungle; diff --git a/Projectiles/Melee/TrueBiomeOrb.png b/Projectiles/Melee/TrueBiomeOrb.png index 0056fc1e24..9e55e98a87 100644 Binary files a/Projectiles/Melee/TrueBiomeOrb.png and b/Projectiles/Melee/TrueBiomeOrb.png differ diff --git a/Projectiles/Typeless/KelvinCatalystBoomerang.cs b/Projectiles/Typeless/KelvinCatalystBoomerang.cs index 6449106602..c271548fa1 100644 --- a/Projectiles/Typeless/KelvinCatalystBoomerang.cs +++ b/Projectiles/Typeless/KelvinCatalystBoomerang.cs @@ -142,7 +142,7 @@ namespace CalamityMod.Projectiles.Typeless public override void OnHitNPC(NPC target, int damage, float knockback, bool crit) { target.AddBuff(BuffID.Frostburn, 240); - if (projectile.owner == Main.myPlayer) + if (projectile.owner == Main.myPlayer && Main.player[projectile.owner].ownedProjectileCounts[ModContent.ProjectileType()] < 25) { float spread = 45f * 0.0174f; double startAngle = Math.Atan2(projectile.velocity.X, projectile.velocity.Y) - spread / 2; diff --git a/Tiles/Ores/PerennialOre.png b/Tiles/Ores/PerennialOre.png index e381504d28..6e61b27a38 100644 Binary files a/Tiles/Ores/PerennialOre.png and b/Tiles/Ores/PerennialOre.png differ diff --git a/build.txt b/build.txt index 72550e95f1..49dce9b7a5 100644 --- a/build.txt +++ b/build.txt @@ -1,4 +1,4 @@ -author = MountainDrew +author = Fabsol and the Dev Team version = 1.4.2.108 displayName = Calamity Mod (No Calamity Music) homepage = https://forums.terraria.org/index.php?threads/calamity-mod.44065/