Files
CalamityModPublic/Items/SummonItems/Portabulb.cs
T
Altixal a321ece97b Material culling & recipe changes 2024
- Removed Demonic Bone Ash
- Removed Murky Paste
- Removed Trapper Bulb

Most of these are recipe ordering hell (again)
- Moved Shadowspec Bar to the top of most materials
- Moved Cosmilite Bar to the top of most materials (under SSpec)
- Moved complementary ASE type to pair below Bars
- Swap recipe order of Soul Artifacts
- Enforced certain material pairing orders
- Added missing materials for certain sets
2024-09-05 23:19:37 +07:00

58 lines
1.8 KiB
C#

using CalamityMod.Events;
using CalamityMod.Items.Materials;
using CalamityMod.Items.Placeables;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace CalamityMod.Items.SummonItems
{
[LegacyName("BulbofDoom")]
public class Portabulb : ModItem, ILocalizedModType
{
public new string LocalizationCategory => "Items.SummonItems";
public override void SetStaticDefaults()
{
NPCID.Sets.MPAllowedEnemies[NPCID.Plantera] = true;
ItemID.Sets.SortingPriorityBossSpawns[Type] = 11; // Pirate Map (1 above Mechanical Skull)
}
public override void SetDefaults()
{
Item.width = 28;
Item.height = 18;
Item.useAnimation = 10;
Item.useTime = 10;
Item.useStyle = ItemUseStyleID.HoldUp;
Item.rare = ItemRarityID.Lime;
Item.consumable = false;
}
public override void ModifyResearchSorting(ref ContentSamples.CreativeHelper.ItemGroup itemGroup)
{
itemGroup = ContentSamples.CreativeHelper.ItemGroup.BossItem;
}
public override bool CanUseItem(Player player)
{
return player.ZoneJungle && !NPC.AnyNPCs(NPCID.Plantera) && !BossRushEvent.BossRushActive;
}
public override bool? UseItem(Player player)
{
CalamityUtils.SpawnBossUsingItem(player, NPCID.Plantera, SoundID.Roar);
return true;
}
public override void AddRecipes()
{
CreateRecipe().
AddIngredient<VernalSoil>(20).
AddIngredient(ItemID.JungleSpores, 15).
AddIngredient<EssenceofSunlight>(5).
AddTile(TileID.Anvils).
Register();
}
}
}