Decimation_Mod/Content/Items/Misc/BloodyLunarTablet.cs
FyloZ 9c23e3284f Fixed Bloodshot Eye disappearing.
The Bloody Lunar Tablet can now be used the day.
2020-06-04 17:17:01 -04:00

38 lines
992 B
C#

using Decimation.Lib.Items;
using Decimation.Lib.Util;
using Terraria;
namespace Decimation.Content.Items.Misc
{
internal class BloodyLunarTablet : DecimationItem
{
protected override string ItemName => "Bloody Lunar Tablet";
protected override string ItemTooltip => "Summon blood moon.";
protected override void Init()
{
item.width = 30;
item.height = 40;
item.rare = Rarity.Green.GetRarityValue();
item.value = Item.buyPrice(gold: 5);
item.useStyle = 1;
item.useTime = 20;
item.useAnimation = 20;
item.consumable = true;
item.maxStack = 1;
}
public override bool CanUseItem(Player player)
{
return !Main.bloodMoon;
}
public override bool UseItem(Player player)
{
Main.bloodMoon = true;
Main.dayTime = false;
return true;
}
}
}