using CalamityMod.Items.Materials; using CalamityMod.Projectiles.Melee.Spears; using CalamityMod.Rarities; using CalamityMod.Tiles.Furniture.CraftingStations; using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Graphics; using Terraria; using Terraria.ID; using Terraria.ModLoader; namespace CalamityMod.Items.Weapons.Melee { public class StreamGouge : ModItem, ILocalizedModType { public new string LocalizationCategory => "Items.Weapons.Melee"; public const int SpinTime = 45; public const int SpearFireTime = 24; public const int PortalLifetime = 30; public override void SetDefaults() { Item.width = 100; Item.height = 100; Item.damage = 440; Item.DamageType = DamageClass.Melee; Item.noMelee = true; Item.useTurn = true; Item.noUseGraphic = true; Item.channel = true; Item.useAnimation = 19; Item.useTime = 19; Item.useStyle = ItemUseStyleID.Shoot; Item.knockBack = 9.75f; Item.UseSound = SoundID.Item20; Item.autoReuse = true; Item.value = CalamityGlobalItem.RarityDarkBlueBuyPrice; Item.shoot = ModContent.ProjectileType(); Item.shootSpeed = 15f; Item.rare = ModContent.RarityType(); } public override void PostDrawInWorld(SpriteBatch spriteBatch, Color lightColor, Color alphaColor, float rotation, float scale, int whoAmI) { Item.DrawItemGlowmaskSingleFrame(spriteBatch, rotation, ModContent.Request("CalamityMod/Items/Weapons/Melee/StreamGougeGlow").Value); } public override bool CanUseItem(Player player) => player.ownedProjectileCounts[Item.shoot] <= 0; public override void AddRecipes() { CreateRecipe(). AddIngredient(12). AddTile(). Register(); } } }