a mining and exploration helmet
This commit is contained in:
1 parent
e45aa7eb7c
commit
09ccb17d5c
5 files changed
+62
-22
No files matched your search
@@ -9,6 +9,7 @@ namespace CalamityMod.Items.Armor
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class ReaverCap : ModItem
|
||||
{
|
||||
//Health and Regen Helm
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Reaver Headgear");
|
||||
|
||||
@@ -9,6 +9,7 @@ namespace CalamityMod.Items.Armor
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class ReaverHelm : ModItem
|
||||
{
|
||||
//Defense and DR Helm
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Reaver Helm");
|
||||
|
||||
+58
-22
@@ -1,7 +1,7 @@
|
||||
using CalamityMod.Buffs.Summon;
|
||||
using CalamityMod.CalPlayer;
|
||||
using CalamityMod.Items.Materials;
|
||||
using CalamityMod.Projectiles.Summon;
|
||||
using CalamityMod.World;
|
||||
using System.Collections.Generic;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
@@ -11,11 +11,12 @@ namespace CalamityMod.Items.Armor
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class ReaverHelmet : ModItem
|
||||
{
|
||||
//Exploration and Mining Helm
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Reaver Helmet");
|
||||
Tooltip.SetDefault("5% increased minion damage, +2 max minions, and increased minion knockback\n" +
|
||||
"10% increased movement speed and can move freely through liquids");
|
||||
Tooltip.SetDefault("10% increased pick speed\n" +
|
||||
"Temporary immunity to lava and can move freely through liquids");
|
||||
}
|
||||
|
||||
public override void SetDefaults()
|
||||
@@ -27,6 +28,21 @@ namespace CalamityMod.Items.Armor
|
||||
item.defense = 3; //36
|
||||
}
|
||||
|
||||
public override void ModifyTooltips(List<TooltipLine> list)
|
||||
{
|
||||
if (CalamityWorld.death)
|
||||
{
|
||||
foreach (TooltipLine line2 in list)
|
||||
{
|
||||
if (line2.mod == "Terraria" && line2.Name == "Tooltip1")
|
||||
{
|
||||
line2.text = "Temporary immunity to lava and can move freely through liquids\n" +
|
||||
"Provides heat protection in Death Mode";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override bool IsArmorSet(Item head, Item body, Item legs)
|
||||
{
|
||||
return body.type == ModContent.ItemType<ReaverScaleMail>() && legs.type == ModContent.ItemType<ReaverCuisses>();
|
||||
@@ -40,31 +56,51 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateArmorSet(Player player)
|
||||
{
|
||||
player.setBonus = "16% increased minion damage\n" +
|
||||
"Summons a reaver orb that emits spore gas when enemies are near";
|
||||
player.setBonus = "Causes nearby treasure to sparkle\n" +
|
||||
"Provides a small amount of light in the abyss";
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.reaverOrb = true;
|
||||
if (player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
if (player.FindBuffIndex(ModContent.BuffType<ReaverSummonSetBuff>()) == -1)
|
||||
{
|
||||
player.AddBuff(ModContent.BuffType<ReaverSummonSetBuff>(), 3600, true);
|
||||
}
|
||||
if (player.ownedProjectileCounts[ModContent.ProjectileType<ReaverOrb>()] < 1)
|
||||
{
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<ReaverOrb>(), (int)(80f * player.MinionDamage()), 0f, Main.myPlayer, 50f, 0f);
|
||||
}
|
||||
}
|
||||
player.minionDamage += 0.16f;
|
||||
|
||||
Lighting.AddLight((int)player.Center.X / 16, (int)player.Center.Y / 16, 0.3f, 1.5f, 0.3f);
|
||||
if (player.miscCounter % 10 == 0)
|
||||
{
|
||||
int searchDist = 17;
|
||||
int x = (int)player.Center.X / 16;
|
||||
int y = (int)player.Center.Y / 16;
|
||||
for (int i = x - searchDist; i <= x + searchDist; ++i)
|
||||
{
|
||||
for (int j = y - searchDist; j <= y + searchDist; ++j)
|
||||
{
|
||||
if (Main.rand.NextBool(4) && (new Vector2((float)(x - i), (float)(y - j)).Length() < (float)searchDist && i > 0 && (i < Main.maxTilesX - 1 && j > 0) && (j < Main.maxTilesY - 1 && Main.tile[i, j] != null && Main.tile[i, j].active())))
|
||||
{
|
||||
bool shouldSparkle = false;
|
||||
//Check for the money piles
|
||||
if (Main.tile[i, j].type == TileID.SmallPiles && Main.tile[i, j].frameY == 18)
|
||||
{
|
||||
if (Main.tile[i, j].frameX >= 576 && Main.tile[i, j].frameX <= 882)
|
||||
shouldSparkle = true;
|
||||
}
|
||||
else if (Main.tile[i, j].type == TileID.LargePiles && Main.tile[i, j].frameX >= 864 && Main.tile[i, j].frameX <= 1170)
|
||||
shouldSparkle = true;
|
||||
|
||||
if (shouldSparkle || Main.tileSpelunker[Main.tile[i, j].type] || Main.tileAlch[Main.tile[i, j].type] && Main.tile[i, j].type != TileID.ImmatureHerbs)
|
||||
{
|
||||
int sparkle = Dust.NewDust(new Vector2((float)(i * 16), (float)(j * 16)), 16, 16, 204, 0f, 0f, 150, new Color(), 0.3f);
|
||||
Dust dust = Main.dust[sparkle];
|
||||
dust.fadeIn = 0.75f;
|
||||
dust.velocity = dust.velocity * 0.1f;
|
||||
dust.noLight = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.ignoreWater = true;
|
||||
player.minionDamage += 0.05f;
|
||||
player.minionKB += 1f;
|
||||
player.maxMinions += 2;
|
||||
player.moveSpeed += 0.1f;
|
||||
player.pickSpeed -= 0.1f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -9,6 +9,7 @@ namespace CalamityMod.Items.Armor
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class ReaverMask : ModItem
|
||||
{
|
||||
//Damage and Crit Helm
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Reaver Mask");
|
||||
|
||||
@@ -9,6 +9,7 @@ namespace CalamityMod.Items.Armor
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class ReaverVisage : ModItem
|
||||
{
|
||||
//Jump/Flight Boosts and Movement Speed Helm
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Reaver Visage");
|
||||
|
||||
Reference in new issue
Block a user