65 lines
2.0 KiB
C#
65 lines
2.0 KiB
C#
using CalamityMod.Items.Materials;
|
|
using CalamityMod.Projectiles.Melee.Yoyos;
|
|
using CalamityMod.Rarities;
|
|
using CalamityMod.Tiles.Furniture.CraftingStations;
|
|
using Terraria.ID;
|
|
using Terraria.Localization;
|
|
using Terraria.ModLoader;
|
|
|
|
namespace CalamityMod.Items.Weapons.Melee
|
|
{
|
|
[LegacyName("Oracle")]
|
|
public class TheOracle : ModItem, ILocalizedModType
|
|
{
|
|
public new string LocalizationCategory => "Items.Weapons.Melee";
|
|
public const float AuraBaseDamageMult = 0.35f;
|
|
public const float AuraMaxDamageMult = 0.8f;
|
|
|
|
public static float Reach = 800f;
|
|
public static float Speed = 60f;
|
|
public override LocalizedText Tooltip => base.Tooltip.WithFormatArgs(Reach.ToTiles(), Speed);
|
|
|
|
public override void SetStaticDefaults()
|
|
{
|
|
ItemID.Sets.Yoyo[Type] = true;
|
|
ItemID.Sets.GamepadExtraRange[Type] = 15;
|
|
ItemID.Sets.GamepadSmartQuickReach[Type] = true;
|
|
}
|
|
|
|
public override void SetDefaults()
|
|
{
|
|
Item.width = 58;
|
|
Item.height = 50;
|
|
Item.DamageType = DamageClass.MeleeNoSpeed;
|
|
Item.damage = 201;
|
|
Item.knockBack = 4f;
|
|
Item.useTime = 20;
|
|
Item.useAnimation = 20;
|
|
Item.autoReuse = true;
|
|
|
|
Item.useStyle = ItemUseStyleID.Shoot;
|
|
Item.UseSound = SoundID.Item1;
|
|
Item.channel = true;
|
|
Item.noUseGraphic = true;
|
|
Item.noMelee = true;
|
|
|
|
Item.shoot = ModContent.ProjectileType<OracleYoyo>();
|
|
Item.shootSpeed = 16f;
|
|
|
|
Item.value = CalamityGlobalItem.RarityVioletBuyPrice;
|
|
Item.rare = ModContent.RarityType<BurnishedAuric>();
|
|
Item.Calamity().donorItem = true;
|
|
}
|
|
|
|
public override void AddRecipes()
|
|
{
|
|
CreateRecipe().
|
|
AddIngredient<BurningRevelation>().
|
|
AddIngredient<TheObliterator>().
|
|
AddIngredient<AuricBar>(5).
|
|
AddTile<CosmicAnvil>().
|
|
Register();
|
|
}
|
|
}
|
|
}
|