58 lines
2.1 KiB
C#
58 lines
2.1 KiB
C#
using CalamityMod.Items.Materials;
|
|
using CalamityMod.Projectiles.Melee;
|
|
using CalamityMod.Tiles.Furniture.CraftingStations;
|
|
using Terraria;
|
|
using Terraria.ID;
|
|
using Terraria.ModLoader;
|
|
|
|
namespace CalamityMod.Items.Weapons.Rogue
|
|
{
|
|
public class ScourgeoftheCosmosThrown : RogueWeapon
|
|
{
|
|
public override void SetStaticDefaults()
|
|
{
|
|
DisplayName.SetDefault("Scourge of the Cosmos");
|
|
Tooltip.SetDefault("Throws a bouncing cosmic scourge that emits tiny homing cosmic scourges on death and tile hits");
|
|
}
|
|
|
|
public override void SafeSetDefaults()
|
|
{
|
|
item.width = 18;
|
|
item.damage = 2200;
|
|
item.noMelee = true;
|
|
item.noUseGraphic = true;
|
|
item.useAnimation = 20;
|
|
item.useStyle = 5;
|
|
item.useTime = 20;
|
|
item.knockBack = 5f;
|
|
item.UseSound = SoundID.Item109;
|
|
item.autoReuse = true;
|
|
item.height = 20;
|
|
item.value = Item.buyPrice(1, 80, 0, 0);
|
|
item.rare = 10;
|
|
item.shoot = ModContent.ProjectileType<ScourgeoftheCosmosProj>();
|
|
item.shootSpeed = 15f;
|
|
item.Calamity().rogue = true;
|
|
item.Calamity().postMoonLordRarity = 14;
|
|
}
|
|
|
|
public override bool Shoot(Player player, ref Microsoft.Xna.Framework.Vector2 position, ref float speedX, ref float speedY, ref int type, ref int damage, ref float knockBack)
|
|
{
|
|
Projectile.NewProjectile(position.X, position.Y, speedX, speedY, type, damage, knockBack, player.whoAmI, 0f, 1f);
|
|
return false;
|
|
}
|
|
|
|
public override void AddRecipes()
|
|
{
|
|
ModRecipe recipe = new ModRecipe(mod);
|
|
recipe.AddIngredient(ItemID.ScourgeoftheCorruptor);
|
|
recipe.AddIngredient(ModContent.ItemType<CosmiliteBar>(), 10);
|
|
recipe.AddIngredient(ModContent.ItemType<DarksunFragment>(), 10);
|
|
recipe.AddIngredient(ModContent.ItemType<XerocPitchfork>(), 200);
|
|
recipe.AddTile(ModContent.TileType<DraedonsForge>());
|
|
recipe.SetResult(this);
|
|
recipe.AddRecipe();
|
|
}
|
|
}
|
|
}
|