Fixed several Eidolon Staff issues
added challenge drop label damage and knockback now scale properly with bonuses
This commit is contained in:
1 parent
a36f6fbbaa
commit
7d877b98f9
1 file changed
+10
-14
@@ -35,35 +35,31 @@ namespace CalamityMod.Items.Weapons.Magic
|
||||
item.autoReuse = true;
|
||||
item.shoot = ModContent.ProjectileType<Starblast>();
|
||||
item.shootSpeed = 12f;
|
||||
item.Calamity().challengeDrop = true;
|
||||
}
|
||||
|
||||
public override Vector2? HoldoutOrigin()
|
||||
{
|
||||
return new Vector2(15, 15);
|
||||
}
|
||||
public override Vector2? HoldoutOrigin() => new Vector2(15, 15);
|
||||
|
||||
public override bool Shoot(Player player, ref Vector2 position, ref float speedX, ref float speedY, ref int type, ref int damage, ref float knockBack)
|
||||
{
|
||||
Vector2 vector2 = player.RotatedRelativePoint(player.MountedCenter, true);
|
||||
int i = Main.myPlayer;
|
||||
float num72 = item.shootSpeed;
|
||||
int num73 = item.damage;
|
||||
float num74 = item.knockBack;
|
||||
float num78 = (float)Main.mouseX + Main.screenPosition.X - vector2.X;
|
||||
float num79 = (float)Main.mouseY + Main.screenPosition.Y - vector2.Y;
|
||||
float num80 = (float)Math.Sqrt((double)(num78 * num78 + num79 * num79));
|
||||
int num130 = 6;
|
||||
int stardustAmt = 6;
|
||||
if (Main.rand.NextBool(3))
|
||||
{
|
||||
num130++;
|
||||
stardustAmt++;
|
||||
}
|
||||
if (Main.rand.NextBool(4))
|
||||
{
|
||||
num130++;
|
||||
stardustAmt++;
|
||||
}
|
||||
if (Main.rand.NextBool(5))
|
||||
{
|
||||
num130++;
|
||||
stardustAmt++;
|
||||
}
|
||||
if (Main.rand.NextBool(3))
|
||||
{
|
||||
@@ -75,15 +71,15 @@ namespace CalamityMod.Items.Weapons.Magic
|
||||
num133 *= num80;
|
||||
float x2 = vector2.X;
|
||||
float y2 = vector2.Y;
|
||||
Projectile.NewProjectile(x2, y2, num132, num133, ModContent.ProjectileType<IceCluster>(), num73, num74, i, 0f, 1f);
|
||||
Projectile.NewProjectile(x2, y2, num132, num133, ModContent.ProjectileType<IceCluster>(), damage, knockBack, i, 0f, 1f);
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int num131 = 0; num131 < num130; num131++)
|
||||
for (int i = 0; i < stardustAmt; i++)
|
||||
{
|
||||
float num132 = num78;
|
||||
float num133 = num79;
|
||||
float num134 = 0.05f * (float)num131;
|
||||
float num134 = 0.05f * (float)i;
|
||||
num132 += (float)Main.rand.Next(-155, 156) * num134;
|
||||
num133 += (float)Main.rand.Next(-155, 156) * num134;
|
||||
num80 = (float)Math.Sqrt((double)(num132 * num132 + num133 * num133));
|
||||
@@ -92,7 +88,7 @@ namespace CalamityMod.Items.Weapons.Magic
|
||||
num133 *= num80;
|
||||
float x2 = vector2.X;
|
||||
float y2 = vector2.Y;
|
||||
Projectile.NewProjectile(x2, y2, num132, num133, ModContent.ProjectileType<Starblast>(), num73, num74, i, 0f, 0f);
|
||||
Projectile.NewProjectile(x2, y2, num132, num133, ModContent.ProjectileType<Starblast>(), damage, knockBack, i, 0f, 0f);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
|
||||
Reference in new issue
Block a user