Files
CalamityModPublic/Items/Pets/McNuggets.cs
T

29 lines
895 B
C#

using CalamityMod.Buffs.Pets;
using CalamityMod.Projectiles.Pets;
using CalamityMod.Rarities;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ModLoader;
namespace CalamityMod.Items.Pets
{
public class McNuggets : ModItem, ILocalizedModType
{
public new string LocalizationCategory => "Items.Pets";
public override void SetDefaults()
{
Item.DefaultToVanitypet(ModContent.ProjectileType<YharonSonPet>(), ModContent.BuffType<YharonSonBuff>());
Item.value = Item.sellPrice(gold: 20);
Item.rare = ModContent.RarityType<BurnishedAuric>();
}
public override void UseStyle(Player player, Rectangle heldItemFrame)
{
if (player.whoAmI == Main.myPlayer && player.itemTime == 0)
{
player.AddBuff(Item.buffType, 3600, true);
}
}
}
}