Example #1
0
        public override void UpdateAccessory(Player player, bool hideVisual)
        {
            KnifeDamagePlayer modPlayer = KnifeDamagePlayer.ModPlayer(player);

            modPlayer.knifeDamageMult += 0.2f;
            crafted = true;
        }
Example #2
0
        public override void UpdateAccessory(Player player, bool hideVisual)
        {
            KnifeDamagePlayer modPlayer = KnifeDamagePlayer.ModPlayer(player);

            modPlayer.KnifeCrit += 8;
            player.magicCrit    += 8;
            player.meleeCrit    += 8;
            player.thrownCrit   += 8;
            player.rangedCrit   += 8;
        }
        public override void Update(Player player, ref int buffIndex)
        {
            KnifeDamagePlayer p = KnifeDamagePlayer.ModPlayer(player);

            if (Main.rand.Next(50) == 5)
            {
                p.KnifeDamage = p.KnifeDamage * 10;
            }
            p.KnifeCrit = (int)(p.KnifeCrit * .01);
        }
Example #4
0
        public override void Update(Player player, ref int buffIndex)
        {
            KnifeDamagePlayer p = KnifeDamagePlayer.ModPlayer(player);

            if (Main.rand.Next(50) == 5)
            {
                p.KnifeDamage = p.KnifeDamage * Main.rand.Next(1, 4);
            }
            p.KnifeCrit = (int)(p.KnifeCrit * .01);
            player.GetModPlayer <VampPlayer>().ShroomiteBuff = true;
        }
        public override void ModifyTooltips(List <TooltipLine> tooltips)
        {
            if (NPC.downedBoss2)
            {
                percentage = 1;
                numProj    = 1;
            }
            if (NPC.downedQueenBee)
            {
                percentage = 2;
                numProj    = 2;
            }
            if (NPC.downedBoss3)
            {
                percentage = 4;
                numProj    = 3;
            }
            if (Main.hardMode)
            {
                percentage = 8;
                numProj    = 4;
            }
            if (NPC.downedMechBoss1)
            {
                percentage = 10;
                numProj    = 5;
            }
            if (NPC.downedMechBoss2)
            {
                percentage = 12;
                numProj    = 6;
            }
            if (NPC.downedMechBoss3)
            {
                percentage = 14;
                numProj    = 7;
            }
            if (NPC.downedPlantBoss)
            {
                percentage = 15;
                numProj    = 8;
            }
            if (NPC.downedGolemBoss)
            {
                percentage = 16;
                numProj    = 9;
            }
            if (NPC.downedFishron)
            {
                percentage = 18;
                numProj    = 10;
            }
            if (NPC.downedAncientCultist)
            {
                percentage = 19;
                numProj    = 11;
            }
            if (NPC.downedTowers)
            {
                percentage = 20;
                numProj    = 12;
            }
            KnifeDamagePlayer d     = Main.LocalPlayer.GetModPlayer <KnifeDamagePlayer>();
            VampPlayer        p     = Main.LocalPlayer.GetModPlayer <VampPlayer>();
            TooltipLine       line2 = new TooltipLine(mod, "Face", "+ " + d.KnifeCrit + "% crit chance.");

            line2.overrideColor = new Color(255, 60, 28);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line2);
            }
            TooltipLine line = new TooltipLine(mod, "Face", "+ " + percentage + "% Movement Speed.");

            line.overrideColor = new Color(255, 60, 28);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line);
            }
            if (p.PsionicArmorSet)
            {
                TooltipLine line4 = new TooltipLine(mod, "Face", "Set Bonus:");
                line4.overrideColor = new Color(255, 70, 38);
                tooltips.Add(line4);
                TooltipLine line3 = new TooltipLine(mod, "Face", "+ 4% chance to spawn " + numProj + " 'homing projectiles'");
                line3.overrideColor = new Color(255, 70, 38);
                tooltips.Add(line3);
            }

            foreach (TooltipLine line5 in tooltips)
            {
                if (line5.mod == "Terraria" && line5.Name == "Equipable")
                {
                    line5.overrideColor = new Color(255, 40, 20);
                }
                if (line5.mod == "Terraria" && line5.Name == "Defense")
                {
                    line5.overrideColor = new Color(235, 32, 12);
                }
                if (line5.mod == "Terraria" && line5.Name == "Tooltip0")
                {
                    line5.overrideColor = new Color(215, 20, 2);
                }
                if (line5.mod == "Terraria" && line5.Name == "ItemName")
                {
                    if (Frame == 0)
                    {
                        line5.text = ("[c/FF3333:Psionic Leggings]");
                    }
                    if (Frame == 1)
                    {
                        line5.text = ("[c/B48C8C:Ps][c/FF3333:ionic Leggings]");
                    }
                    if (Frame == 2)
                    {
                        line5.text = ("[c/75D6D6:Ps][c/B48C8C:io][c/FF3333:nic Leggings]");
                    }
                    if (Frame == 3)
                    {
                        line5.text = ("[c/B48C8C:Ps][c/75D6D6:io][c/B48C8C:ni][c/FF3333:c Leggings]");
                    }
                    if (Frame == 4)
                    {
                        line5.text = ("[c/FF3333:Ps][c/B48C8C:io][c/75D6D6:ni][c/B48C8C:c][c/FF3333: Leggings]");
                    }
                    if (Frame == 5)
                    {
                        line5.text = ("[c/FF3333:Psio][c/B48C8C:ni][c/75D6D6:c][c/B48C8C: Le][c/FF3333:ggings]");
                    }
                    if (Frame == 6)
                    {
                        line5.text = ("[c/FF3333:Psioni][c/B48C8C:c][c/75D6D6: Le][c/B48C8C:gg][c/FF3333:ings]");
                    }
                    if (Frame == 7)
                    {
                        line5.text = ("[c/FF3333:Psionic][c/B48C8C: Le][c/75D6D6:gg][c/B48C8C:in][c/FF3333:gs]");
                    }
                    if (Frame == 8)
                    {
                        line5.text = ("[c/FF3333:Psionic Le][c/B48C8C:gg][c/75D6D6:in][c/B48C8C:gs]");
                    }
                    if (Frame == 9)
                    {
                        line5.text = ("[c/FF3333:Psionic Legg][c/B48C8C:in][c/75D6D6:gs]");
                    }
                    if (Frame == 10)
                    {
                        line5.text = ("[c/FF3333:Psionic Leggin][c/B48C8C:gs]");
                    }
                    if (Frame == 11)
                    {
                        line5.text = ("[c/FF3333:Psionic Leggings]");
                    }
                }
            }
        }
        public override void UpdateEquip(Player player)
        {
            FrameCounter++;        //increase the frameCounter by one
            if (FrameCounter >= 4) //once the frameCounter has reached 3 - change the 10 to change how fast the projectile animates
            {
                FrameCounter = 0;
                Frame++;        //go to the next frame
                if (Frame > 11) //if past the last frame
                {
                    Frame = 0;  //go back to the first frame
                }
            }
            KnifeDamagePlayer d = player.GetModPlayer <KnifeDamagePlayer>();

            if (NPC.downedBoss2)
            {
                player.moveSpeed += 0.01f;
                d.KnifeCrit      += 1;
                item.value        = Item.sellPrice(0, 2, 0, 0);
                item.defense      = 2;
            }
            if (NPC.downedQueenBee)
            {
                player.moveSpeed += 0.02f;
                d.KnifeCrit      += 1;
                item.value        = Item.sellPrice(0, 3, 0, 0);
            }
            if (NPC.downedBoss3)
            {
                player.moveSpeed += 0.04f;
                d.KnifeCrit      += 2;
                item.value        = Item.sellPrice(0, 4, 0, 0);
                item.defense      = 3;
            }
            if (Main.hardMode)
            {
                player.moveSpeed += 0.08f;
                d.KnifeCrit      += 2;
                item.value        = Item.sellPrice(0, 5, 0, 0);
                item.defense      = 5;
            }
            if (NPC.downedMechBoss1)
            {
                player.moveSpeed += 0.1f;
                d.KnifeCrit      += 3;
                item.value        = Item.sellPrice(0, 6, 0, 0);
                item.defense      = 6;
            }
            if (NPC.downedMechBoss2)
            {
                player.moveSpeed += 0.12f;
                d.KnifeCrit      += 4;
                item.value        = Item.sellPrice(0, 7, 0, 0);
                item.defense      = 7;
            }
            if (NPC.downedMechBoss3)
            {
                player.moveSpeed += 0.14f;
                d.KnifeCrit      += 5;
                item.value        = Item.sellPrice(0, 8, 0, 0);
                item.defense      = 8;
            }
            if (NPC.downedPlantBoss)
            {
                player.moveSpeed += 0.15f;
                d.KnifeCrit      += 6;
                item.value        = Item.sellPrice(0, 9, 0, 0);
                item.defense      = 9;
            }
            if (NPC.downedGolemBoss)
            {
                player.moveSpeed += 0.16f;
                d.KnifeCrit      += 7;
                item.value        = Item.sellPrice(0, 10, 0, 0);
                item.defense      = 10;
            }
            if (NPC.downedFishron)
            {
                player.moveSpeed += 0.18f;
                d.KnifeCrit      += 8;
                item.value        = Item.sellPrice(0, 12, 0, 0);
                item.defense      = 11;
            }
            if (NPC.downedAncientCultist)
            {
                player.moveSpeed += 0.19f;
                d.KnifeCrit      += 9;
                item.value        = Item.sellPrice(0, 14, 0, 0);
                item.defense      = 12;
            }
            if (NPC.downedTowers)
            {
                player.moveSpeed += 0.20f;
                d.KnifeCrit      += 10;
                item.value        = Item.sellPrice(0, 16, 0, 0);
                item.defense      = 14;
            }
        }
        public override void ModifyTooltips(List <TooltipLine> tooltips)
        {
            KnifeDamagePlayer d     = Main.LocalPlayer.GetModPlayer <KnifeDamagePlayer>();
            VampPlayer        p     = Main.LocalPlayer.GetModPlayer <VampPlayer>();
            TooltipLine       line2 = new TooltipLine(mod, "Face", "Defense knives have " + p.DefenseExtraLives + " extra life");

            if (NPC.downedBoss2)
            {
                line2.text = "Defense knives have " + p.DefenseExtraLives + " extra lives";
            }
            line2.overrideColor = new Color(160, 0, 0);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line2);
            }
            TooltipLine line = new TooltipLine(mod, "Face", "+" + (int)(SpeedIncrease * 100) + "% Movement Speed.");

            line.overrideColor = new Color(160, 0, 0);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line);
            }
            if (p.VampiricArmorSet)
            {
                TooltipLine line4 = new TooltipLine(mod, "Face", "Set Bonus:");
                line4.overrideColor = new Color(180, 0, 0);
                tooltips.Add(line4);
                TooltipLine line3 = new TooltipLine(mod, "Face", "Enemies are more likely to target you\nHave a " + ((2f * p.VampiricSetScaler) / 10f) + "% Chance to steal the life of the enemies around you upon being hit");
                line3.overrideColor = new Color(180, 0, 0);
                tooltips.Add(line3);
            }

            foreach (TooltipLine line5 in tooltips)
            {
                if (line5.mod == "Terraria" && line5.Name == "Equipable")
                {
                    line5.overrideColor = new Color(160, 0, 0);
                }
                if (line5.mod == "Terraria" && line5.Name == "Defense")
                {
                    line5.overrideColor = new Color(160, 0, 0);
                }
                if (line5.mod == "Terraria" && line5.Name == "Tooltip0")
                {
                    line5.overrideColor = new Color(160, 0, 0);
                }
                if (line5.mod == "Terraria" && line5.Name == "ItemName")
                {
                    if (Frame == 0)
                    {
                        line5.text = ("[c/3B0000:Vampiric Greaves]");
                    }
                    if (Frame == 1)
                    {
                        line5.text = ("[c/730600:Vampiric Greaves]");
                    }
                    if (Frame == 2)
                    {
                        line5.text = ("[c/AD0900:Vampiric Greaves]");
                    }
                    if (Frame == 3)
                    {
                        line5.text = ("[c/730600:Vampiric Greaves]");
                    }
                }
            }
        }
        public override void UpdateEquip(Player player)
        {
            FrameCounter++;        //increase the frameCounter by one
            if (FrameCounter >= 8) //once the frameCounter has reached 3 - change the 10 to change how fast the projectile animates
            {
                FrameCounter = 0;
                Frame++;       //go to the next frame
                if (Frame > 3) //if past the last frame
                {
                    Frame = 0; //go back to the first frame
                }
            }
            VampPlayer        p = player.GetModPlayer <VampPlayer>();
            KnifeDamagePlayer d = player.GetModPlayer <KnifeDamagePlayer>();

            if (NPC.downedBoss2)
            {
                SpeedIncrease        = 0.01f;
                item.value           = Item.sellPrice(0, 2, 0, 0);
                item.defense         = 6;
                p.DefenseExtraLives += 1;
            }
            if (NPC.downedQueenBee)
            {
                SpeedIncrease = 0.02f;
                item.value    = Item.sellPrice(0, 3, 0, 0);
            }
            if (NPC.downedBoss3)
            {
                SpeedIncrease        = 0.03f;
                item.value           = Item.sellPrice(0, 4, 0, 0);
                item.defense         = 7;
                p.DefenseExtraLives += 2;
            }
            if (Main.hardMode)
            {
                SpeedIncrease = 0.04f;
                item.value    = Item.sellPrice(0, 5, 0, 0);
                item.defense  = 8;
            }
            if (NPC.downedMechBoss1)
            {
                SpeedIncrease = 0.05f;
                item.value    = Item.sellPrice(0, 6, 0, 0);
                item.defense  = 10;
            }
            if (NPC.downedMechBoss2)
            {
                SpeedIncrease = 0.06f;
                item.value    = Item.sellPrice(0, 7, 0, 0);
                item.defense  = 11;
            }
            if (NPC.downedMechBoss3)
            {
                SpeedIncrease        = 0.07f;
                item.value           = Item.sellPrice(0, 8, 0, 0);
                item.defense         = 12;
                p.DefenseExtraLives += 3;
            }
            if (NPC.downedPlantBoss)
            {
                SpeedIncrease        = 0.08f;
                item.value           = Item.sellPrice(0, 9, 0, 0);
                item.defense         = 14;
                p.DefenseExtraLives += 4;
            }
            if (NPC.downedGolemBoss)
            {
                SpeedIncrease = 0.09f;
                item.value    = Item.sellPrice(0, 10, 0, 0);
                item.defense  = 15;
            }
            if (NPC.downedFishron)
            {
                SpeedIncrease        = 0.10f;
                item.value           = Item.sellPrice(0, 12, 0, 0);
                item.defense         = 16;
                p.DefenseExtraLives += 5;
            }
            if (NPC.downedAncientCultist)
            {
                SpeedIncrease        = 0.11f;
                item.value           = Item.sellPrice(0, 14, 0, 0);
                item.defense         = 18;
                p.DefenseExtraLives += 6;
            }
            if (NPC.downedTowers)
            {
                SpeedIncrease        = 0.12f;
                item.value           = Item.sellPrice(0, 16, 0, 0);
                item.defense         = 20;
                p.DefenseExtraLives += 7;
            }
            if (NPC.downedMoonlord)
            {
                SpeedIncrease        = 0.15f;
                item.value           = Item.sellPrice(0, 20, 0, 0);
                item.defense         = 24;
                p.DefenseExtraLives += 10;
            }
            player.moveSpeed += SpeedIncrease;
        }
        public override void UpdateAccessory(Player player, bool hideVisual)
        {
            KnifeDamagePlayer modPlayer = KnifeDamagePlayer.ModPlayer(player);

            modPlayer.KnifeCrit += 15;
        }
Example #10
0
        public override void ModifyTooltips(List <TooltipLine> tooltips)
        {
            VampPlayer        p    = Main.LocalPlayer.GetModPlayer <VampPlayer>();
            KnifeDamagePlayer d    = Main.LocalPlayer.GetModPlayer <KnifeDamagePlayer>();
            TooltipLine       line = new TooltipLine(mod, "Face", "+" + (int)(((d.knifeDamageMult * 100) * 0.00341) * 100) + "% Knife and Magic Damage");

            line.overrideColor = new Color(50, 158, 194);
            TooltipLine line2 = new TooltipLine(mod, "Face", "+" + StatManaBonus + " Mana");

            line2.overrideColor = new Color(50, 158, 194);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line);
            }
            if (NPC.downedBoss3)
            {
                tooltips.Add(line2);
            }

            if (p.SupportArmor)
            {
                TooltipLine line4 = new TooltipLine(mod, "Face", "Set Bonus:");
                line4.overrideColor = new Color(50, 182, 194);
                tooltips.Add(line4);
                TooltipLine line3 = new TooltipLine(mod, "Face", "By pressing the support buff key you use \nStored charges (indicated by visor intensity)\nto buff the players around you");
                line3.overrideColor = new Color(50, 182, 194);
                tooltips.Add(line3);
            }

            foreach (TooltipLine line5 in tooltips)
            {
                if (line5.mod == "Terraria" && line5.Name == "Equipable")
                {
                    line5.overrideColor = new Color(50, 158, 194);
                }
                if (line5.mod == "Terraria" && line5.Name == "Defense")
                {
                    line5.overrideColor = new Color(50, 158, 194);
                }
                if (line5.mod == "Terraria" && line5.Name == "Tooltip0")
                {
                    line5.overrideColor = new Color(50, 158, 194);
                }
                if (line5.mod == "Terraria" && line5.Name == "ItemName")
                {
                    if (Frame == 0)
                    {
                        line5.text = ("[c/287399:Spectral Robes]");
                    }
                    if (Frame == 1)
                    {
                        line5.text = ("[c/2E91B3:Spectral Robes]");
                    }
                    if (Frame == 2)
                    {
                        line5.text = ("[c/39B3DB:Spectral Robes]");
                    }
                    if (Frame == 3)
                    {
                        line5.text = ("[c/BCE3E3:Spectral Robes]");
                    }
                }
            }
        }
Example #11
0
        public override void UpdateEquip(Player player)
        {
            FrameCounter++;        //increase the frameCounter by one
            if (FrameCounter >= 9) //once the frameCounter has reached 3 - change the 10 to change how fast the projectile animates
            {
                FrameCounter = 0;
                Frame       += Switch; //go to the next frame
                if (Frame > 2)         //if past the last frame
                {
                    Switch *= -1;
                }
                else if (Frame < 1)
                {
                    Switch *= -1;
                }
            }
            VampPlayer        p = player.GetModPlayer <VampPlayer>();
            KnifeDamagePlayer d = player.GetModPlayer <KnifeDamagePlayer>();

            player.aggro += 300;
            if (NPC.downedBoss2)
            {
                item.value         = Item.sellPrice(0, 2, 0, 0);
                item.defense       = 2;
                d.knifeDamageMult += 0.02f;
            }
            if (NPC.downedQueenBee)
            {
                item.value         = Item.sellPrice(0, 3, 0, 0);
                item.defense       = 3;
                d.knifeDamageMult += 0.04f;
            }
            if (NPC.downedBoss3)
            {
                item.value         = Item.sellPrice(0, 4, 0, 0);
                item.defense       = 4;
                d.knifeDamageMult += 0.05f;
                StatManaBonus      = 10;
            }
            if (Main.hardMode)
            {
                item.value         = Item.sellPrice(0, 5, 0, 0);
                d.knifeDamageMult += 0.06f;
                item.defense       = 6;
                StatManaBonus      = 20;
            }
            if (NPC.downedMechBoss1)
            {
                item.value         = Item.sellPrice(0, 6, 0, 0);
                d.knifeDamageMult += 0.08f;
                item.defense       = 7;
            }
            if (NPC.downedMechBoss2)
            {
                item.value         = Item.sellPrice(0, 7, 0, 0);
                d.knifeDamageMult += 0.09f;
                MagicDamage        = 0.11f;
                item.defense       = 8;
            }
            if (NPC.downedMechBoss3)
            {
                item.value         = Item.sellPrice(0, 8, 0, 0);
                d.knifeDamageMult += 0.10f;
                item.defense       = 9;
                StatManaBonus      = 35;
            }
            if (NPC.downedPlantBoss)
            {
                item.value         = Item.sellPrice(0, 9, 0, 0);
                d.knifeDamageMult += 0.11f;
                item.defense       = 10;
            }
            if (NPC.downedGolemBoss)
            {
                item.value         = Item.sellPrice(0, 10, 0, 0);
                d.knifeDamageMult += 0.12f;
                item.defense       = 12;
                StatManaBonus      = 50;
            }
            if (NPC.downedFishron)
            {
                item.value         = Item.sellPrice(0, 12, 0, 0);
                d.knifeDamageMult += 0.14f;
                item.defense       = 14;
            }
            if (NPC.downedAncientCultist)
            {
                item.value         = Item.sellPrice(0, 14, 0, 0);
                d.knifeDamageMult += 0.15f;
                item.defense       = 16;
            }
            if (NPC.downedTowers)
            {
                item.value         = Item.sellPrice(0, 16, 0, 0);
                d.knifeDamageMult += 0.18f;
                item.defense       = 20;
                StatManaBonus      = 60;
            }
            if (NPC.downedMoonlord)
            {
                item.value         = Item.sellPrice(0, 20, 0, 0);
                d.knifeDamageMult += 0.24f;
                item.defense       = 30;
                StatManaBonus      = 80;
            }
            if (StatManaBonus > 0)
            {
                player.statManaMax2 += StatManaBonus;
            }
            if (NPC.downedBoss2)
            {
                float Multiplier = 0.78f;
                player.magicDamageMult += ((d.knifeDamageMult - 1.2f) * Multiplier);
            }
        }
Example #12
0
        public override void ModifyTooltips(List <TooltipLine> tooltips)
        {
            KnifeDamagePlayer d     = Main.LocalPlayer.GetModPlayer <KnifeDamagePlayer>();
            VampPlayer        p     = Main.LocalPlayer.GetModPlayer <VampPlayer>();
            TooltipLine       line2 = new TooltipLine(mod, "Face", "Movement adds +" + ManaRegen + " active mana regen");

            line2.overrideColor = new Color(50, 158, 194);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line2);
            }
            TooltipLine line = new TooltipLine(mod, "Face", "+" + (int)(SpeedIncrease * 100) + "% Movement Speed.");

            line.overrideColor = new Color(50, 158, 194);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line);
            }
            if (p.SupportArmor)
            {
                TooltipLine line4 = new TooltipLine(mod, "Face", "Set Bonus:");
                line4.overrideColor = new Color(50, 182, 194);
                tooltips.Add(line4);
                TooltipLine line3 = new TooltipLine(mod, "Face", "By pressing the support buff key you use \nStored charges (indicated by visor intensity)\nto buff the players around you");
                line3.overrideColor = new Color(50, 182, 194);
                tooltips.Add(line3);
            }

            foreach (TooltipLine line5 in tooltips)
            {
                if (line5.mod == "Terraria" && line5.Name == "Equipable")
                {
                    line5.overrideColor = new Color(50, 158, 194);
                }
                if (line5.mod == "Terraria" && line5.Name == "Defense")
                {
                    line5.overrideColor = new Color(50, 158, 194);
                }
                if (line5.mod == "Terraria" && line5.Name == "Tooltip0")
                {
                    line5.overrideColor = new Color(50, 158, 194);
                }
                if (line5.mod == "Terraria" && line5.Name == "ItemName")
                {
                    if (Frame == 0)
                    {
                        line5.text = ("[c/287399:Spectral Boots]");
                    }
                    if (Frame == 1)
                    {
                        line5.text = ("[c/2E91B3:Spectral Boots]");
                    }
                    if (Frame == 2)
                    {
                        line5.text = ("[c/39B3DB:Spectral Boots]");
                    }
                    if (Frame == 3)
                    {
                        line5.text = ("[c/BCE3E3:Spectral Boots]");
                    }
                }
            }
        }
Example #13
0
        public override void UpdateEquip(Player player)
        {
            FrameCounter++;        //increase the frameCounter by one
            if (FrameCounter >= 9) //once the frameCounter has reached 3 - change the 10 to change how fast the projectile animates
            {
                FrameCounter = 0;
                Frame       += Switch; //go to the next frame
                if (Frame > 2)         //if past the last frame
                {
                    Switch *= -1;
                }
                else if (Frame < 1)
                {
                    Switch *= -1;
                }
            }
            VampPlayer        p = player.GetModPlayer <VampPlayer>();
            KnifeDamagePlayer d = player.GetModPlayer <KnifeDamagePlayer>();

            if (NPC.downedBoss2)
            {
                SpeedIncrease        = 0.01f;
                item.value           = Item.sellPrice(0, 2, 0, 0);
                item.defense         = 1;
                p.DefenseExtraLives += 1;
                ManaRegen            = 1;
            }
            if (NPC.downedQueenBee)
            {
                SpeedIncrease = 0.02f;
                item.value    = Item.sellPrice(0, 3, 0, 0);
            }
            if (NPC.downedBoss3)
            {
                SpeedIncrease        = 0.03f;
                item.value           = Item.sellPrice(0, 4, 0, 0);
                item.defense         = 2;
                p.DefenseExtraLives += 2;
            }
            if (Main.hardMode)
            {
                SpeedIncrease = 0.04f;
                item.value    = Item.sellPrice(0, 5, 0, 0);
                item.defense  = 4;
                ManaRegen     = 2;
            }
            if (NPC.downedMechBoss1)
            {
                SpeedIncrease = 0.05f;
                item.value    = Item.sellPrice(0, 6, 0, 0);
                item.defense  = 5;
            }
            if (NPC.downedMechBoss2)
            {
                SpeedIncrease = 0.06f;
                item.value    = Item.sellPrice(0, 7, 0, 0);
                item.defense  = 6;
            }
            if (NPC.downedMechBoss3)
            {
                SpeedIncrease        = 0.07f;
                item.value           = Item.sellPrice(0, 8, 0, 0);
                item.defense         = 7;
                p.DefenseExtraLives += 3;
                ManaRegen            = 3;
            }
            if (NPC.downedPlantBoss)
            {
                SpeedIncrease        = 0.08f;
                item.value           = Item.sellPrice(0, 9, 0, 0);
                item.defense         = 9;
                p.DefenseExtraLives += 4;
                ManaRegen            = 4;
            }
            if (NPC.downedGolemBoss)
            {
                SpeedIncrease = 0.09f;
                item.value    = Item.sellPrice(0, 10, 0, 0);
                item.defense  = 10;
            }
            if (NPC.downedFishron)
            {
                SpeedIncrease        = 0.10f;
                item.value           = Item.sellPrice(0, 12, 0, 0);
                item.defense         = 12;
                p.DefenseExtraLives += 5;
            }
            if (NPC.downedAncientCultist)
            {
                SpeedIncrease        = 0.11f;
                item.value           = Item.sellPrice(0, 14, 0, 0);
                item.defense         = 14;
                p.DefenseExtraLives += 6;
            }
            if (NPC.downedTowers)
            {
                SpeedIncrease        = 0.12f;
                item.value           = Item.sellPrice(0, 16, 0, 0);
                item.defense         = 18;
                p.DefenseExtraLives += 7;
            }
            if (NPC.downedMoonlord)
            {
                SpeedIncrease        = 0.15f;
                item.value           = Item.sellPrice(0, 20, 0, 0);
                item.defense         = 22;
                p.DefenseExtraLives += 10;
                ManaRegen            = 5;
            }
            player.moveSpeed += SpeedIncrease;
            if (player.velocity.X > 3 || player.velocity.X < -3 || player.velocity.Y > 3 || player.velocity.Y < -3)
            {
                Counter++;
                if (Counter > 12 && player.statMana < player.statManaMax2)
                {
                    player.statMana += ManaRegen;
                    Counter          = 0;
                }
            }
        }
        public override void ModifyTooltips(List <TooltipLine> tooltips)
        {
            if (NPC.downedBoss2)
            {
                percentage = 5;
                numProj    = 1;
            }
            if (NPC.downedQueenBee)
            {
                percentage = 6;
                numProj    = 2;
            }
            if (NPC.downedBoss3)
            {
                percentage = 8;
                numProj    = 3;
            }
            if (Main.hardMode)
            {
                percentage = 10;
                numProj    = 4;
            }
            if (NPC.downedMechBoss1)
            {
                percentage = 12;
                numProj    = 5;
            }
            if (NPC.downedMechBoss2)
            {
                percentage = 14;
                numProj    = 6;
            }
            if (NPC.downedMechBoss3)
            {
                percentage = 16;
                numProj    = 7;
            }
            if (NPC.downedPlantBoss)
            {
                percentage = 18;
                numProj    = 8;
            }
            if (NPC.downedGolemBoss)
            {
                percentage = 20;
                numProj    = 9;
            }
            if (NPC.downedFishron)
            {
                percentage = 22;
                numProj    = 10;
            }
            if (NPC.downedAncientCultist)
            {
                percentage = 25;
                numProj    = 11;
            }
            if (NPC.downedTowers)
            {
                percentage = 30;
                numProj    = 12;
            }
            KnifeDamagePlayer d     = Main.LocalPlayer.GetModPlayer <KnifeDamagePlayer>();
            VampPlayer        p     = Main.LocalPlayer.GetModPlayer <VampPlayer>();
            TooltipLine       line2 = new TooltipLine(mod, "Face", "Adds: " + Math.Round((p.DelayAdd / 60), 3) + " seconds to 'Blood Essence' decay delay");

            line2.overrideColor = new Color(255, 60, 28);
            tooltips.Add(line2);
            TooltipLine line = new TooltipLine(mod, "Face", "+" + (int)(((d.knifeDamageMult * 100) * 0.00341) * 100) + "% Knife Damage");

            line.overrideColor = new Color(255, 60, 28);
            TooltipLine line6 = new TooltipLine(mod, "Face", "+" + StatManaBonus + " Mana\n+" + StatLifeBonus + " Life");

            line6.overrideColor = new Color(255, 60, 28);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line);
            }
            if (NPC.downedBoss3)
            {
                tooltips.Add(line6);
            }

            if (p.PsionicArmorSet)
            {
                TooltipLine line4 = new TooltipLine(mod, "Face", "Set Bonus:");
                line4.overrideColor = new Color(255, 70, 38);
                tooltips.Add(line4);
                TooltipLine line3 = new TooltipLine(mod, "Face", "+ 4% chance to spawn " + numProj + " 'homing projectiles'");
                line3.overrideColor = new Color(255, 70, 38);
                tooltips.Add(line3);
            }

            foreach (TooltipLine line5 in tooltips)
            {
                if (line5.mod == "Terraria" && line5.Name == "Equipable")
                {
                    line5.overrideColor = new Color(255, 40, 20);
                }
                if (line5.mod == "Terraria" && line5.Name == "Defense")
                {
                    line5.overrideColor = new Color(235, 32, 12);
                }
                if (line5.mod == "Terraria" && line5.Name == "Tooltip0")
                {
                    line5.overrideColor = new Color(215, 20, 2);
                }
                if (line5.mod == "Terraria" && line5.Name == "ItemName")
                {
                    if (Frame == 0)
                    {
                        line5.text = ("[c/FF3333:Psionic Chestplate]");
                    }
                    if (Frame == 1)
                    {
                        line5.text = ("[c/B48C8C:Ps][c/FF3333:ionic Chestplate]");
                    }
                    if (Frame == 2)
                    {
                        line5.text = ("[c/75D6D6:Ps][c/B48C8C:io][c/FF3333:nic Chestplate]");
                    }
                    if (Frame == 3)
                    {
                        line5.text = ("[c/B48C8C:Ps][c/75D6D6:io][c/B48C8C:ni][c/FF3333:c Chestplate]");
                    }
                    if (Frame == 4)
                    {
                        line5.text = ("[c/FF3333:Ps][c/B48C8C:io][c/75D6D6:ni][c/B48C8C:c][c/FF3333: Chestplate]");
                    }
                    if (Frame == 5)
                    {
                        line5.text = ("[c/FF3333:Psio][c/B48C8C:ni][c/75D6D6:c][c/B48C8C: Ch][c/FF3333:estplate]");
                    }
                    if (Frame == 6)
                    {
                        line5.text = ("[c/FF3333:Psioni][c/B48C8C:c][c/75D6D6: Ch][c/B48C8C:es][c/FF3333:tplate]");
                    }
                    if (Frame == 7)
                    {
                        line5.text = ("[c/FF3333:Psionic][c/B48C8C: Ch][c/75D6D6:es][c/B48C8C:tp][c/FF3333:late]");
                    }
                    if (Frame == 8)
                    {
                        line5.text = ("[c/FF3333:Psionic Ch][c/B48C8C:es][c/75D6D6:tp][c/B48C8C:la][c/FF3333:te]");
                    }
                    if (Frame == 9)
                    {
                        line5.text = ("[c/FF3333:Psionic Ches][c/B48C8C:tp][c/75D6D6:la][c/B48C8C:te]");
                    }
                    if (Frame == 10)
                    {
                        line5.text = ("[c/FF3333:Psionic Chestp][c/B48C8C:la][c/75D6D6:te]");
                    }
                    if (Frame == 11)
                    {
                        line5.text = ("[c/FF3333:Psionic Chestpla][c/B48C8C:te]");
                    }
                    if (Frame == 12)
                    {
                        line5.text = ("[c/FF3333:Psionic Chestplate]");
                    }
                }
            }
        }
        public override void UpdateEquip(Player player)
        {
            FrameCounter++;        //increase the frameCounter by one
            if (FrameCounter >= 4) //once the frameCounter has reached 3 - change the 10 to change how fast the projectile animates
            {
                FrameCounter = 0;
                Frame++;        //go to the next frame
                if (Frame > 12) //if past the last frame
                {
                    Frame = 0;  //go back to the first frame
                }
            }
            VampPlayer        p = player.GetModPlayer <VampPlayer>();
            KnifeDamagePlayer d = player.GetModPlayer <KnifeDamagePlayer>();

            p.DelayAdd = 10;
            if (NPC.downedBoss2)
            {
                p.DelayAdd         = 20;
                d.knifeDamageMult += 0.05f;
                item.value         = Item.sellPrice(0, 2, 0, 0);
                item.defense       = 5;
            }
            if (NPC.downedQueenBee)
            {
                p.DelayAdd         = 30;
                d.knifeDamageMult += 0.06f;
                item.value         = Item.sellPrice(0, 3, 0, 0);
            }
            if (NPC.downedBoss3)
            {
                p.DelayAdd         = 30;
                d.knifeDamageMult += 0.08f;
                item.value         = Item.sellPrice(0, 4, 0, 0);
                item.defense       = 7;
                StatLifeBonus      = 5;
                StatManaBonus      = 5;
            }
            if (Main.hardMode)
            {
                p.DelayAdd         = 40;
                d.knifeDamageMult += 0.10f;
                item.value         = Item.sellPrice(0, 5, 0, 0);
                item.defense       = 10;
                StatLifeBonus      = 10;
                StatManaBonus      = 10;
            }
            if (NPC.downedMechBoss1)
            {
                p.DelayAdd         = 50;
                d.knifeDamageMult += 0.12f;
                item.value         = Item.sellPrice(0, 6, 0, 0);
                item.defense       = 12;
            }
            if (NPC.downedMechBoss2)
            {
                p.DelayAdd         = 55;
                d.knifeDamageMult += 0.14f;
                item.value         = Item.sellPrice(0, 7, 0, 0);
                item.defense       = 13;
            }
            if (NPC.downedMechBoss3)
            {
                p.DelayAdd         = 60;
                d.knifeDamageMult += 0.16f;
                item.value         = Item.sellPrice(0, 8, 0, 0);
                item.defense       = 14;
                StatLifeBonus      = 15;
                StatManaBonus      = 15;
            }
            if (NPC.downedPlantBoss)
            {
                p.DelayAdd         = 70;
                d.knifeDamageMult += 0.18f;
                item.value         = Item.sellPrice(0, 9, 0, 0);
                item.defense       = 16;
            }
            if (NPC.downedGolemBoss)
            {
                p.DelayAdd         = 80;
                d.knifeDamageMult += 0.20f;
                item.value         = Item.sellPrice(0, 10, 0, 0);
                item.defense       = 17;
                StatLifeBonus      = 20;
                StatManaBonus      = 20;
            }
            if (NPC.downedFishron)
            {
                p.DelayAdd         = 90;
                d.knifeDamageMult += 0.22f;
                item.value         = Item.sellPrice(0, 12, 0, 0);
                item.defense       = 18;
            }
            if (NPC.downedAncientCultist)
            {
                p.DelayAdd         = 100;
                d.knifeDamageMult += 0.25f;
                item.value         = Item.sellPrice(0, 14, 0, 0);
                item.defense       = 22;
            }
            if (NPC.downedTowers)
            {
                p.DelayAdd         = 120;
                d.knifeDamageMult += 0.30f;
                item.value         = Item.sellPrice(0, 16, 0, 0);
                item.defense       = 26;
                StatLifeBonus      = 30;
                StatManaBonus      = 30;
            }
            if (NPC.downedMoonlord)
            {
                p.DelayAdd         = 150;
                item.value         = Item.sellPrice(0, 20, 0, 0);
                d.knifeDamageMult += 0.36f;
                item.defense       = 34;
                StatLifeBonus      = 40;
                StatManaBonus      = 40;
            }
            if (StatManaBonus > 0)
            {
                player.statManaMax2 += StatManaBonus;
                player.statLifeMax2 += StatLifeBonus;
            }
        }
Example #16
0
        public override void ModifyTooltips(List <TooltipLine> tooltips)
        {
            VampPlayer        p    = Main.LocalPlayer.GetModPlayer <VampPlayer>();
            KnifeDamagePlayer d    = Main.LocalPlayer.GetModPlayer <KnifeDamagePlayer>();
            TooltipLine       line = new TooltipLine(mod, "Face", "+" + (int)(((d.knifeDamageMult * 100) * 0.00341) * 100) + "% Knife Damage");

            line.overrideColor = new Color(160, 0, 0);
            TooltipLine line2 = new TooltipLine(mod, "Face", "+" + StatLifeBonus + " Health");

            line2.overrideColor = new Color(160, 0, 0);
            if (NPC.downedBoss2)
            {
                tooltips.Add(line);
            }
            if (NPC.downedBoss3)
            {
                tooltips.Add(line2);
            }

            if (p.VampiricArmorSet)
            {
                TooltipLine line4 = new TooltipLine(mod, "Face", "Set Bonus:");
                line4.overrideColor = new Color(180, 0, 0);
                tooltips.Add(line4);
                TooltipLine line3 = new TooltipLine(mod, "Face", "Enemies are more likely to target you\nHave a " + ((2f * p.VampiricSetScaler) / 10f) + "% Chance to steal the life of the enemies around you upon being hit");
                line3.overrideColor = new Color(180, 0, 0);
                tooltips.Add(line3);
            }

            foreach (TooltipLine line5 in tooltips)
            {
                if (line5.mod == "Terraria" && line5.Name == "Equipable")
                {
                    line5.overrideColor = new Color(160, 0, 0);
                }
                if (line5.mod == "Terraria" && line5.Name == "Defense")
                {
                    line5.overrideColor = new Color(160, 0, 0);
                }
                if (line5.mod == "Terraria" && line5.Name == "Tooltip0")
                {
                    line5.overrideColor = new Color(160, 0, 0);
                }
                if (line5.mod == "Terraria" && line5.Name == "ItemName")
                {
                    if (Frame == 0)
                    {
                        line5.text = ("[c/3B0000:Vampiric Chestplate]");
                    }
                    if (Frame == 1)
                    {
                        line5.text = ("[c/730600:Vampiric Chestplate]");
                    }
                    if (Frame == 2)
                    {
                        line5.text = ("[c/AD0900:Vampiric Chestplate]");
                    }
                    if (Frame == 3)
                    {
                        line5.text = ("[c/730600:Vampiric Chestplate]");
                    }
                }
            }
        }