Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using Terraria.ID;
- using Terraria.ModLoader;
- using Terraria;
- namespace Runeblade.Items.Spells
- {
- public class EnduranceSpell : ModItem
- {
- public override void SetStaticDefaults()
- {
- DisplayName.SetDefault("Endurance");
- Tooltip.SetDefault("Spell"
- +"\nDraws power from the heavens"
- +"\nGrants the Endurance, Wrath, Ironskin, Beetle Endurance 3 and Inferno buffs for 2 minutes");
- }
- public override void SetDefaults()
- {
- item.potion = true;
- item.value = 100000;
- item.rare = 12;
- item.maxStack = 1;
- item.buffType = BuffID.Endurance;
- item.buffTime = 7200;
- item.noMelee = true;
- item.useStyle = 4;
- item.mana = 20;
- }
- public virtual bool UseItem(Item item, Player player)
- {
- player.AddBuff(BuffID.Wrath, 7200, true);
- player.AddBuff(BuffID.BeetleEndurance3, 7200, true);
- player.AddBuff(BuffID.Inferno, 7200, true);
- player.AddBuff(BuffID.Ironskin, 7200, true);
- return true;
- }
- public override void AddRecipes()
- {
- ModRecipe recipe = new ModRecipe(mod);
- recipe.AddIngredient(null, "RunebladeEssence", 500);
- recipe.AddIngredient(ItemID.ManaCrystal, 5);
- recipe.AddIngredient(ItemID.SpellTome, 1);
- recipe.SetResult(this);
- recipe.AddRecipe();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement