Files
CalamityModPublic/Items/Potions/AureusCell.cs
T
Altixal e1c848d45f bulk price changes part 1
- *Re-scaled price of most Calamity materials* (most drastically post-DoG)
- Shimmer transmutation price parity (same as og items)
- Applied consistent vanilla sell anchor values to Calamity items:
 - Buff potions: 2 silver
 - Flask: 5 silver
 - Uncommon critters: 10 silver
 - Potion fish: 15 silver
 - Lootable fish: 10 silver
 - Sashimi fish: 7.5 silver
 - Plentiful fish: 5 silver
 - Added value to Calamity seeds and saplings to match vanilla
2024-09-17 21:42:55 +07:00

56 lines
1.8 KiB
C#

using Terraria;
using Terraria.GameInput;
using Terraria.ID;
using Terraria.ModLoader;
namespace CalamityMod.Items.Potions
{
[LegacyName("AstralJelly")]
public class AureusCell : ModItem, ILocalizedModType
{
public new string LocalizationCategory => "Items.Potions";
public override void SetStaticDefaults()
{
Item.ResearchUnlockCount = 20;
}
public override void SetDefaults()
{
Item.width = 28;
Item.height = 18;
Item.useTurn = true;
Item.maxStack = 9999;
Item.useAnimation = 17;
Item.useTime = 17;
Item.useStyle = ItemUseStyleID.EatFood;
Item.healMana = 200;
Item.UseSound = SoundID.Item3;
Item.consumable = true;
Item.buffType = BuffID.MagicPower;
Item.buffTime = CalamityUtils.SecondsToFrames(360f);
Item.value = Item.sellPrice(silver: 50); // Based on material cost rather than potion cost
Item.rare = ItemRarityID.Lime;
}
public override void OnConsumeItem(Player player)
{
if (PlayerInput.Triggers.JustPressed.QuickBuff)
{
player.statMana += Item.healMana;
if (player.statMana > player.statManaMax2)
{
player.statMana = player.statManaMax2;
}
player.AddBuff(BuffID.ManaSickness, Player.manaSickTime, true);
if (Main.myPlayer == player.whoAmI)
{
player.ManaEffect(Item.healMana);
}
}
player.AddBuff(BuffID.MagicPower, Item.buffTime);
player.AddBuff(BuffID.ManaRegeneration, Item.buffTime);
}
}
}