2 - Holy Wrath and Profaned Rage no longer provide movement speed. 3 - Holy Wrath no longer provides horizontal flight speed. 4 - Mirage Jellys can now be hit at all times, even while they're teleporting. 5 - King Slime Jewel can now be killed. 6 - Profaned Energy Lanterns no longer deal contact damage. 7 - Plague Mines can now be damaged at all times.
124 lines
3.9 KiB
C#
124 lines
3.9 KiB
C#
using CalamityMod.CalPlayer;
|
|
using CalamityMod.Items.Materials;
|
|
using CalamityMod.World;
|
|
using System.Collections.Generic;
|
|
using Terraria;
|
|
using Terraria.ID;
|
|
using Terraria.ModLoader;
|
|
|
|
namespace CalamityMod.Items.Armor
|
|
{
|
|
[AutoloadEquip(EquipType.Head)]
|
|
public class XerocMask : ModItem
|
|
{
|
|
public override void SetStaticDefaults()
|
|
{
|
|
DisplayName.SetDefault("Empyrean Mask");
|
|
Tooltip.SetDefault("Wrath of the cosmos\n" +
|
|
"11% increased rogue damage and critical strike chance, 5% increased movement speed\n" +
|
|
"Temporary immunity to lava");
|
|
}
|
|
|
|
public override void SetDefaults()
|
|
{
|
|
item.width = 18;
|
|
item.height = 18;
|
|
item.value = Item.buyPrice(0, 40, 0, 0);
|
|
item.rare = ItemRarityID.Red;
|
|
item.defense = 20; //71
|
|
}
|
|
|
|
public override void ModifyTooltips(List<TooltipLine> list)
|
|
{
|
|
if (CalamityWorld.death)
|
|
{
|
|
foreach (TooltipLine line2 in list)
|
|
{
|
|
if (line2.mod == "Terraria" && line2.Name == "Tooltip2")
|
|
{
|
|
line2.text = "Temporary immunity to lava\n" +
|
|
"Provides heat protection in Death Mode";
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
public override bool IsArmorSet(Item head, Item body, Item legs)
|
|
{
|
|
return body.type == ModContent.ItemType<XerocPlateMail>() && legs.type == ModContent.ItemType<XerocCuisses>();
|
|
}
|
|
|
|
public override void ArmorSetShadows(Player player)
|
|
{
|
|
player.armorEffectDrawShadow = true;
|
|
player.armorEffectDrawOutlines = true;
|
|
player.Calamity().meldTransformation = true;
|
|
player.Calamity().meldTransformationForce = true;
|
|
}
|
|
|
|
public override void UpdateArmorSet(Player player)
|
|
{
|
|
CalamityPlayer modPlayer = player.Calamity();
|
|
modPlayer.xerocSet = true;
|
|
modPlayer.rogueStealthMax += 1.15f;
|
|
player.setBonus = "9% increased rogue damage and velocity\n" +
|
|
"Rogue projectiles have special effects on enemy hits\n" +
|
|
"Imbued with cosmic wrath and rage when you are damaged\n" +
|
|
"Rogue stealth builds while not attacking and slower while moving, up to a max of 115\n" +
|
|
"Once you have built max stealth, you will be able to perform a Stealth Strike\n" +
|
|
"Rogue stealth only reduces when you attack, it does not reduce while moving\n" +
|
|
"The higher your rogue stealth the higher your rogue damage, crit, and movement speed";
|
|
if (player.statLife <= (int)(player.statLifeMax2 * 0.5))
|
|
{
|
|
player.AddBuff(BuffID.Wrath, 2);
|
|
player.AddBuff(BuffID.Rage, 2);
|
|
}
|
|
modPlayer.throwingDamage += 0.09f;
|
|
modPlayer.throwingVelocity += 0.09f;
|
|
modPlayer.wearingRogueArmor = true;
|
|
}
|
|
|
|
public override void UpdateEquip(Player player)
|
|
{
|
|
player.Calamity().throwingDamage += 0.11f;
|
|
player.Calamity().throwingCrit += 11;
|
|
player.moveSpeed += 0.05f;
|
|
player.lavaMax += 240;
|
|
}
|
|
|
|
public override void AddRecipes()
|
|
{
|
|
ModRecipe recipe = new ModRecipe(mod);
|
|
recipe.AddIngredient(ModContent.ItemType<MeldiateBar>(), 12);
|
|
recipe.AddIngredient(ItemID.LunarBar, 8);
|
|
recipe.AddTile(TileID.LunarCraftingStation);
|
|
recipe.SetResult(this);
|
|
recipe.AddRecipe();
|
|
}
|
|
}
|
|
|
|
public class MeldTransformationHead : EquipTexture
|
|
{
|
|
public override bool DrawHead()
|
|
{
|
|
return false;
|
|
}
|
|
}
|
|
|
|
public class MeldTransformationBody : EquipTexture
|
|
{
|
|
public override bool DrawBody()
|
|
{
|
|
return false;
|
|
}
|
|
}
|
|
|
|
public class MeldTransformationLegs : EquipTexture
|
|
{
|
|
public override bool DrawLegs()
|
|
{
|
|
return false;
|
|
}
|
|
}
|
|
}
|