- Added support for animated projectiles - Refactoring - Removed useless fields - Fixed swords not dealing damages - Added Hour Hand (from Evie's PR)
47 lines
1.4 KiB
C#
47 lines
1.4 KiB
C#
using Decimation.Content.Items.Accessories;
|
|
using Decimation.Content.Items.Weapons.Arachnus;
|
|
using Decimation.Lib.Items;
|
|
using Decimation.Lib.Util;
|
|
using Terraria;
|
|
using Terraria.ModLoader;
|
|
|
|
namespace Decimation.Content.Items.Boss.Arachnus
|
|
{
|
|
internal class ArachnusTreasureBag : DecimationItem
|
|
{
|
|
protected override string ItemName => "Treasure Bag";
|
|
protected override string ItemTooltip => "{$CommonItemTooltip.RightClickToOpen}";
|
|
public override int BossBagNPC => ModContent.NPCType<NPCs.Arachnus.Arachnus>();
|
|
|
|
protected override void Init()
|
|
{
|
|
item.consumable = true;
|
|
item.width = 32;
|
|
item.height = 32;
|
|
item.rare = Rarity.Cyan.GetRarityValue();
|
|
|
|
this.item.expert = true;
|
|
this.item.maxStack = 999;
|
|
}
|
|
|
|
public override bool CanRightClick()
|
|
{
|
|
return true;
|
|
}
|
|
|
|
public override void OpenBossBag(Player player)
|
|
{
|
|
player.TryGettingDevArmor();
|
|
|
|
int rand = Main.rand.Next(3);
|
|
if (rand == 0)
|
|
player.QuickSpawnItem(ModContent.ItemType<ChainStynger>());
|
|
else if (rand == 1)
|
|
player.QuickSpawnItem(ModContent.ItemType<GlaiveWeaver>());
|
|
else if (rand == 2)
|
|
player.QuickSpawnItem(ModContent.ItemType<Infernolizer>());
|
|
|
|
player.QuickSpawnItem(ModContent.ItemType<ShinySentinel>());
|
|
}
|
|
}
|
|
} |