Clean up all projectile code.

This commit is contained in:
Big Duckie
2022-07-05 22:32:27 -06:00
parent 2b34d060c5
commit 099f0a2e50
73 changed files with 651 additions and 840 deletions
+3 -4
View File
@@ -25,9 +25,8 @@ public class GoldenSpiritArrow : ModProjectile
{
if (Utils.NextFloat(Main.rand) < 0.1f && Projectile.alpha <= 100)
{
int dust = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, ModContent.DustType<Dusts.MeatDust>(), 0f, 0f, 0, default, 1f);
Dust obj = Main.dust[dust];
obj.velocity /= 2f;
int dust = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, ModContent.DustType<Dusts.MeatDust>());
Main.dust[dust].velocity /= 2f;
}
}
@@ -35,7 +34,7 @@ public class GoldenSpiritArrow : ModProjectile
{
for (int i = 0; i < 5; i++)
{
Dust.NewDust(Projectile.position + Projectile.velocity, Projectile.width, Projectile.height, ModContent.DustType<Dusts.MeatDust>(), Projectile.oldVelocity.X * 0.5f, Projectile.oldVelocity.Y * 0.5f, 0, default, 1f);
Dust.NewDust(Projectile.position + Projectile.velocity, Projectile.width, Projectile.height, ModContent.DustType<Dusts.MeatDust>(), Projectile.oldVelocity.X * 0.5f, Projectile.oldVelocity.Y * 0.5f);
}
SoundEngine.PlaySound(SoundID.Item1, Projectile.position);
}