Decimation_Mod/Content/Items/Accessories/EndlessPouchofLife.cs
FyloZ ec4585bed5 - Changed Bloodshot Eye's music to Boss 1 Orchestra ( https://www.youtube.com/watch?time_continue=120&v=r-9nKGc85FQ )
- Added support for animated projectiles
- Refactoring
- Removed useless fields
- Fixed swords not dealing damages
- Added Hour Hand (from Evie's PR)
2020-03-21 00:11:07 -04:00

48 lines
1.8 KiB
C#

using System.Collections.Generic;
using Decimation.Content.Tiles;
using Decimation.Lib.Items;
using Decimation.Lib.Util;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace Decimation.Content.Items.Accessories
{
internal class EndlessPouchofLife : DecimationAccessory
{
protected override string ItemName => "Endless Pouch of Life";
protected override string ItemTooltip => "Cancels ammunition consumption." +
"\nIncrease maximum life by 15" +
"\nChange ammunitions in Chlorophyte Bullets \nProvide a life regeneration boost \n+8% ranged damage \n+15% critical strike chance";
protected override void InitAccessory()
{
item.width = 24;
item.height = 32;
item.rare = Rarity.Lime.GetRarityValue();
this.item.value = Item.buyPrice(0, 50);
}
public override void UpdateAccessory(Player player, bool hideVisual)
{
player.lifeRegen += 5;
player.rangedDamage += 0.08f;
player.rangedCrit += 5;
player.statLifeMax2 += 15;
Main.LocalPlayer.GetModPlayer<DecimationPlayer>().endlessPouchofLifeEquipped = true;
}
protected override List<ModRecipe> GetAdditionalRecipes()
{
ModRecipe recipe = GetNewModRecipe(this, 1, new List<int> {ModContent.TileType<ChlorophyteAnvil>()});
recipe.AddIngredient(ItemID.ChlorophyteBar, 25);
recipe.AddIngredient(ModContent.ItemType<EnergyFocuser>());
recipe.AddIngredient(ItemID.EndlessMusketPouch);
recipe.AddIngredient(ItemID.SoulofSight, 50);
return new List<ModRecipe> {recipe};
}
}
}