54 lines
1.6 KiB
C#
54 lines
1.6 KiB
C#
using CalamityMod.CalPlayer;
|
|
using CalamityMod.Items.Materials;
|
|
using CalamityMod.Items.Placeables.Plates;
|
|
using CalamityMod.Items.Placeables.Ores;
|
|
using CalamityMod.Rarities;
|
|
using Terraria;
|
|
using Terraria.DataStructures;
|
|
using Terraria.ID;
|
|
using Terraria.ModLoader;
|
|
|
|
namespace CalamityMod.Items.Accessories
|
|
{
|
|
public class ProfanedSoulArtifact : ModItem, ILocalizedModType //My precious babs <3 ~Amber
|
|
{
|
|
public new string LocalizationCategory => "Items.Accessories";
|
|
public override void SetStaticDefaults()
|
|
{
|
|
Main.RegisterItemAnimation(Item.type, new DrawAnimationVertical(6, 6));
|
|
ItemID.Sets.AnimatesAsSoul[Type] = true;
|
|
}
|
|
|
|
public override void SetDefaults()
|
|
{
|
|
Item.width = 32;
|
|
Item.height = 40;
|
|
Item.accessory = true;
|
|
Item.value = CalamityGlobalItem.Rarity12BuyPrice;
|
|
Item.rare = ModContent.RarityType<Turquoise>();
|
|
Item.Calamity().donorItem = true;
|
|
}
|
|
|
|
public override bool CanEquipAccessory(Player player, int slot, bool modded)
|
|
{
|
|
return !player.Calamity().pArtifact;
|
|
}
|
|
|
|
public override void UpdateAccessory(Player player, bool hideVisual)
|
|
{
|
|
CalamityPlayer modPlayer = player.Calamity();
|
|
modPlayer.pArtifact = true;
|
|
}
|
|
|
|
public override void AddRecipes()
|
|
{
|
|
CreateRecipe().
|
|
AddIngredient<ExodiumCluster>(25).
|
|
AddIngredient<Havocplate>(25).
|
|
AddIngredient<DivineGeode>(5).
|
|
AddTile(TileID.DemonAltar).
|
|
Register();
|
|
}
|
|
}
|
|
}
|