From ef791d2b964566d04e277b2a27b639f7fb77a09b Mon Sep 17 00:00:00 2001 From: Xyk Date: Tue, 22 Aug 2023 12:50:02 -0700 Subject: [PATCH 001/138] Reworked Radiant Ooze, Living Dew, Honey Dew, and Ambrosial Ampoule Radiant Ooze: Effects happen at all times rather than just night, this was supposed to be a thing a while ago, but only the tooltip was changed life regen 4 -> 3 Now has a natural life regen boost of 2 Living Dew: 20% move speed and jump speed, 12% decreased damage, moved to early hardmode Honey Dew: +30 max life You have Honey-like life regen Halves how long you are afflicted with sickness debuffs When you are afflicted with a sickness debuff you quickly heal (1 hp per 12 frames you have a sickness debuff) Ambrosial Ampoule: You emit light +50 max life Your life regen is increased by 5 Your natural life regen is greatly improved (+4) Halves how long you are afflicted with sickness debuffs When you are afflicted with a sickness debuff you quickly heal (1 hp per 10 frames you have a sickness debuff) Moved to post Golem --- CalPlayer/CalamityPlayer.cs | 6 +- CalPlayer/CalamityPlayerLifeRegen.cs | 12 ++- CalPlayer/CalamityPlayerMiscEffects.cs | 79 +++++++++++++++++-- CalamityLists.cs | 16 +++- Items/Accessories/AmbrosialAmpoule.cs | 18 +---- Items/Accessories/HoneyDew.cs | 33 ++------ Items/Accessories/LivingDew.cs | 21 +++-- .../Mods.CalamityMod.Items.Accessories.hjson | 28 ++++--- Utilities/PlayerUtils.cs | 2 +- 9 files changed, 138 insertions(+), 77 deletions(-) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index c4a4bca9b0..0e0d214893 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -470,6 +470,9 @@ namespace CalamityMod.CalPlayer public bool gShell = false; public bool tortShell = false; public bool absorber = false; + public bool hDew = false; + public int HoneyDewHealCooldown = 0; + public int AmbrosialAmpouleHealCooldown = 0; public bool aAmpoule = false; public bool rOoze = false; public bool fBarrier = false; @@ -812,6 +815,7 @@ namespace CalamityMod.CalPlayer public bool fishAlert = false; public bool clamity = false; public bool NOU = false; + public bool absorberAffliction = false; public bool sulphurPoison = false; public bool nightwither = false; public bool eutrophication = false; @@ -1079,7 +1083,6 @@ namespace CalamityMod.CalPlayer public bool witheringWeaponEnchant = false; public bool witheredDebuff = false; - public bool absorberAffliction = false; public int witheredWeaponHoldTime = 0; public int witheringDamageDone = 0; @@ -1572,6 +1575,7 @@ namespace CalamityMod.CalPlayer gShell = false; tortShell = false; absorber = false; + hDew = false; aAmpoule = false; rOoze = false; fBarrier = false; diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index d358a1c42f..8eab5088e1 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -673,9 +673,17 @@ namespace CalamityMod.CalPlayer if (trinketOfChi || chiRegen) Player.lifeRegen += 2; - if (rOoze) - Player.lifeRegen += 4; + if (rOoze && !aAmpoule) + { + Player.lifeRegen += 3; + Player.lifeRegenTime += 2; + } + if (aAmpoule) + { + Player.lifeRegen += 5; + Player.lifeRegenTime += 4; + } if (ursaSergeant) { diff --git a/CalPlayer/CalamityPlayerMiscEffects.cs b/CalPlayer/CalamityPlayerMiscEffects.cs index 4e101ef4f9..efd9ad6947 100644 --- a/CalPlayer/CalamityPlayerMiscEffects.cs +++ b/CalPlayer/CalamityPlayerMiscEffects.cs @@ -1,6 +1,7 @@ using System; using System.Collections.Generic; using System.Linq; +using System.Security.Cryptography.X509Certificates; using System.Text; using CalamityMod.Balancing; using CalamityMod.Buffs.DamageOverTime; @@ -1577,22 +1578,84 @@ namespace CalamityMod.CalPlayer Player.GetDamage() += 0.1f; } - // Ambrosial Ampoule bonus and other light-granting bonuses + if (hDew && !aAmpoule) + { + if (HoneyDewHealCooldown == 12) + HoneyDewHealCooldown = 0; + Player.statLifeMax2 += 30; + for (int l = 0; l < Player.MaxBuffs; l++) + { + int hasBuff = Player.buffType[l]; + if (Player.buffTime[l] > 2 && CalamityLists.sicknessDebuffList.Contains(hasBuff)) + { + Player.buffTime[l]--; + if (HoneyDewHealCooldown == 0) + { + HoneyDewHealCooldown++; + Player.Heal(1); + } + else + HoneyDewHealCooldown++; + } + } + //Honey Like life regen, does not work if you have honey buff + if (!Player.honey && Player.lifeRegen < 0) + { + Player.lifeRegen += 2; + if (Player.lifeRegen > 0) + Player.lifeRegen = 0; + } + if (!Player.honey) + { + Player.lifeRegenTime += 1; + Player.lifeRegen += 2; + } + } + + // Radiant Ooze light-granting float[] light = new float[3]; - if ((rOoze && !Main.dayTime) || aAmpoule) + if (rOoze && !aAmpoule) { light[0] += 1f; light[1] += 1f; light[2] += 0.6f; } + + // Ambrosial Ampoule bonus and other light-granting bonuses if (aAmpoule) { - Player.endurance += 0.05f; - Player.buffImmune[BuffID.Frozen] = true; - Player.buffImmune[BuffID.Chilled] = true; - Player.buffImmune[BuffID.Frostburn] = true; - Player.buffImmune[BuffID.CursedInferno] = true; - Player.buffImmune[ModContent.BuffType()] = true; + light[0] += 1.3f; + light[1] += 1.3f; + light[2] += 0.8f; + } + if (aAmpoule) + { + if (AmbrosialAmpouleHealCooldown == 10) + AmbrosialAmpouleHealCooldown = 0; + Player.statLifeMax2 += 50; + for (int l = 0; l < Player.MaxBuffs; l++) + { + int hasBuff = Player.buffType[l]; + if (Player.buffTime[l] > 2 && CalamityLists.sicknessDebuffList.Contains(hasBuff)) + { + Player.buffTime[l]--; + if (AmbrosialAmpouleHealCooldown == 0) + { + AmbrosialAmpouleHealCooldown++; + Player.Heal(1); + } + else + AmbrosialAmpouleHealCooldown++; + } + } + if (Player.lifeRegen < 0) + { + Player.lifeRegen += 2; + if (Player.lifeRegen > 0) + Player.lifeRegen = 0; + } + + } if (cFreeze) { diff --git a/CalamityLists.cs b/CalamityLists.cs index 878f01aa30..5e7783f114 100644 --- a/CalamityLists.cs +++ b/CalamityLists.cs @@ -87,6 +87,7 @@ namespace CalamityMod public static List friendlyBeeList; public static List hardModeNerfList; public static List debuffList; + public static List sicknessDebuffList; public static List alcoholList; public static List spearAutoreuseList; public static List pumpkinMoonBuffList; @@ -1155,7 +1156,20 @@ namespace CalamityMod BuffType(), BuffType(), BuffType(), - BuffType() + BuffType(), + BuffType() + }; + + sicknessDebuffList = new List() + { + BuffID.Poisoned, + BuffID.Venom, + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType() }; alcoholList = new List() diff --git a/Items/Accessories/AmbrosialAmpoule.cs b/Items/Accessories/AmbrosialAmpoule.cs index e5c3c33fd1..b08f3bcf83 100644 --- a/Items/Accessories/AmbrosialAmpoule.cs +++ b/Items/Accessories/AmbrosialAmpoule.cs @@ -12,11 +12,10 @@ namespace CalamityMod.Items.Accessories public new string LocalizationCategory => "Items.Accessories"; public override void SetDefaults() { - Item.defense = 6; Item.width = 20; Item.height = 20; - Item.value = CalamityGlobalItem.Rarity5BuyPrice; - Item.rare = ItemRarityID.Pink; + Item.value = CalamityGlobalItem.Rarity8BuyPrice; + Item.rare = ItemRarityID.Yellow; Item.accessory = true; } @@ -24,23 +23,14 @@ namespace CalamityMod.Items.Accessories { CalamityPlayer modPlayer = player.Calamity(); modPlayer.aAmpoule = true; - modPlayer.rOoze = true; } public override void AddRecipes() { CreateRecipe(). - AddIngredient(). + AddIngredient(). AddIngredient(). - AddIngredient(5). - AddIngredient(10). - AddTile(TileID.MythrilAnvil). - Register(); - - CreateRecipe(). - AddIngredient(). - AddIngredient(). - AddIngredient(5). + AddIngredient(3). AddIngredient(10). AddTile(TileID.MythrilAnvil). Register(); diff --git a/Items/Accessories/HoneyDew.cs b/Items/Accessories/HoneyDew.cs index 055720f5f6..044ec06780 100644 --- a/Items/Accessories/HoneyDew.cs +++ b/Items/Accessories/HoneyDew.cs @@ -21,38 +21,17 @@ namespace CalamityMod.Items.Accessories public override void UpdateAccessory(Player player, bool hideVisual) { CalamityPlayer modPlayer = player.Calamity(); - modPlayer.beeResist = true; - - if (player.ZoneJungle) - { - player.lifeRegen += 1; - player.statDefense += 9; - player.endurance += 0.05f; - } - - player.buffImmune[BuffID.Venom] = true; - player.buffImmune[BuffID.Poisoned] = true; - - if (!player.honey && player.lifeRegen < 0) - { - player.lifeRegen += 2; - if (player.lifeRegen > 0) - player.lifeRegen = 0; - } - - player.lifeRegenTime += 1; - player.lifeRegen += 2; + modPlayer.hDew = true; } public override void AddRecipes() { CreateRecipe(). - AddIngredient(). - AddIngredient(ItemID.BottledHoney, 10). - AddIngredient(2). - AddIngredient(ItemID.ButterflyDust). - AddIngredient(3). - AddTile(TileID.MythrilAnvil). + AddIngredient(ItemID.JungleSpores, 12). + AddIngredient(5). + AddIngredient(3). + AddIngredient(ItemID.BottledHoney, 5). + AddTile(TileID.Anvils). Register(); } } diff --git a/Items/Accessories/LivingDew.cs b/Items/Accessories/LivingDew.cs index 7faeb35edd..9827ad277f 100644 --- a/Items/Accessories/LivingDew.cs +++ b/Items/Accessories/LivingDew.cs @@ -12,28 +12,27 @@ namespace CalamityMod.Items.Accessories { Item.width = 34; Item.height = 24; - Item.value = CalamityGlobalItem.Rarity3BuyPrice; - Item.rare = ItemRarityID.Orange; + Item.value = CalamityGlobalItem.Rarity5BuyPrice; + Item.rare = ItemRarityID.Pink; Item.accessory = true; } public override void UpdateAccessory(Player player, bool hideVisual) { - if (player.ZoneJungle) - { - player.lifeRegen += 1; - player.statDefense += 5; - player.endurance += 0.05f; - } - player.buffImmune[BuffID.Poisoned] = true; + //20% Movespeed and Jumpspeed, 12% reduced damage + player.moveSpeed += 0.2f; + player.jumpSpeedBoost += 1f; + player.GetDamage() -= 0.12f; } public override void AddRecipes() { CreateRecipe(). - AddIngredient(ItemID.Bezoar). - AddIngredient(ItemID.Vine, 2). + AddIngredient(ItemID.JungleSpores, 12). AddIngredient(5). + AddIngredient(3). + //replace with water essence later + AddIngredient(5). AddTile(TileID.Anvils). Register(); } diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 5cd7eda970..7cb4285b7e 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -116,8 +116,11 @@ AmbrosialAmpoule: { Tooltip: ''' You emit light - 5% increased damage reduction and increased life regen - Grants immunity to the Frozen, Chilled, Frostburn, Cursed Inferno and Burning Blood debuffs + +50 max life + Your life regen is increased by 5 + Your natural life regen is greatly improved + Halves how long you are afflicted with sickness debuffs + When you are afflicted with a sickness debuff you quickly heal ''' } @@ -934,10 +937,10 @@ HoneyDew: { DisplayName: Honey Dew Tooltip: ''' - 5% increased damage reduction, +9 defense and increased life regen while in the Jungle - Poison and Venom immunity - Honey-like life regen with no speed penalty - Most bee/hornet enemies and projectiles do 75% damage to you + +30 max life + You have Honey-like life regen + Halves how long you are afflicted with sickness debuffs + When you are afflicted with a sickness debuff you quickly heal ''' } @@ -1007,11 +1010,7 @@ LifeJelly: { LivingDew: { DisplayName: Living Dew - Tooltip: - ''' - 5% increased damage reduction, +5 defense, and increased life regen while in the Jungle - Immunity to Poison - ''' + Tooltip: 20% increased movement and jump speed, but 12% reduced damage } LumenousAmulet: { @@ -1311,7 +1310,12 @@ QuiverofNihility: { RadiantOoze: { DisplayName: Radiant Ooze - Tooltip: You emit light and regen life more quickly + Tooltip: + ''' + You produce light + Your life regen is increased by 3 + Your natural life regen is improved + ''' } RaidersTalisman: { diff --git a/Utilities/PlayerUtils.cs b/Utilities/PlayerUtils.cs index 452c1edf1d..3bb1704ce4 100644 --- a/Utilities/PlayerUtils.cs +++ b/Utilities/PlayerUtils.cs @@ -175,7 +175,7 @@ namespace CalamityMod light += 1; if (mp.aAmpoule) light += 1; - else if (mp.rOoze && !Main.dayTime) // radiant ooze and ampoule/higher don't stack + else if (mp.rOoze) // radiant ooze and ampoule/higher don't stack light += 1; if (mp.aquaticEmblem && underwater) light += 1; From 238eedc551f42a9368b37b5bcea011c0454372d8 Mon Sep 17 00:00:00 2001 From: Xyk Date: Tue, 22 Aug 2023 16:30:36 -0700 Subject: [PATCH 002/138] Added Purity (reworked Astral Arcanum) Crafted with Celestial Jewel and Ambrosial Ampule post Providence Effects: You emit light +80 max life Your life regen is increased by 5 Your natural life regen is greatly improved (by 6) Greatly reduces how long you are afflicted with debuffs (they last 1/3 or the duration) When you are afflicted with a debuff you heal rapidly (1hp every 6 frames you have the debuff) and gain 18 defense Boosts life regen even while under the effects of a damaging debuff (an additional +5 life regen) Press [KEY] to toggle teleportation UI while no bosses are alive (this effect will be removed later) Crown Jewel defense 5 -> 4 Celestial Jewel defense 8 -> 6 both now activate from ALL debuffs, not just DoT --- CalPlayer/CalamityPlayer.cs | 9 +- CalPlayer/CalamityPlayerLifeRegen.cs | 80 ++++++++++-------- CalPlayer/CalamityPlayerMiscEffects.cs | 14 ++- CalamityKeybinds.cs | 6 +- CalamityMod.cs | 4 +- Items/Accessories/AmbrosialAmpoule.cs | 1 - Items/Accessories/AstralArcanum.png | Bin 1102 -> 0 bytes Items/Accessories/CelestialJewel.cs | 2 +- Items/Accessories/CrownJewel.cs | 2 +- .../{AstralArcanum.cs => Purity.cs} | 21 +++-- Items/Accessories/Purity.png | Bin 0 -> 7621 bytes .../Mods.CalamityMod.Items.Accessories.hjson | 21 +++-- .../en-US/Mods.CalamityMod.Keybinds.hjson | 2 +- .../en-US/Mods.CalamityMod.Status.Death.hjson | 4 +- Systems/UIManagementSystem.cs | 2 +- ...alArcanumCircles.png => PurityCircles.png} | Bin UI/{AstralArcanumUI.cs => PurityUI.cs} | 4 +- 17 files changed, 99 insertions(+), 73 deletions(-) delete mode 100644 Items/Accessories/AstralArcanum.png rename Items/Accessories/{AstralArcanum.cs => Purity.cs} (66%) create mode 100644 Items/Accessories/Purity.png rename UI/MiscTextures/{AstralArcanumCircles.png => PurityCircles.png} (100%) rename UI/{AstralArcanumUI.cs => PurityUI.cs} (98%) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index 0e0d214893..ca11980325 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -473,6 +473,7 @@ namespace CalamityMod.CalPlayer public bool hDew = false; public int HoneyDewHealCooldown = 0; public int AmbrosialAmpouleHealCooldown = 0; + public int PurityHealCooldown = 0; public bool aAmpoule = false; public bool rOoze = false; public bool fBarrier = false; @@ -521,7 +522,7 @@ namespace CalamityMod.CalPlayer public bool elementalHeart = false; public bool crownJewel = false; public bool celestialJewel = false; - public bool astralArcanum = false; + public bool purity = false; public bool harpyRing = false; public bool angelTreads = false; public bool harpyWingBoost = false; //harpy wings + harpy ring @@ -1614,7 +1615,7 @@ namespace CalamityMod.CalPlayer elementalHeart = false; crownJewel = false; celestialJewel = false; - astralArcanum = false; + purity = false; harpyRing = false; angelTreads = false; harpyWingBoost = false; //harpy wings + harpy ring @@ -2886,9 +2887,9 @@ namespace CalamityMod.CalPlayer if (prismaticSet && !Player.HasCooldown(PrismaticLaser.ID) && prismaticLasers <= 0) prismaticLasers = CalamityUtils.SecondsToFrames(35f); } - if (CalamityKeybinds.AstralArcanumUIHotkey.JustPressed && astralArcanum && !areThereAnyDamnBosses) + if (CalamityKeybinds.PurityUIHotkey.JustPressed && purity && !areThereAnyDamnBosses) { - AstralArcanumUI.Toggle(); + PurityUI.Toggle(); } if (CalamityKeybinds.AstralTeleportHotKey.JustPressed) { diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index 8eab5088e1..40844b02bc 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -13,6 +13,8 @@ using Terraria.ModLoader; using Terraria.DataStructures; using CalamityMod.Systems; using System.Linq; +using CalamityMod.Buffs.Pets; +using CalamityMod.Particles; namespace CalamityMod.CalPlayer { @@ -507,58 +509,68 @@ namespace CalamityMod.CalPlayer } } - if (celestialJewel || astralArcanum) + if (celestialJewel || purity) { - bool lesserEffect = false; + Player.lifeRegen += 5; + Player.lifeRegenTime += 6; + if (PurityHealCooldown == 5) + PurityHealCooldown = 0; + Player.statLifeMax2 += 80; for (int l = 0; l < Player.MaxBuffs; l++) { int hasBuff = Player.buffType[l]; - lesserEffect = CalamityLists.alcoholList.Contains(hasBuff); - } - - int defenseBoost = astralArcanum ? 15 : 11; - if (lesserEffect) - { - Player.lifeRegen += astralArcanum ? 2 : 1; - Player.statDefense += defenseBoost; - } - else - { - if (Player.lifeRegen < 0) + if (Player.buffTime[l] > 3 && CalamityLists.debuffList.Contains(hasBuff)) { + Player.buffTime[l] -= 2; + if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; + //add extra regen when effected by a debuff + Player.lifeRegen += 5; + Player.statDefense += 18; - Player.lifeRegen += astralArcanum ? 6 : 4; - Player.statDefense += defenseBoost; + if (PurityHealCooldown == 0) + { + PurityHealCooldown++; + Player.Heal(1); + } + else + PurityHealCooldown++; } - else - Player.lifeRegen += astralArcanum ? 3 : 2; } } - else if (crownJewel) + + if (celestialJewel && !purity) { - bool lesserEffect = false; + Player.lifeRegen += 2; for (int l = 0; l < Player.MaxBuffs; l++) { int hasBuff = Player.buffType[l]; - lesserEffect = CalamityLists.alcoholList.Contains(hasBuff); - } - - if (lesserEffect) - Player.statDefense += 8; - else - { - if (Player.lifeRegen < 0) + if (Player.buffTime[l] > 2 && CalamityLists.debuffList.Contains(hasBuff)) { if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; - - Player.lifeRegen += 4; + //add extra regen when effected by a debuff + Player.lifeRegen += 2; + Player.statDefense += 12; + } + } + } + + if (crownJewel && !celestialJewel && !purity) + { + Player.lifeRegen += 2; + for (int l = 0; l < Player.MaxBuffs; l++) + { + int hasBuff = Player.buffType[l]; + if (Player.buffTime[l] > 2 && CalamityLists.debuffList.Contains(hasBuff)) + { + if (Player.lifeRegenTime < 1800) + Player.lifeRegenTime = 1800; + //add extra regen when effected by a debuff + Player.lifeRegen += 2; Player.statDefense += 8; } - else - Player.lifeRegen += 2; } } @@ -673,13 +685,13 @@ namespace CalamityMod.CalPlayer if (trinketOfChi || chiRegen) Player.lifeRegen += 2; - if (rOoze && !aAmpoule) + if (rOoze && !aAmpoule && !purity) { Player.lifeRegen += 3; Player.lifeRegenTime += 2; } - if (aAmpoule) + if (aAmpoule && !purity) { Player.lifeRegen += 5; Player.lifeRegenTime += 4; diff --git a/CalPlayer/CalamityPlayerMiscEffects.cs b/CalPlayer/CalamityPlayerMiscEffects.cs index efd9ad6947..a2b17a7288 100644 --- a/CalPlayer/CalamityPlayerMiscEffects.cs +++ b/CalPlayer/CalamityPlayerMiscEffects.cs @@ -1578,7 +1578,7 @@ namespace CalamityMod.CalPlayer Player.GetDamage() += 0.1f; } - if (hDew && !aAmpoule) + if (hDew && !aAmpoule && !purity) { if (HoneyDewHealCooldown == 12) HoneyDewHealCooldown = 0; @@ -1614,7 +1614,7 @@ namespace CalamityMod.CalPlayer // Radiant Ooze light-granting float[] light = new float[3]; - if (rOoze && !aAmpoule) + if (rOoze && !aAmpoule && !purity) { light[0] += 1f; light[1] += 1f; @@ -1622,13 +1622,19 @@ namespace CalamityMod.CalPlayer } // Ambrosial Ampoule bonus and other light-granting bonuses - if (aAmpoule) + if (aAmpoule && !purity) { light[0] += 1.3f; light[1] += 1.3f; light[2] += 0.8f; } - if (aAmpoule) + if (purity) + { + light[0] += 1.2f; + light[1] += 1.7f; + light[2] += 2.7f; + } + if (aAmpoule && !purity) { if (AmbrosialAmpouleHealCooldown == 10) AmbrosialAmpouleHealCooldown = 0; diff --git a/CalamityKeybinds.cs b/CalamityKeybinds.cs index fc27dabb6c..d498511c85 100644 --- a/CalamityKeybinds.cs +++ b/CalamityKeybinds.cs @@ -10,7 +10,7 @@ namespace CalamityMod public static ModKeybind RageHotKey { get; private set; } public static ModKeybind AdrenalineHotKey { get; private set; } public static ModKeybind AstralTeleportHotKey { get; private set; } - public static ModKeybind AstralArcanumUIHotkey { get; private set; } + public static ModKeybind PurityUIHotkey { get; private set; } public static ModKeybind SandCloakHotkey { get; private set; } public static ModKeybind SpectralVeilHotKey { get; private set; } public static ModKeybind PlaguePackHotKey { get; private set; } @@ -29,7 +29,7 @@ namespace CalamityMod BlazingCoreHotKey = KeybindLoader.RegisterKeybind(Mod, "BlazingCoreParry", "N"); SetBonusHotKey = KeybindLoader.RegisterKeybind(Mod, "ArmorSetBonus", "Y"); AstralTeleportHotKey = KeybindLoader.RegisterKeybind(Mod, "AstralTeleport", "P"); - AstralArcanumUIHotkey = KeybindLoader.RegisterKeybind(Mod, "AstralArcanumUIToggle", "O"); + PurityUIHotkey = KeybindLoader.RegisterKeybind(Mod, "PurityUIToggle", "O"); SandCloakHotkey = KeybindLoader.RegisterKeybind(Mod, "SandCloakEffect", "C"); SpectralVeilHotKey = KeybindLoader.RegisterKeybind(Mod, "SpectralVeilTeleport", "Z"); PlaguePackHotKey = KeybindLoader.RegisterKeybind(Mod, "BoosterDash", "Q"); @@ -48,7 +48,7 @@ namespace CalamityMod BlazingCoreHotKey = null; SetBonusHotKey = null; AstralTeleportHotKey = null; - AstralArcanumUIHotkey = null; + PurityUIHotkey = null; SandCloakHotkey = null; SpectralVeilHotKey = null; PlaguePackHotKey = null; diff --git a/CalamityMod.cs b/CalamityMod.cs index 8f665dadcf..de5e30bd06 100644 --- a/CalamityMod.cs +++ b/CalamityMod.cs @@ -361,7 +361,7 @@ namespace CalamityMod RipperUI.Load(); StealthUI.Load(); ChargeMeterUI.Load(); - AstralArcanumUI.Load(this); + PurityUI.Load(this); FlightBar.Load(); // TODO -- Is this not possible to place in ModNPC.Load or ModNPC.SetStaticDefaults ? @@ -465,7 +465,7 @@ namespace CalamityMod RipperUI.Unload(); StealthUI.Unload(); ChargeMeterUI.Unload(); - AstralArcanumUI.Unload(); + PurityUI.Unload(); FlightBar.Unload(); if (!Main.dedServ) diff --git a/Items/Accessories/AmbrosialAmpoule.cs b/Items/Accessories/AmbrosialAmpoule.cs index b08f3bcf83..96716ea559 100644 --- a/Items/Accessories/AmbrosialAmpoule.cs +++ b/Items/Accessories/AmbrosialAmpoule.cs @@ -31,7 +31,6 @@ namespace CalamityMod.Items.Accessories AddIngredient(). AddIngredient(). AddIngredient(3). - AddIngredient(10). AddTile(TileID.MythrilAnvil). Register(); } diff --git a/Items/Accessories/AstralArcanum.png b/Items/Accessories/AstralArcanum.png deleted file mode 100644 index 30af2e08c5dbe320586ad3ece4cab1e66b0b4215..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1102 zcmV-U1hM;xP)hC)ke zXiGwUvZc@lVp|_#AVEdZ8e1jO2uW%_*4Ut?)R<_*?Ze#T=1g|7dFg|<{$K8%xo76i z&hMT%XRe1sC2M!PZUGR!_m})kj%{C(x55Ls+R%Si$03POs0O-0u3c!)*Gytml42gE zB=>IsAn*83<{=AS0$^%xE&z`bf2SqpQecRT`KrhQ=H!X?V?AH4>^?(MGv@Wa9wkct`CJm$m-J%7GHfQV$* zy~?&ph$JR{zNE>xl(oo@vG!|fJRx(!@(<0Q2SB-hZEUDdLW)dqh`2~}v|a|_)0zDM zR7q?&2D0;nE!nLke^jhCcKXT*rd96);Jj}ae)bCh@sd@Hov)Ay4v|a_zxA0^Q?_e5 z0F{{izmAadlf2N^Wyr|xB(WeQgp7-z+6zz!34aY%uSlD}R)AT?OF6 zlm!4B+Bu-^ulh!lnHyRTxXFkT?KR3?Q~!>#PabXoU`Biv02_b5t?t|TBsfGQvqy9D z02sXgPZD6!ydvc&yO$j^BB{M39|#$d5D^lRFYMY%Vq#XY$rrL)i8_0`Wxk$2Uo(ED zfBLLwT=k28B9wDMaU=&wt%THCwj|>(E;Z+f_x8S<*6-L?9|Lfs*_<<^wz4I)mb@8l zLnDCtR^UMZt6ygxS@*KprB3~M6M(Sa{&{?T`VM|cw%9lAl^0T?f!-+qywR(7BT=J& z6%sO^<`fa7z!1rJLX^Dnl#IV3(k@l0T_u;kzaN0N;wBHB?pOgp^U*JqpWR>bgT&}l z5`KH|Pl$Gdi;SIDWET_dsN4iV;`}Yu{$Z`jA0O;FquOJyneSL9Y8q6#>p3nGqTmt{ z37JUPWbmQk2Wh|MzECjJ1Gqb2z6{!ABvvFgY!Y^VTaoZ|&woBJo`fj)L_}jU{)8%u zn+)CEkx*o835lY3%=7&xHNK04=>J1xvJ!GGGA=-q8~^|S diff --git a/Items/Accessories/CelestialJewel.cs b/Items/Accessories/CelestialJewel.cs index 565496846d..99be42768f 100644 --- a/Items/Accessories/CelestialJewel.cs +++ b/Items/Accessories/CelestialJewel.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Accessories public new string LocalizationCategory => "Items.Accessories"; public override void SetDefaults() { - Item.defense = 8; + Item.defense = 6; Item.width = 26; Item.height = 26; Item.value = CalamityGlobalItem.Rarity7BuyPrice; diff --git a/Items/Accessories/CrownJewel.cs b/Items/Accessories/CrownJewel.cs index 617a17cd63..75b74c27da 100644 --- a/Items/Accessories/CrownJewel.cs +++ b/Items/Accessories/CrownJewel.cs @@ -10,7 +10,7 @@ namespace CalamityMod.Items.Accessories public new string LocalizationCategory => "Items.Accessories"; public override void SetDefaults() { - Item.defense = 5; + Item.defense = 4; Item.width = 26; Item.height = 26; Item.value = CalamityGlobalItem.Rarity1BuyPrice; diff --git a/Items/Accessories/AstralArcanum.cs b/Items/Accessories/Purity.cs similarity index 66% rename from Items/Accessories/AstralArcanum.cs rename to Items/Accessories/Purity.cs index c5b266e111..c2a7831067 100644 --- a/Items/Accessories/AstralArcanum.cs +++ b/Items/Accessories/Purity.cs @@ -1,6 +1,7 @@ using CalamityMod.Buffs.DamageOverTime; using CalamityMod.CalPlayer; using CalamityMod.Items.Materials; +using CalamityMod.Items.Placeables; using CalamityMod.Rarities; using System.Collections.Generic; using Terraria; @@ -9,34 +10,36 @@ using Terraria.ModLoader; namespace CalamityMod.Items.Accessories { - public class AstralArcanum : ModItem, ILocalizedModType + [LegacyName("AstralArcanum")] + public class Purity : ModItem, ILocalizedModType { public new string LocalizationCategory => "Items.Accessories"; public override void SetDefaults() { - Item.defense = 12; - Item.width = 26; - Item.height = 26; + Item.defense = 8; + Item.width = 24; + Item.height = 24; Item.accessory = true; Item.value = CalamityGlobalItem.Rarity12BuyPrice; Item.rare = ModContent.RarityType(); } - public override void ModifyTooltips(List list) => list.IntegrateHotkey(CalamityKeybinds.AstralArcanumUIHotkey); + public override void ModifyTooltips(List list) => list.IntegrateHotkey(CalamityKeybinds.PurityUIHotkey); public override void UpdateAccessory(Player player, bool hideVisual) { CalamityPlayer modPlayer = player.Calamity(); - modPlayer.astralArcanum = true; - player.buffImmune[ModContent.BuffType()] = true; + modPlayer.purity = true; } public override void AddRecipes() { CreateRecipe(). AddIngredient(). - AddIngredient(3). - AddIngredient(ItemID.LunarBar, 5). + AddIngredient(). + AddIngredient(1). + AddIngredient(8). + AddIngredient(8). AddTile(TileID.LunarCraftingStation). Register(); } diff --git a/Items/Accessories/Purity.png b/Items/Accessories/Purity.png new file mode 100644 index 0000000000000000000000000000000000000000..5bd31a409e2941cef2417e53b3d6e53e9afa097a GIT binary patch literal 7621 zcmV;$9XjHPP)f6 zXi@@54ZTQ_E-Enz5K6$103tR-RB%L5k){YTDBysjLy@r}iiH7DvFijGMAUI`6dRUF zWUU$Bym{}eS9UO(Z2>7`&z9wUXbV-Il#&6`Y8GKGQ04S2&F6MJnWNa;Ck|;8QE#r9r;7G||@X{|> z%+C|c55>;RS}qbKr-&IQTvLXPlM{>K&(BTgi^a?^4mXV>;xX8n8Ce|RasXz}{8imI52H3ZN4bfe_i~WlJ|C&UW9+{8AKoW!}eExnGFE2re(F+`iE_46#!l9 z0Z_aBhs|Iw0E)7{bq;-T9=d#9QpDmcXDh4R++0fmpKB>E=%LdZt9g$j;($`3&Zthxi`{{&gM}5&R^+h%b~yM9Zd3AWW9ETgVfL z1(`yIK=_}U_z%PWq}jQaiQ4!P(3V&Nr6C$XejWfQDiI(Fdt@un?|lo#M+5oIi_w{w zo%_#%{(V=tO#a9gB!7-$M?^BX5>d|Vn*3S!?g~$*UQipUPL&zMmg;!4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RmU<%mS^>~3~@a%bfW3ngA)e2XZ>t|Z|k{_BQxy0c>K2mobQsW|K?=> zyfyjt_En8|h|1c`WHPy9(hJXwW(yxl0l>I8Bda~6(^+Cm1BOPD%2v~2vnHJ7c<{6U z-1Xj(%%{iwPG;;w?Zj`Di*}N|Hx4{$xS~2So1@ZXMd$9CR7sZO-!*n;0LDZtvM%Gq zz8UPb2K8dWBFa@Iw#~m7;EFf*lI4>sPj)C@vWL`M-}gHP^R^$K+Mw$Vb1x{~(3zWl z10cr8Ixk^kW1v@rG;T_nO$UIbH7b8)x%8udGx$k>&Wg<6;m4YfWcJ=)^c9O6$gigq nowC!hv9B`Kdq0x%zfb=QEP6Cb#-n9900000NkvXXu0mjfSMX%t literal 0 HcmV?d00001 diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 7cb4285b7e..1841fac2e6 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -240,13 +240,18 @@ AsgardsValor: { ''' } -AstralArcanum: { - DisplayName: Astral Arcanum +Purity: { + DisplayName: Purity Tooltip: ''' - Provides immunity to the astral infection debuff + A once infected crystal, now perfectly purified + You emit light + +80 max life + Your life regen is increased by 5 + Your natural life regen is greatly improved + Greatly reduces how long you are afflicted with debuffs + When you are afflicted with a debuff you heal rapidly and gain 18 defense Boosts life regen even while under the effects of a damaging debuff - While under the effects of a damaging debuff you will gain 15 defense Press [KEY] to toggle teleportation UI while no bosses are alive ''' } @@ -354,8 +359,8 @@ CelestialJewel: { DisplayName: Celestial Jewel Tooltip: ''' - Boosts life regen even while under the effects of a damaging debuff - While under the effects of a damaging debuff you will gain 11 defense + Boosts life regen even while under the effects of a debuff + While under the effects of a debuff you will gain 12 defense Press [KEY] to teleport to a random location while no bosses are alive ''' } @@ -451,8 +456,8 @@ CrownJewel: { DisplayName: Crown Jewel Tooltip: ''' - Boosts life regen even while under the effects of a damaging debuff - While under the effects of a damaging debuff you will gain 8 defense + Boosts life regen even while under the effects of a debuff + While under the effects of a debuff you will gain 8 defense ''' } diff --git a/Localization/en-US/Mods.CalamityMod.Keybinds.hjson b/Localization/en-US/Mods.CalamityMod.Keybinds.hjson index b37414be9f..1dbcda7a73 100644 --- a/Localization/en-US/Mods.CalamityMod.Keybinds.hjson +++ b/Localization/en-US/Mods.CalamityMod.Keybinds.hjson @@ -5,7 +5,7 @@ AngelicAllianceBlessing.DisplayName: Angelic Alliance Blessing BoosterDash.DisplayName: Booster Dash SpectralVeilTeleport.DisplayName: Spectral Veil Teleport SandCloakEffect.DisplayName: Sand Cloak Effect -AstralArcanumUIToggle.DisplayName: Astral Arcanum UI Toggle +PurityUIToggle.DisplayName: Purity UI Toggle AstralTeleport.DisplayName: Astral Teleport ArmorSetBonus.DisplayName: Armor Set Bonus AdrenalineMode.DisplayName: Adrenaline Mode diff --git a/Localization/en-US/Mods.CalamityMod.Status.Death.hjson b/Localization/en-US/Mods.CalamityMod.Status.Death.hjson index 3add54bf13..00e6c26998 100644 --- a/Localization/en-US/Mods.CalamityMod.Status.Death.hjson +++ b/Localization/en-US/Mods.CalamityMod.Status.Death.hjson @@ -1,5 +1,5 @@ AbyssDrown1: "{0} is food for the Wyrms." -AbyssDrown2: "Oxygen failed to reach {0} from the depths of the Abyss." +AbyssDrown2: Oxygen failed to reach {0} from the depths of the Abyss. AbyssDrown3: "{0} faded away, lost in the dark waters." AlcoholBig1: "{0} downed too many shots." AlcoholBig2: "{0}'s liver failed." @@ -30,7 +30,7 @@ Riptide2: "{0} was ripped apart by the current." Dragonfire1: "{0}'s ashes scatter in the wind." Dragonfire2: "{0}'s embers fade away in a warm glow." Dragonfire3: "{0} can no longer feel the heat of the dragonfire." -Dragonfire4: "This was a fight {0} could not win." +Dragonfire4: This was a fight {0} could not win. GodSlayerInferno1: "{0} imploded into nothingness." GodSlayerInferno2: "{0}'s body slipped into oblivion." GodSlayerInferno3: "{0} ceased being a part of our universe." diff --git a/Systems/UIManagementSystem.cs b/Systems/UIManagementSystem.cs index a678d6e40c..f8366ace3d 100644 --- a/Systems/UIManagementSystem.cs +++ b/Systems/UIManagementSystem.cs @@ -65,7 +65,7 @@ namespace CalamityMod.Systems // Astral Arcanum overlay (if open) layers.Insert(mouseIndex, new LegacyGameInterfaceLayer("Astral Arcanum UI", delegate () { - AstralArcanumUI.UpdateAndDraw(Main.spriteBatch); + PurityUI.UpdateAndDraw(Main.spriteBatch); return true; }, InterfaceScaleType.None)); diff --git a/UI/MiscTextures/AstralArcanumCircles.png b/UI/MiscTextures/PurityCircles.png similarity index 100% rename from UI/MiscTextures/AstralArcanumCircles.png rename to UI/MiscTextures/PurityCircles.png diff --git a/UI/AstralArcanumUI.cs b/UI/PurityUI.cs similarity index 98% rename from UI/AstralArcanumUI.cs rename to UI/PurityUI.cs index ef5cc8cbfb..c13a151cd9 100644 --- a/UI/AstralArcanumUI.cs +++ b/UI/PurityUI.cs @@ -13,7 +13,7 @@ using Terraria.ModLoader; namespace CalamityMod.UI { // TODO -- This can be made into a ModSystem with simple OnModLoad and Unload hooks. - public static class AstralArcanumUI + public static class PurityUI { enum CircleStyle { @@ -34,7 +34,7 @@ namespace CalamityMod.UI public static void Load(Mod mod) { - CircleTextures = ModContent.Request("CalamityMod/UI/MiscTextures/AstralArcanumCircles", AssetRequestMode.ImmediateLoad).Value; + CircleTextures = ModContent.Request("CalamityMod/UI/MiscTextures/PurityCircles", AssetRequestMode.ImmediateLoad).Value; } public static void Unload() From 0145ac0a7b6e95004524c2f303010596159c172c Mon Sep 17 00:00:00 2001 From: Xyk Date: Thu, 24 Aug 2023 02:45:53 -0700 Subject: [PATCH 003/138] Reworked Jewels and added effects and anti-cheese to Purity Changed the name of Celestial Jewel to Infected Jewel to contrasts Purity Reworked Crown Jewel and Infected Jewel Crown Jewel: Life regen increased by 1 Increases life regen by 3 while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff When afflicted with a debuff, you will gain 8 defense This defense will begin to fade away when you are no longer debuffed Infected Jewel: A beautiful gem that has been corrupted by the astral infection Life regen increased by 2 Increases life regen by 4 while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff When afflicted with a debuff, you will gain 14 defense This defense will begin to fade away when you are no longer debuffed Updated Purity to fit the Jewels new bonus defense decay Purity now works with more debuffs, but if you are debuffed for long enough there is a healing penalty to prevent permanent super healing with stuff like weak brimstone flames and mana burn --- Buffs/Potions/WeaponImbueCrumbling.png | Bin 605 -> 555 bytes Buffs/StatDebuffs/Crumbling.png | Bin 3091 -> 472 bytes CalPlayer/CalamityPlayer.cs | 29 ++-- CalPlayer/CalamityPlayerLifeRegen.cs | 136 ++++++++++++------ CalPlayer/CalamityPlayerMiscEffects.cs | 8 +- CalamityKeybinds.cs | 3 - CalamityLists.cs | 18 ++- .../{CelestialJewel.cs => InfectedJewel.cs} | 13 +- .../{CelestialJewel.png => InfectedJewel.png} | Bin Items/Accessories/Purity.cs | 2 +- .../Mods.CalamityMod.Items.Accessories.hjson | 30 ++-- 11 files changed, 155 insertions(+), 84 deletions(-) rename Items/Accessories/{CelestialJewel.cs => InfectedJewel.cs} (71%) rename Items/Accessories/{CelestialJewel.png => InfectedJewel.png} (100%) diff --git a/Buffs/Potions/WeaponImbueCrumbling.png b/Buffs/Potions/WeaponImbueCrumbling.png index 91c59e28166118d4afd1ab1ee09a17af5143233b..3518e6bf34597418c5b5bfceb7dd9a5d3ce13c30 100644 GIT binary patch delta 530 zcmV+t0`2|X1giv)B!2;OQb$4nuFf3k0005YNklpstHxboe+ z_s+fVoOeFwzH{HpBdb?_R(SyVKOEHf6t4h%10w)5H8(mYG=J3B0dR47Wwd)qzwhMu z6oBx`0$>4w0y&Y)Ba1V}iK$FYPL7KUuZ{Me;VA&ZE9%-F0-{7J1Hj1mC;+i|9Du#; z&72(f4-NrPSzZdj%=D~ro_z##)dm9U_@0rMB;)VOUIIr4hX4dyTa4q8wI~2Rz1?31 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z_Gz4(M6mD>3y^{^?wec!6|$P4XqLd5jg0*B=`@crR6xt8O{aoO{lKN z`z+@y55LdwM8N&tiqtIIz{N+|$D-~d1ZT$~g=3x(sOUj^LU-eDGC9i-cN0HAzX z2?@XrQ2>>nLd*xa)9bwea8<8{3@{o`SEu6u(7tW~FrLms0vPn)0k9`u0DokXQ2=U< zrUn_>w${7vJQ@yAOQ#Z#MF5yBz5zHrKlALH3s^VUDwY7SolgKhUf(<+<^j~QMPexc z_EQNRvX|DO&rcf6e1Kov0Ke=GVAH|d3&>^S032iwLk>_+sb%H=WbpO_RQw>j0|@+c c8Z=-Djl%u;XJ{l=00000Ne4wvM6N<$f?`n1g#Z8m diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index ca11980325..9c0ccf1597 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -472,10 +472,19 @@ namespace CalamityMod.CalPlayer public bool absorber = false; public bool hDew = false; public int HoneyDewHealCooldown = 0; + public int HoneyDewHealSpeed = 12; public int AmbrosialAmpouleHealCooldown = 0; + public int AmbrosialAmpouleHealSpeed = 9; public int PurityHealCooldown = 0; + public int PurityHealSpeed = 5; + //Used to time until you get reduced healing + public int ReducedHealingCounter = 0; + public int CrownJewelBonusDefense = 0; + public int InfectedJewelBonusDefense = 0; + public int PurityBonusDefense = 0; public bool aAmpoule = false; public bool rOoze = false; + public bool JustWasDebuffed = false; public bool fBarrier = false; public bool aBrain = false; public bool amalgam = false; @@ -521,7 +530,7 @@ namespace CalamityMod.CalPlayer public bool coreOfTheBloodGod = false; public bool elementalHeart = false; public bool crownJewel = false; - public bool celestialJewel = false; + public bool infectedJewel = false; public bool purity = false; public bool harpyRing = false; public bool angelTreads = false; @@ -1614,7 +1623,7 @@ namespace CalamityMod.CalPlayer coreOfTheBloodGod = false; elementalHeart = false; crownJewel = false; - celestialJewel = false; + infectedJewel = false; purity = false; harpyRing = false; angelTreads = false; @@ -2891,21 +2900,7 @@ namespace CalamityMod.CalPlayer { PurityUI.Toggle(); } - if (CalamityKeybinds.AstralTeleportHotKey.JustPressed) - { - if (celestialJewel && !areThereAnyDamnBosses) - { - if (Main.netMode == NetmodeID.SinglePlayer) - { - Player.TeleportationPotion(); - SoundEngine.PlaySound(SoundID.Item6, Player.Center); - } - else if (Main.netMode == NetmodeID.MultiplayerClient && Player.whoAmI == Main.myPlayer) - { - NetMessage.SendData(MessageID.RequestTeleportationByServer, -1, -1, null, 0, 0f, 0f, 0f, 0, 0, 0); - } - } - } + if (CalamityKeybinds.BlazingCoreHotKey.JustPressed) { if (blazingCore && blazingCoreParry == 0 && blazingCoreSuccessfulParry == 0) diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index 40844b02bc..52ffd2da5b 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -509,67 +509,123 @@ namespace CalamityMod.CalPlayer } } - if (celestialJewel || purity) + if (purity) { - Player.lifeRegen += 5; + Player.lifeRegen += 4; Player.lifeRegenTime += 6; - if (PurityHealCooldown == 5) + Player.statDefense += PurityBonusDefense; + //heal every 5 frames + if (PurityHealCooldown == PurityHealSpeed) PurityHealCooldown = 0; Player.statLifeMax2 += 80; + bool hasAnyDebuffs = false; for (int l = 0; l < Player.MaxBuffs; l++) { int hasBuff = Player.buffType[l]; - if (Player.buffTime[l] > 3 && CalamityLists.debuffList.Contains(hasBuff)) + if (CalamityLists.debuffList.Contains(hasBuff)) { - Player.buffTime[l] -= 2; - - if (Player.lifeRegenTime < 1800) - Player.lifeRegenTime = 1800; - //add extra regen when effected by a debuff - Player.lifeRegen += 5; - Player.statDefense += 18; - - if (PurityHealCooldown == 0) + if (Player.buffTime[l] > 3) { - PurityHealCooldown++; - Player.Heal(1); + hasAnyDebuffs = true; + //JustWasDebuffed = false; + Player.buffTime[l] -= 2; + + if (Player.lifeRegenTime < 1800) + Player.lifeRegenTime = 1800; + //add extra regen when effected by a debuff + Player.lifeRegen += 6; + PurityBonusDefense = 18; + if (ReducedHealingCounter < 120) + ReducedHealingCounter++; + + //If it's been over 2 seconds with a debuff, Every 15 frames increase the ammount of frames between healing 1, up to a max of 4x the original frames + if (ReducedHealingCounter == 120 && PurityHealSpeed < 20) + if (Player.miscCounter % 15 == 0) + { + PurityHealSpeed++; + } + + if (PurityHealCooldown == 0) + { + PurityHealCooldown++; + Player.Heal(1); + } + else + PurityHealCooldown++; + } + } + } + + if (!hasAnyDebuffs) + { + //recover any heal penalty youve gained as long as youre not currently debuffed + if (PurityHealSpeed > 5) + if (Player.miscCounter % 15 == 0) + PurityHealSpeed--; + //If you're not debuffed and you are back to full healing speed, give the 3 second countdown back + if (PurityHealSpeed == 5) + ReducedHealingCounter = 0; + //Bonus defense goes down by 1 every second after + if (Player.miscCounter % 90 == 0 && PurityBonusDefense > 0) + PurityBonusDefense--; + } + + } + + if (infectedJewel && !purity) + { + bool hasAnyDebuffs = false; + Player.lifeRegen += 2; + Player.statDefense += InfectedJewelBonusDefense; + if (!hasAnyDebuffs) + { + //Bonus defense goes down by 1 every second after + if (Player.miscCounter % 90 == 0 && InfectedJewelBonusDefense > 0) + InfectedJewelBonusDefense--; + } + for (int l = 0; l < Player.MaxBuffs; l++) + { + int hasBuff = Player.buffType[l]; + if (CalamityLists.debuffList.Contains(hasBuff)) + { + if (Player.buffTime[l] > 2) + { + hasAnyDebuffs = true; + if (Player.lifeRegenTime < 1800) + Player.lifeRegenTime = 1800; + //add extra regen when effected by a debuff + Player.lifeRegen += 4; + InfectedJewelBonusDefense = 14; } - else - PurityHealCooldown++; } } } - if (celestialJewel && !purity) + if (crownJewel && !infectedJewel && !purity) { - Player.lifeRegen += 2; - for (int l = 0; l < Player.MaxBuffs; l++) + bool hasAnyDebuffs = false; + Player.lifeRegen += 1; + Player.statDefense += CrownJewelBonusDefense; + if (!hasAnyDebuffs) { - int hasBuff = Player.buffType[l]; - if (Player.buffTime[l] > 2 && CalamityLists.debuffList.Contains(hasBuff)) - { - if (Player.lifeRegenTime < 1800) - Player.lifeRegenTime = 1800; - //add extra regen when effected by a debuff - Player.lifeRegen += 2; - Player.statDefense += 12; - } + //Bonus defense goes down by 1 every second after + if (Player.miscCounter % 90 == 0 && CrownJewelBonusDefense > 0) + CrownJewelBonusDefense--; } - } - - if (crownJewel && !celestialJewel && !purity) - { - Player.lifeRegen += 2; for (int l = 0; l < Player.MaxBuffs; l++) { int hasBuff = Player.buffType[l]; - if (Player.buffTime[l] > 2 && CalamityLists.debuffList.Contains(hasBuff)) + if (CalamityLists.debuffList.Contains(hasBuff)) { - if (Player.lifeRegenTime < 1800) - Player.lifeRegenTime = 1800; - //add extra regen when effected by a debuff - Player.lifeRegen += 2; - Player.statDefense += 8; + if (Player.buffTime[l] > 2) + { + hasAnyDebuffs = true; + if (Player.lifeRegenTime < 1800) + Player.lifeRegenTime = 1800; + //add extra regen when effected by a debuff + Player.lifeRegen += 3; + CrownJewelBonusDefense = 8; + } } } } diff --git a/CalPlayer/CalamityPlayerMiscEffects.cs b/CalPlayer/CalamityPlayerMiscEffects.cs index a2b17a7288..60b7d518db 100644 --- a/CalPlayer/CalamityPlayerMiscEffects.cs +++ b/CalPlayer/CalamityPlayerMiscEffects.cs @@ -1580,7 +1580,8 @@ namespace CalamityMod.CalPlayer if (hDew && !aAmpoule && !purity) { - if (HoneyDewHealCooldown == 12) + //heal ever 12 frames + if (HoneyDewHealCooldown == HoneyDewHealSpeed) HoneyDewHealCooldown = 0; Player.statLifeMax2 += 30; for (int l = 0; l < Player.MaxBuffs; l++) @@ -1636,7 +1637,8 @@ namespace CalamityMod.CalPlayer } if (aAmpoule && !purity) { - if (AmbrosialAmpouleHealCooldown == 10) + //heal every 9 frames + if (AmbrosialAmpouleHealCooldown == AmbrosialAmpouleHealSpeed) AmbrosialAmpouleHealCooldown = 0; Player.statLifeMax2 += 50; for (int l = 0; l < Player.MaxBuffs; l++) @@ -3796,7 +3798,7 @@ namespace CalamityMod.CalPlayer ref int lostDef = ref bloodflareCoreLostDefense; if (lostDef > 0) { - // Defense regeneration occurs every six frames while defense is missing + // Defense regeneration occurs every six frames while defense is missing (Call Xyk a bitch if he doesn't change this) if (Player.miscCounter % 6 == 0) { --lostDef; diff --git a/CalamityKeybinds.cs b/CalamityKeybinds.cs index d498511c85..575fe168cb 100644 --- a/CalamityKeybinds.cs +++ b/CalamityKeybinds.cs @@ -9,7 +9,6 @@ namespace CalamityMod public static ModKeybind SetBonusHotKey { get; private set; } public static ModKeybind RageHotKey { get; private set; } public static ModKeybind AdrenalineHotKey { get; private set; } - public static ModKeybind AstralTeleportHotKey { get; private set; } public static ModKeybind PurityUIHotkey { get; private set; } public static ModKeybind SandCloakHotkey { get; private set; } public static ModKeybind SpectralVeilHotKey { get; private set; } @@ -28,7 +27,6 @@ namespace CalamityMod AdrenalineHotKey = KeybindLoader.RegisterKeybind(Mod, "AdrenalineMode", "B"); BlazingCoreHotKey = KeybindLoader.RegisterKeybind(Mod, "BlazingCoreParry", "N"); SetBonusHotKey = KeybindLoader.RegisterKeybind(Mod, "ArmorSetBonus", "Y"); - AstralTeleportHotKey = KeybindLoader.RegisterKeybind(Mod, "AstralTeleport", "P"); PurityUIHotkey = KeybindLoader.RegisterKeybind(Mod, "PurityUIToggle", "O"); SandCloakHotkey = KeybindLoader.RegisterKeybind(Mod, "SandCloakEffect", "C"); SpectralVeilHotKey = KeybindLoader.RegisterKeybind(Mod, "SpectralVeilTeleport", "Z"); @@ -47,7 +45,6 @@ namespace CalamityMod AdrenalineHotKey = null; BlazingCoreHotKey = null; SetBonusHotKey = null; - AstralTeleportHotKey = null; PurityUIHotkey = null; SandCloakHotkey = null; SpectralVeilHotKey = null; diff --git a/CalamityLists.cs b/CalamityLists.cs index 5e7783f114..d7901c66f4 100644 --- a/CalamityLists.cs +++ b/CalamityLists.cs @@ -1,8 +1,11 @@ -using CalamityMod.Buffs.Alcohol; +using CalamityMod.Buffs; +using CalamityMod.Buffs.Alcohol; +using CalamityMod.Buffs.Cooldowns; using CalamityMod.Buffs.DamageOverTime; using CalamityMod.Buffs.Potions; using CalamityMod.Buffs.StatDebuffs; using CalamityMod.Items.Accessories; +using CalamityMod.Items.Accessories.Vanity; using CalamityMod.Items.Armor.Vanity; using CalamityMod.Items.DraedonMisc; using CalamityMod.Items.Fishing.BrimstoneCragCatches; @@ -11,6 +14,7 @@ using CalamityMod.Items.LoreItems; using CalamityMod.Items.Materials; using CalamityMod.Items.Placeables; using CalamityMod.Items.Placeables.Furniture.Trophies; +using CalamityMod.Items.SummonItems; using CalamityMod.Items.TreasureBags; using CalamityMod.Items.Weapons.Magic; using CalamityMod.Items.Weapons.Melee; @@ -1157,7 +1161,17 @@ namespace CalamityMod BuffType(), BuffType(), BuffType(), - BuffType() + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType() }; sicknessDebuffList = new List() diff --git a/Items/Accessories/CelestialJewel.cs b/Items/Accessories/InfectedJewel.cs similarity index 71% rename from Items/Accessories/CelestialJewel.cs rename to Items/Accessories/InfectedJewel.cs index 99be42768f..6accf136d1 100644 --- a/Items/Accessories/CelestialJewel.cs +++ b/Items/Accessories/InfectedJewel.cs @@ -2,13 +2,15 @@ using CalamityMod.CalPlayer; using CalamityMod.Items.Potions; using System.Collections.Generic; +using CalamityMod.Items.Materials; using Terraria; using Terraria.ID; using Terraria.ModLoader; namespace CalamityMod.Items.Accessories { - public class CelestialJewel : ModItem, ILocalizedModType + [LegacyName("CelestialJewel")] + public class InfectedJewel : ModItem, ILocalizedModType { public new string LocalizationCategory => "Items.Accessories"; public override void SetDefaults() @@ -21,21 +23,18 @@ namespace CalamityMod.Items.Accessories Item.accessory = true; } - public override void ModifyTooltips(List list) => list.IntegrateHotkey(CalamityKeybinds.AstralTeleportHotKey); - public override void UpdateAccessory(Player player, bool hideVisual) { CalamityPlayer modPlayer = player.Calamity(); - modPlayer.celestialJewel = true; + modPlayer.infectedJewel = true; } public override void AddRecipes() { CreateRecipe(). AddIngredient(). - AddIngredient(ItemID.TeleportationPotion, 3). - AddIngredient(15). - AddIngredient(15). + AddIngredient(10). + AddIngredient(25). AddTile(TileID.MythrilAnvil). Register(); } diff --git a/Items/Accessories/CelestialJewel.png b/Items/Accessories/InfectedJewel.png similarity index 100% rename from Items/Accessories/CelestialJewel.png rename to Items/Accessories/InfectedJewel.png diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index c2a7831067..79c3950096 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -35,7 +35,7 @@ namespace CalamityMod.Items.Accessories public override void AddRecipes() { CreateRecipe(). - AddIngredient(). + AddIngredient(). AddIngredient(). AddIngredient(1). AddIngredient(8). diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 1841fac2e6..dfe56edc50 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -247,11 +247,13 @@ Purity: { A once infected crystal, now perfectly purified You emit light +80 max life - Your life regen is increased by 5 - Your natural life regen is greatly improved + Your life regen is increased by 4 + Increases life regen by 6 while afflicted with a debuff + Your life regen is still increased even when afflicted with a damage over time debuff + Your natural life regen is massively improved Greatly reduces how long you are afflicted with debuffs - When you are afflicted with a debuff you heal rapidly and gain 18 defense - Boosts life regen even while under the effects of a damaging debuff + When afflicted with a debuff, you will gain 18 defense + This defense will begin to fade away when you are no longer debuffed Press [KEY] to toggle teleportation UI while no bosses are alive ''' } @@ -355,13 +357,16 @@ Calamity: { ''' } -CelestialJewel: { - DisplayName: Celestial Jewel +InfectedJewel: { + DisplayName: Infected Jewel Tooltip: ''' - Boosts life regen even while under the effects of a debuff - While under the effects of a debuff you will gain 12 defense - Press [KEY] to teleport to a random location while no bosses are alive + A beautiful gem that has been corrupted by the astral infection + Life regen increased by 2 + Increases life regen by 4 while afflicted with a debuff + Your life regen is still increased even when afflicted with a damage over time debuff + When afflicted with a debuff, you will gain 14 defense + This defense will begin to fade away when you are no longer debuffed ''' } @@ -456,8 +461,11 @@ CrownJewel: { DisplayName: Crown Jewel Tooltip: ''' - Boosts life regen even while under the effects of a debuff - While under the effects of a debuff you will gain 8 defense + Life regen increased by 1 + Increases life regen by 3 while afflicted with a debuff + Your life regen is still increased even when afflicted with a damage over time debuff + When afflicted with a debuff, you will gain 8 defense + This defense will begin to fade away when you are no longer debuffed ''' } From 44af0ab912633c3ac042f6065dc9a1fdbe6b92f1 Mon Sep 17 00:00:00 2001 From: Xyk Date: Thu, 24 Aug 2023 02:49:21 -0700 Subject: [PATCH 004/138] im a bitch god damn it --- CalPlayer/CalamityPlayerMiscEffects.cs | 2 +- Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CalPlayer/CalamityPlayerMiscEffects.cs b/CalPlayer/CalamityPlayerMiscEffects.cs index 60b7d518db..60d6b4fa58 100644 --- a/CalPlayer/CalamityPlayerMiscEffects.cs +++ b/CalPlayer/CalamityPlayerMiscEffects.cs @@ -3798,7 +3798,7 @@ namespace CalamityMod.CalPlayer ref int lostDef = ref bloodflareCoreLostDefense; if (lostDef > 0) { - // Defense regeneration occurs every six frames while defense is missing (Call Xyk a bitch if he doesn't change this) + // Defense regeneration occurs every six frames while defense is missing if (Player.miscCounter % 6 == 0) { --lostDef; diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index dfe56edc50..c617c75823 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -361,7 +361,7 @@ InfectedJewel: { DisplayName: Infected Jewel Tooltip: ''' - A beautiful gem that has been corrupted by the astral infection + A beautiful gem that has been corrupted by the astral infection Life regen increased by 2 Increases life regen by 4 while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff From 5e931c7f0db85cf5d0b01f59f89650c38e615c17 Mon Sep 17 00:00:00 2001 From: Xyk Date: Thu, 24 Aug 2023 14:50:23 -0700 Subject: [PATCH 005/138] Removed the Keybinded effects from Infected Jewel and Purity I left the UI from Astral Arcanum in because we might decide to use it later, but there's no way to access it anymore in game. --- CalPlayer/CalamityPlayer.cs | 4 ---- CalamityKeybinds.cs | 3 --- CalamityMod.cs | 2 -- Items/Accessories/Purity.cs | 2 -- .../en-US/Mods.CalamityMod.Items.Accessories.hjson | 1 - Localization/en-US/Mods.CalamityMod.Keybinds.hjson | 2 +- Systems/UIManagementSystem.cs | 6 +++--- ...PurityCircles.png => SpecialTeleportCircles.png} | Bin UI/PurityUI.cs | 4 ++-- Utilities/CalamityRecipes.cs | 10 ++++++++++ 10 files changed, 16 insertions(+), 18 deletions(-) rename UI/MiscTextures/{PurityCircles.png => SpecialTeleportCircles.png} (100%) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index 9c0ccf1597..ea481e8755 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -2896,10 +2896,6 @@ namespace CalamityMod.CalPlayer if (prismaticSet && !Player.HasCooldown(PrismaticLaser.ID) && prismaticLasers <= 0) prismaticLasers = CalamityUtils.SecondsToFrames(35f); } - if (CalamityKeybinds.PurityUIHotkey.JustPressed && purity && !areThereAnyDamnBosses) - { - PurityUI.Toggle(); - } if (CalamityKeybinds.BlazingCoreHotKey.JustPressed) { diff --git a/CalamityKeybinds.cs b/CalamityKeybinds.cs index 575fe168cb..c76f1a98c2 100644 --- a/CalamityKeybinds.cs +++ b/CalamityKeybinds.cs @@ -9,7 +9,6 @@ namespace CalamityMod public static ModKeybind SetBonusHotKey { get; private set; } public static ModKeybind RageHotKey { get; private set; } public static ModKeybind AdrenalineHotKey { get; private set; } - public static ModKeybind PurityUIHotkey { get; private set; } public static ModKeybind SandCloakHotkey { get; private set; } public static ModKeybind SpectralVeilHotKey { get; private set; } public static ModKeybind PlaguePackHotKey { get; private set; } @@ -27,7 +26,6 @@ namespace CalamityMod AdrenalineHotKey = KeybindLoader.RegisterKeybind(Mod, "AdrenalineMode", "B"); BlazingCoreHotKey = KeybindLoader.RegisterKeybind(Mod, "BlazingCoreParry", "N"); SetBonusHotKey = KeybindLoader.RegisterKeybind(Mod, "ArmorSetBonus", "Y"); - PurityUIHotkey = KeybindLoader.RegisterKeybind(Mod, "PurityUIToggle", "O"); SandCloakHotkey = KeybindLoader.RegisterKeybind(Mod, "SandCloakEffect", "C"); SpectralVeilHotKey = KeybindLoader.RegisterKeybind(Mod, "SpectralVeilTeleport", "Z"); PlaguePackHotKey = KeybindLoader.RegisterKeybind(Mod, "BoosterDash", "Q"); @@ -45,7 +43,6 @@ namespace CalamityMod AdrenalineHotKey = null; BlazingCoreHotKey = null; SetBonusHotKey = null; - PurityUIHotkey = null; SandCloakHotkey = null; SpectralVeilHotKey = null; PlaguePackHotKey = null; diff --git a/CalamityMod.cs b/CalamityMod.cs index de5e30bd06..15188a5ff9 100644 --- a/CalamityMod.cs +++ b/CalamityMod.cs @@ -361,7 +361,6 @@ namespace CalamityMod RipperUI.Load(); StealthUI.Load(); ChargeMeterUI.Load(); - PurityUI.Load(this); FlightBar.Load(); // TODO -- Is this not possible to place in ModNPC.Load or ModNPC.SetStaticDefaults ? @@ -465,7 +464,6 @@ namespace CalamityMod RipperUI.Unload(); StealthUI.Unload(); ChargeMeterUI.Unload(); - PurityUI.Unload(); FlightBar.Unload(); if (!Main.dedServ) diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index 79c3950096..b4f69892b5 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -24,8 +24,6 @@ namespace CalamityMod.Items.Accessories Item.rare = ModContent.RarityType(); } - public override void ModifyTooltips(List list) => list.IntegrateHotkey(CalamityKeybinds.PurityUIHotkey); - public override void UpdateAccessory(Player player, bool hideVisual) { CalamityPlayer modPlayer = player.Calamity(); diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index c617c75823..cb2649b326 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -254,7 +254,6 @@ Purity: { Greatly reduces how long you are afflicted with debuffs When afflicted with a debuff, you will gain 18 defense This defense will begin to fade away when you are no longer debuffed - Press [KEY] to toggle teleportation UI while no bosses are alive ''' } diff --git a/Localization/en-US/Mods.CalamityMod.Keybinds.hjson b/Localization/en-US/Mods.CalamityMod.Keybinds.hjson index 1dbcda7a73..2800de597f 100644 --- a/Localization/en-US/Mods.CalamityMod.Keybinds.hjson +++ b/Localization/en-US/Mods.CalamityMod.Keybinds.hjson @@ -5,7 +5,7 @@ AngelicAllianceBlessing.DisplayName: Angelic Alliance Blessing BoosterDash.DisplayName: Booster Dash SpectralVeilTeleport.DisplayName: Spectral Veil Teleport SandCloakEffect.DisplayName: Sand Cloak Effect -PurityUIToggle.DisplayName: Purity UI Toggle +PurityUIToggle.DisplayName: Special Teleport UI Toggle AstralTeleport.DisplayName: Astral Teleport ArmorSetBonus.DisplayName: Armor Set Bonus AdrenalineMode.DisplayName: Adrenaline Mode diff --git a/Systems/UIManagementSystem.cs b/Systems/UIManagementSystem.cs index f8366ace3d..9da8ba9fc7 100644 --- a/Systems/UIManagementSystem.cs +++ b/Systems/UIManagementSystem.cs @@ -62,10 +62,10 @@ namespace CalamityMod.Systems return true; }, InterfaceScaleType.UI)); - // Astral Arcanum overlay (if open) - layers.Insert(mouseIndex, new LegacyGameInterfaceLayer("Astral Arcanum UI", delegate () + // Special Teleport overlay (if open) + layers.Insert(mouseIndex, new LegacyGameInterfaceLayer("Special Teleport UI", delegate () { - PurityUI.UpdateAndDraw(Main.spriteBatch); + SpecialTeleportUI.UpdateAndDraw(Main.spriteBatch); return true; }, InterfaceScaleType.None)); diff --git a/UI/MiscTextures/PurityCircles.png b/UI/MiscTextures/SpecialTeleportCircles.png similarity index 100% rename from UI/MiscTextures/PurityCircles.png rename to UI/MiscTextures/SpecialTeleportCircles.png diff --git a/UI/PurityUI.cs b/UI/PurityUI.cs index c13a151cd9..2767f40817 100644 --- a/UI/PurityUI.cs +++ b/UI/PurityUI.cs @@ -13,7 +13,7 @@ using Terraria.ModLoader; namespace CalamityMod.UI { // TODO -- This can be made into a ModSystem with simple OnModLoad and Unload hooks. - public static class PurityUI + public static class SpecialTeleportUI { enum CircleStyle { @@ -34,7 +34,7 @@ namespace CalamityMod.UI public static void Load(Mod mod) { - CircleTextures = ModContent.Request("CalamityMod/UI/MiscTextures/PurityCircles", AssetRequestMode.ImmediateLoad).Value; + CircleTextures = ModContent.Request("CalamityMod/UI/MiscTextures/SpecialTeleportCircles", AssetRequestMode.ImmediateLoad).Value; } public static void Unload() diff --git a/Utilities/CalamityRecipes.cs b/Utilities/CalamityRecipes.cs index 8a03f12c5b..724ed644af 100644 --- a/Utilities/CalamityRecipes.cs +++ b/Utilities/CalamityRecipes.cs @@ -813,6 +813,7 @@ namespace CalamityMod // Make various things cheaper (sorted by progression) { Vanilla(ItemID.Leather), ChangeIngredientStack(ItemID.RottenChunk, 2) }, { Vanilla(ItemID.JestersArrow), JesterArrowRecipeEdit }, + { Vanilla(ItemID.TeleportationPotion), TeleportationPotionRecipeEdit }, { Vanilla(ItemID.WormFood), WormFoodRecipeEdit }, { Vanilla(ItemID.BloodySpine), BloodySpineRecipeEdit }, { Vanilla(ItemID.GoblinBattleStandard), ChangeIngredientStack(ItemID.TatteredCloth, 5) }, @@ -957,6 +958,15 @@ namespace CalamityMod r.ChangeIngredientStack(ItemID.WoodenArrow, intendedStack); } + // Increases Teleportation Potion's recipe to give 10 per craft and use 10 bottled waters + private static void TeleportationPotionRecipeEdit(Recipe r) + { + int intendedStack = 10; + if (r.createItem.stack < intendedStack) + r.createItem.stack = intendedStack; + r.ChangeIngredientStack(ItemID.BottledWater, intendedStack); + } + // Change True Night's Edge recipe to require far less mech boss souls private static void TrueNightsEdgeRecipeEdit(Recipe r) { From 4c62b9c90b14aeee97d608184e8db93a012af722 Mon Sep 17 00:00:00 2001 From: Xyk Date: Thu, 24 Aug 2023 16:49:57 -0700 Subject: [PATCH 006/138] Teleportation potion craft quantity nerf --- Utilities/CalamityRecipes.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Utilities/CalamityRecipes.cs b/Utilities/CalamityRecipes.cs index 724ed644af..75a77e5ee8 100644 --- a/Utilities/CalamityRecipes.cs +++ b/Utilities/CalamityRecipes.cs @@ -958,10 +958,10 @@ namespace CalamityMod r.ChangeIngredientStack(ItemID.WoodenArrow, intendedStack); } - // Increases Teleportation Potion's recipe to give 10 per craft and use 10 bottled waters + // Increases Teleportation Potion's recipe to give 5 per craft and use 5 bottled waters private static void TeleportationPotionRecipeEdit(Recipe r) { - int intendedStack = 10; + int intendedStack = 5; if (r.createItem.stack < intendedStack) r.createItem.stack = intendedStack; r.ChangeIngredientStack(ItemID.BottledWater, intendedStack); From 0312a3b5b4bc4d245d00557822e5ea47a7aa44bd Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Thu, 24 Aug 2023 20:39:22 -0600 Subject: [PATCH 007/138] Locket flags and disabled Sacfice's lifesteal and Final Dawn's stealth generation from clones Nerfed locket's knive amount but buffed their damage --- CalPlayer/CalamityPlayer.cs | 11 +++++++---- Projectiles/CalamityGlobalProjectile.cs | 1 + Projectiles/Rogue/FinalDawnFireSlash.cs | 6 +++--- Projectiles/Rogue/SacrificeProjectile.cs | 3 +++ 4 files changed, 14 insertions(+), 7 deletions(-) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index c4a4bca9b0..bf86cd458c 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -3968,9 +3968,12 @@ namespace CalamityMod.CalPlayer int p = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, (int)(damage * 0.075), knockBack * 0.5f, Player.whoAmI); if (p.WithinBounds(Main.maxProjectiles)) - Main.projectile[p].DamageType = DamageClass.Generic; //in case melee/rogue variants bug out + { + Main.projectile[p].DamageType = DamageClass.Generic; //Makes it not proc shit like nanotech, extorter and other stuff + Main.projectile[p].Calamity().LocketClone = true; //To not have clones trigger effects like Sacrifice's Lifesteal and Final Dawn's stealth generation + } - // Handle AI edge-cases. + // Handle AI edge-cases. These are like overlapping projectiles and the projectile not spawning at all if (item.type == ModContent.ItemType()) Main.projectile[p].ai[1] = 1f; if (item.type == ModContent.ItemType()) @@ -3978,8 +3981,8 @@ namespace CalamityMod.CalPlayer if (StealthStrikeAvailable()) { - int knifeCount = 16; - int knifeDamage = (int)Player.GetTotalDamage().ApplyTo(60); + int knifeCount = 12; + int knifeDamage = (int)Player.GetTotalDamage().ApplyTo(75); float angleStep = MathHelper.TwoPi / knifeCount; float speed = 15f; diff --git a/Projectiles/CalamityGlobalProjectile.cs b/Projectiles/CalamityGlobalProjectile.cs index 1da386d36d..2268b521e7 100644 --- a/Projectiles/CalamityGlobalProjectile.cs +++ b/Projectiles/CalamityGlobalProjectile.cs @@ -105,6 +105,7 @@ namespace CalamityMod.Projectiles public bool stealthStrike = false; public int stealthStrikeHitCount = 0; public bool extorterBoost = false; + public bool LocketClone = false; // Note: Although this was intended for fishing line colors, I use this as an AI variable a lot because vanilla only has 4 that sometimes are already in use. ~Ben // TODO -- uses of this variable are undocumented and unstable. Remove it from the API surface. diff --git a/Projectiles/Rogue/FinalDawnFireSlash.cs b/Projectiles/Rogue/FinalDawnFireSlash.cs index c676c2ad00..65be647d42 100644 --- a/Projectiles/Rogue/FinalDawnFireSlash.cs +++ b/Projectiles/Rogue/FinalDawnFireSlash.cs @@ -14,7 +14,7 @@ namespace CalamityMod.Projectiles.Rogue { public new string LocalizationCategory => "Projectiles.Rogue"; public bool HasRegeneratedStealth = false; - public const float StealthReturnRatio = 0.25f; + public const float StealthReturnRatio = 0.40f; public override void SetStaticDefaults() { Main.projFrames[Projectile.type] = 11; @@ -93,14 +93,14 @@ namespace CalamityMod.Projectiles.Rogue { CalamityPlayer calamityPlayer = Main.player[Projectile.owner].Calamity(); // Restore stealth - if (!HasRegeneratedStealth) + if (!HasRegeneratedStealth && !Projectile.Calamity().LocketClone) //Locket clones dont create stealth { calamityPlayer.rogueStealth += calamityPlayer.rogueStealthMax * StealthReturnRatio; if (calamityPlayer.rogueStealth > calamityPlayer.rogueStealthMax) calamityPlayer.rogueStealth = calamityPlayer.rogueStealthMax; HasRegeneratedStealth = true; - target.AddBuff(ModContent.BuffType(), 300); } + target.AddBuff(ModContent.BuffType(), 300); } public override bool PreDraw(ref Color lightColor) { diff --git a/Projectiles/Rogue/SacrificeProjectile.cs b/Projectiles/Rogue/SacrificeProjectile.cs index c28094dd21..61dbf71973 100644 --- a/Projectiles/Rogue/SacrificeProjectile.cs +++ b/Projectiles/Rogue/SacrificeProjectile.cs @@ -40,6 +40,9 @@ namespace CalamityMod.Projectiles.Rogue public override void AI() { + if (Projectile.Calamity().LocketClone) + AbleToHealOwner = false; // No healing you too much of your hp + if (ReturningToOwner) { Projectile.timeLeft = 15; From eafa6c04e71940be642109e142c74e69a4bf7721 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Thu, 24 Aug 2023 22:16:39 -0600 Subject: [PATCH 008/138] Venerated Locket Item Banlist; contains mainly spikeballs, slick cane and the two short ranged kunais; added a mod call for adding items to said list (such as Dreamtastic from Infernum) Final Dawn stealth gain nerf (i buffed it too much) --- CalPlayer/CalamityPlayer.cs | 123 ++++++++++++------------ CalamityLists.cs | 16 +++ ModSupport/ModCalls.cs | 26 ++++- Projectiles/Rogue/FinalDawnFireSlash.cs | 2 +- 4 files changed, 105 insertions(+), 62 deletions(-) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index bf86cd458c..a3ffbce08f 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -373,7 +373,7 @@ namespace CalamityMod.CalPlayer public bool HasAnyEnergyShield => roverDrive || lunicCorpsSet || sponge; public bool freeDodgeFromShieldAbsorption = false; public bool drawnAnyShieldThisFrame = false; - + // TODO -- Some way to show the player their total shield points. public int TotalEnergyShielding => RoverDriveShieldDurability + LunicCorpsShieldDurability + SpongeShieldDurability; public int TotalMaxShieldDurability => (roverDrive ? RoverDrive.ShieldDurabilityMax : 0) + (lunicCorpsSet ? LunicCorpsHelmet.ShieldDurabilityMax : 0) + (sponge ? TheSponge.ShieldDurabilityMax : 0); @@ -2575,7 +2575,7 @@ namespace CalamityMod.CalPlayer { gSabatonHotkeyHoldTime = 0; } - + if (CalamityKeybinds.NormalityRelocatorHotKey.JustPressed && normalityRelocator && Main.myPlayer == Player.whoAmI) { if (!Player.CCed && !Player.chaosState) @@ -2964,7 +2964,7 @@ namespace CalamityMod.CalPlayer { float angle = MathHelper.TwoPi * i / skullCount; Vector2 initialVelocity = angle.ToRotationVector2().RotatedByRandom(MathHelper.ToRadians(12f)) * skullSpeed * new Vector2(0.82f, 1.5f) * - Main.rand.NextFloat(0.8f, 1.2f) * (i < skullCount / 2 ? 0.25f : 1f); + Main.rand.NextFloat(0.8f, 1.2f) * (i < skullCount / 2 ? 0.25f : 1f); int projectileIndex = Projectile.NewProjectile(source, Player.Center + initialVelocity * 3f, initialVelocity, ModContent.ProjectileType(), damage, 2f, Player.whoAmI); Main.projectile[projectileIndex].tileCollide = false; Main.projectile[projectileIndex].localAI[1] = (Main.projectile[projectileIndex].velocity.Y < 0f).ToInt(); @@ -3285,7 +3285,7 @@ namespace CalamityMod.CalPlayer //Life Jelly regen aura spawn when using a healing potion if (timePotionSick == 1 && Player.whoAmI == Main.myPlayer && lifejelly && !GrandGelatin) - Projectile.NewProjectile(Player.GetSource_FromThis(), Player.Center, Vector2.Zero, ModContent.ProjectileType(), 0, 0, Player.whoAmI); + Projectile.NewProjectile(Player.GetSource_FromThis(), Player.Center, Vector2.Zero, ModContent.ProjectileType(), 0, 0, Player.whoAmI); //Cleansing Jelly cleansing aura spawn when using a healing potion if (timePotionSick == 1 && Player.whoAmI == Main.myPlayer && cleansingjelly && !GrandGelatin) @@ -3351,7 +3351,7 @@ namespace CalamityMod.CalPlayer //While holding hotkey, but before slam, bring Y velocity closer to 0 if (gSabatonHotkeyHoldTime < 60 && gSabatonHotkeyHoldTime != 0 && !gSabatonFalling) { - Player.velocity.Y *= (60 - (gSabatonHotkeyHoldTime/4f))/60f; + Player.velocity.Y *= (60 - (gSabatonHotkeyHoldTime / 4f)) / 60f; } //Play sound a bit early so it goes in time with the fall if (gSabatonHotkeyHoldTime == 45 && !gSabatonFalling) @@ -3372,11 +3372,11 @@ namespace CalamityMod.CalPlayer if (gSabatonFalling) { SpawnGravistarParticle(); - + //Cap time converted to damage at 2 seconds if (gSabatonFall < 120) gSabatonFall++; - + Player.maxFallSpeed = 40f; Player.gravity = 1.3f; //If the player can fly during the fall, the physics gets a bit funky @@ -3394,7 +3394,7 @@ namespace CalamityMod.CalPlayer gSabatonTempJumpSpeed = 40; } } - + } } #endregion @@ -3405,7 +3405,7 @@ namespace CalamityMod.CalPlayer //Infinite flight granted by some boss attacks if (infiniteFlight) Player.wingTime = Player.wingTimeMax; - + // Reset the Calamity shader. CalamityFireDyeShader = null; @@ -3774,7 +3774,7 @@ namespace CalamityMod.CalPlayer if (Main.rand.NextBool(20)) { int confettiDust = Main.rand.Next(139, 143); - int confetti = Dust.NewDust(new Vector2(hitbox.X,hitbox.Y), hitbox.Width, hitbox.Height, confettiDust, Player.velocity.X, Player.velocity.Y, 0, new Color(), 1.2f); + int confetti = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, confettiDust, Player.velocity.X, Player.velocity.Y, 0, new Color(), 1.2f); Main.dust[confetti].velocity.X *= (float)(1.0 + Main.rand.Next(-50, 51) * 0.01); Main.dust[confetti].velocity.Y *= (float)(1.0 + Main.rand.Next(-50, 51) * 0.01); Main.dust[confetti].velocity.X += Main.rand.Next(-50, 51) * 0.05f; @@ -3915,7 +3915,7 @@ namespace CalamityMod.CalPlayer } } #endregion - + #region Shoot public override bool Shoot(Item item, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockBack) { @@ -3926,59 +3926,62 @@ namespace CalamityMod.CalPlayer { if (item.CountsAsClass()) { - float num72 = item.shootSpeed; - Vector2 vector2 = Player.RotatedRelativePoint(Player.MountedCenter, true); - float num78 = (float)Main.mouseX + Main.screenPosition.X - vector2.X; - float num79 = (float)Main.mouseY + Main.screenPosition.Y - vector2.Y; - if (Player.gravDir == -1f) - { - num79 = Main.screenPosition.Y + (float)Main.screenHeight - (float)Main.mouseY - vector2.Y; - } - float num80 = (float)Math.Sqrt((double)(num78 * num78 + num79 * num79)); - if ((float.IsNaN(num78) && float.IsNaN(num79)) || (num78 == 0f && num79 == 0f)) - { - num78 = (float)Player.direction; - num79 = 0f; - num80 = num72; - } - else + if (!CalamityLists.VeneratedLocketBanlist.Contains(item.type)) { + float num72 = item.shootSpeed; + Vector2 vector2 = Player.RotatedRelativePoint(Player.MountedCenter, true); + float num78 = (float)Main.mouseX + Main.screenPosition.X - vector2.X; + float num79 = (float)Main.mouseY + Main.screenPosition.Y - vector2.Y; + if (Player.gravDir == -1f) + { + num79 = Main.screenPosition.Y + (float)Main.screenHeight - (float)Main.mouseY - vector2.Y; + } + float num80 = (float)Math.Sqrt((double)(num78 * num78 + num79 * num79)); + if ((float.IsNaN(num78) && float.IsNaN(num79)) || (num78 == 0f && num79 == 0f)) + { + num78 = (float)Player.direction; + num79 = 0f; + num80 = num72; + } + else + { + num80 = num72 / num80; + } + + vector2 = new Vector2(Player.position.X + (float)Player.width * 0.5f + (float)(Main.rand.Next(201) * -(float)Player.direction) + ((float)Main.mouseX + Main.screenPosition.X - Player.position.X), Player.MountedCenter.Y - 600f); + vector2.X = (vector2.X + Player.Center.X) / 2f + (float)Main.rand.Next(-200, 201); + vector2.Y -= 100f; + num78 = (float)Main.mouseX + Main.screenPosition.X - vector2.X; + num79 = (float)Main.mouseY + Main.screenPosition.Y - vector2.Y; + if (num79 < 0f) + { + num79 *= -1f; + } + if (num79 < 20f) + { + num79 = 20f; + } + num80 = (float)Math.Sqrt((double)(num78 * num78 + num79 * num79)); num80 = num72 / num80; - } + num78 *= num80; + num79 *= num80; + float speedX4 = num78 + (float)Main.rand.Next(-30, 31) * 0.02f; + float speedY5 = num79 + (float)Main.rand.Next(-30, 31) * 0.02f; + int p = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, (int)(damage * 0.075), knockBack * 0.5f, Player.whoAmI); - vector2 = new Vector2(Player.position.X + (float)Player.width * 0.5f + (float)(Main.rand.Next(201) * -(float)Player.direction) + ((float)Main.mouseX + Main.screenPosition.X - Player.position.X), Player.MountedCenter.Y - 600f); - vector2.X = (vector2.X + Player.Center.X) / 2f + (float)Main.rand.Next(-200, 201); - vector2.Y -= 100f; - num78 = (float)Main.mouseX + Main.screenPosition.X - vector2.X; - num79 = (float)Main.mouseY + Main.screenPosition.Y - vector2.Y; - if (num79 < 0f) - { - num79 *= -1f; - } - if (num79 < 20f) - { - num79 = 20f; - } - num80 = (float)Math.Sqrt((double)(num78 * num78 + num79 * num79)); - num80 = num72 / num80; - num78 *= num80; - num79 *= num80; - float speedX4 = num78 + (float)Main.rand.Next(-30, 31) * 0.02f; - float speedY5 = num79 + (float)Main.rand.Next(-30, 31) * 0.02f; - int p = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, (int)(damage * 0.075), knockBack * 0.5f, Player.whoAmI); + if (p.WithinBounds(Main.maxProjectiles)) + { + Main.projectile[p].DamageType = DamageClass.Generic; //Makes it not proc shit like nanotech, extorter and other stuff + Main.projectile[p].Calamity().LocketClone = true; //To not have clones trigger effects like Sacrifice's Lifesteal and Final Dawn's stealth generation + } - if (p.WithinBounds(Main.maxProjectiles)) - { - Main.projectile[p].DamageType = DamageClass.Generic; //Makes it not proc shit like nanotech, extorter and other stuff - Main.projectile[p].Calamity().LocketClone = true; //To not have clones trigger effects like Sacrifice's Lifesteal and Final Dawn's stealth generation + // Handle AI edge-cases. These are like overlapping projectiles and the projectile not spawning at all + if (item.type == ModContent.ItemType()) + Main.projectile[p].ai[1] = 1f; + if (item.type == ModContent.ItemType()) + Main.projectile[p].ai[0] = -1f; } - // Handle AI edge-cases. These are like overlapping projectiles and the projectile not spawning at all - if (item.type == ModContent.ItemType()) - Main.projectile[p].ai[1] = 1f; - if (item.type == ModContent.ItemType()) - Main.projectile[p].ai[0] = -1f; - if (StealthStrikeAvailable()) { int knifeCount = 12; @@ -4066,7 +4069,7 @@ namespace CalamityMod.CalPlayer } else if (AresExoskeleton.ArmExists(Player)) Player.body = EquipLoader.GetEquipSlot(Mod, "AresExoskeleton", EquipType.Body); - + else if ((abyssalDivingSuitPower || abyssalDivingSuitForce) && !abyssalDivingSuitHide) { Player.legs = EquipLoader.GetEquipSlot(Mod, "AbyssalDivingSuit", EquipType.Legs); @@ -4666,7 +4669,7 @@ namespace CalamityMod.CalPlayer break; if (Main.projectile[i].owner == Player.whoAmI && Main.projectile[i].friendly) { - bool attack = Main.projectile[i].owner == Player.whoAmI && Main.projectile[i].type == ModContent.ProjectileType(); + bool attack = Main.projectile[i].owner == Player.whoAmI && Main.projectile[i].type == ModContent.ProjectileType(); bool defense = Main.projectile[i].owner == Player.whoAmI && Main.projectile[i].type == ModContent.ProjectileType(); if (attack || defense) { diff --git a/CalamityLists.cs b/CalamityLists.cs index 878f01aa30..8ab290132b 100644 --- a/CalamityLists.cs +++ b/CalamityLists.cs @@ -160,6 +160,8 @@ namespace CalamityMod public static List DisabledSummonerNerfItems; public static List DisabledSummonerNerfMinions; + public static List VeneratedLocketBanlist; //To ban projectiles from locket, mainly spikeballs altho Toasty asked me to add mod calls for adding stuff like Dreamtastic + public static void LoadLists() { donatorList = new List() @@ -2670,6 +2672,18 @@ namespace CalamityMod DisabledSummonerNerfItems = new(); DisabledSummonerNerfMinions = new(); + + VeneratedLocketBanlist = new List() + { + ItemType(), + ItemType(), + ItemType(), + ItemType(), + ItemType(), + ItemType(), + ItemType(), + ItemType() + }; } public static void UnloadLists() @@ -2758,6 +2772,8 @@ namespace CalamityMod DisabledSummonerNerfItems = null; DisabledSummonerNerfMinions = null; + + VeneratedLocketBanlist = null; } } } diff --git a/ModSupport/ModCalls.cs b/ModSupport/ModCalls.cs index 7db7b60177..39f7d74de8 100644 --- a/ModSupport/ModCalls.cs +++ b/ModSupport/ModCalls.cs @@ -1702,8 +1702,25 @@ namespace CalamityMod public static bool IsOnPersistentBuffList(int type) => CalamityLists.persistentBuffList.Contains(type); #endregion + #region Venerated Locket Bans + public static bool SetVeneratedLocketBanlist(int type, bool shouldBeListed2) + { + if (shouldBeListed2 && !CalamityLists.VeneratedLocketBanlist.Contains(type)) + { + CalamityLists.VeneratedLocketBanlist.Add(type); + return true; + } + else if (!shouldBeListed2) + { + return CalamityLists.VeneratedLocketBanlist.Remove(type); + } + + return false; + } + #endregion + #region Summoner Cross Class Nerf Disabling - public static bool SetSummonerNerfDisabledByMinion(int type, bool disableNerf) + public static bool SetSummonerNerfDisabledByMinion(int type, bool disableNerf) { if (disableNerf && !CalamityLists.DisabledSummonerNerfMinions.Contains(type)) { @@ -2684,6 +2701,13 @@ namespace CalamityMod DraedonDialogRegistry.DialogOptions.Add(new(inquiry, response, condition)); return null; + case "SetVeneratedLocketBanlist": + if (args.Length < 2 || !isValidItemArg(args[1])) + return new ArgumentException("ERROR: Must specify a valid item to check status of."); + if (args.Length != 3 || args[2] is not bool shouldBeListed2) + return new ArgumentException("ERROR: Must specify a bool that determines whether the weapon is banned from being cloned by Venerated Locket."); + return SetVeneratedLocketBanlist(castItem(args[1]).type, shouldBeListed2); + default: return new ArgumentException("ERROR: Invalid method name."); } diff --git a/Projectiles/Rogue/FinalDawnFireSlash.cs b/Projectiles/Rogue/FinalDawnFireSlash.cs index 65be647d42..7f869fcd48 100644 --- a/Projectiles/Rogue/FinalDawnFireSlash.cs +++ b/Projectiles/Rogue/FinalDawnFireSlash.cs @@ -14,7 +14,7 @@ namespace CalamityMod.Projectiles.Rogue { public new string LocalizationCategory => "Projectiles.Rogue"; public bool HasRegeneratedStealth = false; - public const float StealthReturnRatio = 0.40f; + public const float StealthReturnRatio = 0.35f; public override void SetStaticDefaults() { Main.projFrames[Projectile.type] = 11; From cd1d25853d7426576204e2fc246d16135a4d06c4 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Thu, 24 Aug 2023 22:58:06 -0600 Subject: [PATCH 009/138] Final MFing Dawn (40% stealth was actually fine, made the stealth return variable static, fixed clone generating stealth) --- CalPlayer/CalamityPlayer.cs | 2 +- Localization/en-US/Mods.CalamityMod.Configs.hjson | 2 +- Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson | 4 ++-- Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson | 4 ++-- Projectiles/Rogue/FinalDawnFireSlash.cs | 2 +- Projectiles/Rogue/FinalDawnProjectile.cs | 4 +++- 6 files changed, 10 insertions(+), 8 deletions(-) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index a3ffbce08f..6ec02390e7 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -3977,7 +3977,7 @@ namespace CalamityMod.CalPlayer // Handle AI edge-cases. These are like overlapping projectiles and the projectile not spawning at all if (item.type == ModContent.ItemType()) - Main.projectile[p].ai[1] = 1f; + Main.projectile[p].ai[1] = 1f; //MUST BE 1 OTHERWISE CLONES GENERATE STEALTH AAAAAAAAAAA if (item.type == ModContent.ItemType()) Main.projectile[p].ai[0] = -1f; } diff --git a/Localization/en-US/Mods.CalamityMod.Configs.hjson b/Localization/en-US/Mods.CalamityMod.Configs.hjson index eba58802b8..f2f8a3ade9 100644 --- a/Localization/en-US/Mods.CalamityMod.Configs.hjson +++ b/Localization/en-US/Mods.CalamityMod.Configs.hjson @@ -423,4 +423,4 @@ CalamityConfig: { Label: "[i:Book] Wiki Status Message" Tooltip: Enable or disable the status message promoting the Official Calamity Wiki that plays on world entry. } -} +} \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson b/Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson index ef43f00306..3a78fdb492 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson @@ -235,7 +235,7 @@ RuneofKos: { Tooltip: ''' An ornate sigil of the Profaned Flame - Hatred yet burns upon its brow + Hatred yet burns upon its brow [SPAWN] Not consumable ''' @@ -307,4 +307,4 @@ YharonEgg: { Not consumable An effigy of a Phoenix Dragon egg, used in worship ''' -} +} \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson index bfe3cc19c2..0c171b76c1 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson @@ -734,7 +734,7 @@ SubsumingVortex: { Press to cast a gigantic vortex in front of you with a bias towards the mouse When enemies are near the vortex, it sends multiple fast-moving smaller vortices towards them Releasing fires the vortex towards the mouse if enough time has passed - Damage scales based on how long the vortex was held out + Damage scales based on how long the vortex was held out ''' } @@ -955,4 +955,4 @@ YharimsCrystal: { Tooltip: "[GFB]" TooltipNormal: Fires draconic beams of total annihilation TooltipGFB: ...throughs a pice of dnimite -} +} \ No newline at end of file diff --git a/Projectiles/Rogue/FinalDawnFireSlash.cs b/Projectiles/Rogue/FinalDawnFireSlash.cs index 7f869fcd48..8cee1e8eac 100644 --- a/Projectiles/Rogue/FinalDawnFireSlash.cs +++ b/Projectiles/Rogue/FinalDawnFireSlash.cs @@ -14,7 +14,7 @@ namespace CalamityMod.Projectiles.Rogue { public new string LocalizationCategory => "Projectiles.Rogue"; public bool HasRegeneratedStealth = false; - public const float StealthReturnRatio = 0.35f; + public static float StealthReturnRatio = 0.40f; public override void SetStaticDefaults() { Main.projFrames[Projectile.type] = 11; diff --git a/Projectiles/Rogue/FinalDawnProjectile.cs b/Projectiles/Rogue/FinalDawnProjectile.cs index cfbc669dd8..e520d9d24c 100644 --- a/Projectiles/Rogue/FinalDawnProjectile.cs +++ b/Projectiles/Rogue/FinalDawnProjectile.cs @@ -138,12 +138,14 @@ namespace CalamityMod.Projectiles.Rogue else { //This one doesn't consume stealth since it replenishes stealth on hits - Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, + int p = Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, Projectile.velocity, ModContent.ProjectileType(), Projectile.damage, Projectile.knockBack, Projectile.owner); + if (p.WithinBounds(Main.maxProjectiles) && Projectile.Calamity().LocketClone) + Main.projectile[p].Calamity().LocketClone = true; // NO STEALTH GEN OK? } } } From cb5a1a235a2177844dd0c360144dac11167c3a79 Mon Sep 17 00:00:00 2001 From: Altixal <73398287+Altixal@users.noreply.github.com> Date: Fri, 25 Aug 2023 12:13:47 +0700 Subject: [PATCH 010/138] aquatic aberration bestiary typo fix --- Localization/en-US/Mods.CalamityMod.Bestiary.hjson | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Localization/en-US/Mods.CalamityMod.Bestiary.hjson b/Localization/en-US/Mods.CalamityMod.Bestiary.hjson index ba3e243db0..dfc3a10260 100644 --- a/Localization/en-US/Mods.CalamityMod.Bestiary.hjson +++ b/Localization/en-US/Mods.CalamityMod.Bestiary.hjson @@ -139,7 +139,7 @@ DarkEnergy: - DesertNuisance: Though these serpents are of the Desert Scourge’s species, they are notably younger and less developed. Choosing to hunt in a pack with the large scourge due to this weakness, many have seen them tear apart prey not unlike the piranhas that once populated the former sea. CosmicGuardian: Though of the same species as the nameless serpent, their minds and functions are far more basic. They possess very little will of their own and blindly follow the orders of their gluttonous master. HiveTumor: This tumor acts as the brain of the putrid wasteland, being all that is left of the minds of the slain gods that lay there. The creatures of the Corruption exist to protect it, and those who attempt to harm it rarely live to tell the tale. -AquaticAberration: ASpawn of the immense Leviathan, their lifespan can be measured in hours. All they know is how to hunt for their masters. Even non-aquatic life is well within their reach, due to their uncanny ability to fly through air just as easily as swimming through water. +AquaticAberration: A spawn of the immense Leviathan, their lifespan can be measured in hours. All they know is how to hunt for their masters. Even non-aquatic life is well within their reach, due to their uncanny ability to fly through air just as easily as swimming through water. LeviathanStart: A lure created by the Water Elemental, Anahita. It sings so sweetly, its voice full of promise and warmth, but beware: follow the siren’s call at your own peril. PerforatorCyst: This twitching and convulsing pile of gore acts as the heart of the Perforator Hive, harvesting what small amount of diluted Ichor flowing through the Crimson is left and feeding it to the Hive. Little else is known about it, for those who dare to disturb it have become indistinguishable from the landscape. CosmicLantern: These lanterns possess a magical, distorted flame that radiates no heat whatsoever. If one looks closely into their fire, they may see another world entirely. From f31fb64522e47f5614f15b4dfea45bc4e4e86641 Mon Sep 17 00:00:00 2001 From: Xyk Date: Thu, 24 Aug 2023 22:18:25 -0700 Subject: [PATCH 011/138] Fixed some bad wording in the tooltips --- CalPlayer/CalamityPlayerLifeRegen.cs | 4 ++-- .../en-US/Mods.CalamityMod.Items.Accessories.hjson | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index 52ffd2da5b..5d370e5d72 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -511,7 +511,7 @@ namespace CalamityMod.CalPlayer if (purity) { - Player.lifeRegen += 4; + Player.lifeRegen += 5; Player.lifeRegenTime += 6; Player.statDefense += PurityBonusDefense; //heal every 5 frames @@ -533,7 +533,7 @@ namespace CalamityMod.CalPlayer if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; //add extra regen when effected by a debuff - Player.lifeRegen += 6; + Player.lifeRegen += 5; PurityBonusDefense = 18; if (ReducedHealingCounter < 120) ReducedHealingCounter++; diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index cb2649b326..3d732505e0 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -247,8 +247,8 @@ Purity: { A once infected crystal, now perfectly purified You emit light +80 max life - Your life regen is increased by 4 - Increases life regen by 6 while afflicted with a debuff + Your life regen is increased by 5 + You gain an additional 5 life regen while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff Your natural life regen is massively improved Greatly reduces how long you are afflicted with debuffs @@ -362,7 +362,7 @@ InfectedJewel: { ''' A beautiful gem that has been corrupted by the astral infection Life regen increased by 2 - Increases life regen by 4 while afflicted with a debuff + You gain an additional 4 life regen while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff When afflicted with a debuff, you will gain 14 defense This defense will begin to fade away when you are no longer debuffed @@ -461,7 +461,7 @@ CrownJewel: { Tooltip: ''' Life regen increased by 1 - Increases life regen by 3 while afflicted with a debuff + You gain an additional 3 life regen while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff When afflicted with a debuff, you will gain 8 defense This defense will begin to fade away when you are no longer debuffed From c65a20fa3cb1807245945a5e59798d9f3e198f41 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Thu, 24 Aug 2023 23:45:43 -0600 Subject: [PATCH 012/138] Optimized the ModCall, removed the boolean check as it just needs the item to be added and not added and removed like cross class summoner nerfs disabling (btw why does Amalgam also have a bool check?) --- ModSupport/ModCalls.cs | 21 ++++++++------------- 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/ModSupport/ModCalls.cs b/ModSupport/ModCalls.cs index 39f7d74de8..0be1f42525 100644 --- a/ModSupport/ModCalls.cs +++ b/ModSupport/ModCalls.cs @@ -1703,18 +1703,13 @@ namespace CalamityMod #endregion #region Venerated Locket Bans - public static bool SetVeneratedLocketBanlist(int type, bool shouldBeListed2) + public static bool AddToVeneratedLocketBanlist(int type) { - if (shouldBeListed2 && !CalamityLists.VeneratedLocketBanlist.Contains(type)) + if (!CalamityLists.VeneratedLocketBanlist.Contains(type)) { CalamityLists.VeneratedLocketBanlist.Add(type); return true; } - else if (!shouldBeListed2) - { - return CalamityLists.VeneratedLocketBanlist.Remove(type); - } - return false; } #endregion @@ -2701,12 +2696,12 @@ namespace CalamityMod DraedonDialogRegistry.DialogOptions.Add(new(inquiry, response, condition)); return null; - case "SetVeneratedLocketBanlist": - if (args.Length < 2 || !isValidItemArg(args[1])) - return new ArgumentException("ERROR: Must specify a valid item to check status of."); - if (args.Length != 3 || args[2] is not bool shouldBeListed2) - return new ArgumentException("ERROR: Must specify a bool that determines whether the weapon is banned from being cloned by Venerated Locket."); - return SetVeneratedLocketBanlist(castItem(args[1]).type, shouldBeListed2); + case "AddToVeneratedLocketBanlist": + if (args.Length < 2) + return new ArgumentException("ERROR: Not enough arguments"); + if (args[1] is not int ItemType) + return new ArgumentException("ERROR: Must specify a valid item type."); + return AddToVeneratedLocketBanlist(ItemType); default: return new ArgumentException("ERROR: Invalid method name."); From 30289e6fd988ffef5db058bf5853dbedc5968102 Mon Sep 17 00:00:00 2001 From: Xyk Date: Thu, 24 Aug 2023 22:51:26 -0700 Subject: [PATCH 013/138] Added a Purity sprite I didn't say it's good --- Items/Accessories/Purity.cs | 4 ++-- Items/Accessories/Purity.png | Bin 7621 -> 3265 bytes 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index b4f69892b5..49e7f8f711 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -17,8 +17,8 @@ namespace CalamityMod.Items.Accessories public override void SetDefaults() { Item.defense = 8; - Item.width = 24; - Item.height = 24; + Item.width = 22; + Item.height = 44; Item.accessory = true; Item.value = CalamityGlobalItem.Rarity12BuyPrice; Item.rare = ModContent.RarityType(); diff --git a/Items/Accessories/Purity.png b/Items/Accessories/Purity.png index 5bd31a409e2941cef2417e53b3d6e53e9afa097a..2c81cd5c7cbc747f83788b160e52648d89ed855a 100644 GIT binary patch delta 529 zcmV+s0`C3AJHZ(tiBL{Q4GJ0x0000DNk~Le0000O0000i2nGNE0Dqi#L$M*f3V#93 zNkl_kgbP{`oBc4JGQj zI^P}SA28V4ts1-p0XVz7vH-WQ>ixFDTtGi`?*M6BR1pE7IZ_6|eMZO?po_|TK!#fz zN(12VE^diX2OMAD0kFEh0YKCk@faAGm@)x|`}-`>oE#mhAJEZifux}wGJm2mkAeR2 zNfV&1v**ibhU(SOmk&-Y5y_$nWWScEyaRO6wAa@F`lG@rD(`@$AE6pbdSum6cttcO}+kllM@Eq9(EFy zlr&D-X__=Z7nPLL17~S*5oUmunQ5PZs>T+;{X@SvRV`dry1H$rXJ&l@q;$h}0_GO1 z(Mb6R*rSqR+ZRn2jemd>l%137s&PU<{0%~x2?BOVhA#g=H`Koe*dZyW#-0K1(7c?( TyVVcF00000NkvXXu0mjfz|`&e delta 4920 zcmV-86UXeq8O1vxiBL{Q4GJ0x0000DNk~Le0000m0000m2nGNE09OL}hp{2O3V#yO zNklRRsm!9d&{lsxbA{y){z_nuSd zcW>QO_tb5|7{mW(k^c*T->f^F2YILwtvjF?Svov_+v!@SYHH<`95k+cT)zP6W+`9a3>$3nV+{^ zcYeO3r%$JM$I}#XlfPwLcj38T3~<5fz2u{Dm272DA695u3rhr24jV;7%&a*gC;xgy zcmIOUK#<#Kx$E!!^J*KR!!=^TB-X0ZfbCN9+sCCtb8jEVr-l0@f`2|u$785I7F}@T z*s>Wv75q;Ej1HyAhD?zG03n2a+MIf*MB*RdhziZ*(V_xW5^ugckY2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29Z%-`Y1nvZ1m-e2?;iyO$V qrxcyC)3LFyGSz!OlJmb${|hX7G)l&!Weqt10000 Date: Thu, 24 Aug 2023 23:51:49 -0600 Subject: [PATCH 014/138] as an int index of the item --- ModSupport/ModCalls.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ModSupport/ModCalls.cs b/ModSupport/ModCalls.cs index 0be1f42525..90e028304a 100644 --- a/ModSupport/ModCalls.cs +++ b/ModSupport/ModCalls.cs @@ -2698,10 +2698,10 @@ namespace CalamityMod case "AddToVeneratedLocketBanlist": if (args.Length < 2) - return new ArgumentException("ERROR: Not enough arguments"); - if (args[1] is not int ItemType) - return new ArgumentException("ERROR: Must specify a valid item type."); - return AddToVeneratedLocketBanlist(ItemType); + return new ArgumentException("ERROR: Not enough arguments!"); + if (args[1] is not int itemType) + return new ArgumentException("ERROR: Must specify a valid item type as an int index of the item."); + return AddToVeneratedLocketBanlist(itemType); default: return new ArgumentException("ERROR: Invalid method name."); From c0b993e13ef982be86b668845b44ecd321d54958 Mon Sep 17 00:00:00 2001 From: Altixal <73398287+Altixal@users.noreply.github.com> Date: Fri, 25 Aug 2023 18:27:06 +0700 Subject: [PATCH 015/138] random ass ssv tooltip spacing --- Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson index bfe3cc19c2..a52ec10ad9 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson @@ -734,7 +734,7 @@ SubsumingVortex: { Press to cast a gigantic vortex in front of you with a bias towards the mouse When enemies are near the vortex, it sends multiple fast-moving smaller vortices towards them Releasing fires the vortex towards the mouse if enough time has passed - Damage scales based on how long the vortex was held out + Damage scales based on how long the vortex was held out ''' } From 8f6561af6ebddc10b30fb7fec070637e53db3d88 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Fri, 25 Aug 2023 09:45:08 -0400 Subject: [PATCH 016/138] Further SSV balance changes --- Balancing/BalancingChangesManager.cs | 4 ++-- Items/Weapons/Magic/SubsumingVortex.cs | 2 +- Projectiles/Magic/EnormousConsumingVortex.cs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Balancing/BalancingChangesManager.cs b/Balancing/BalancingChangesManager.cs index 47037c8dbb..398ec7fe84 100644 --- a/Balancing/BalancingChangesManager.cs +++ b/Balancing/BalancingChangesManager.cs @@ -377,8 +377,8 @@ namespace CalamityMod.Balancing // 85% resist to Chicken Cannon. NPCSpecificBalancingChanges.Add(new NPCBalancingChange(NPCType(), new ProjectileResistBalancingRule(0.15f, ProjectileType()))); - // 35% resist to Subsuming Vortex. - NPCSpecificBalancingChanges.Add(new NPCBalancingChange(NPCType(), new ProjectileResistBalancingRule(0.65f, ProjectileType(), ProjectileType(), ProjectileType()))); + // 40% resist to Subsuming Vortex. + NPCSpecificBalancingChanges.Add(new NPCBalancingChange(NPCType(), new ProjectileResistBalancingRule(0.6f, ProjectileType(), ProjectileType(), ProjectileType()))); // 30% resist to Murasama. NPCSpecificBalancingChanges.Add(new NPCBalancingChange(NPCType(), new ProjectileResistBalancingRule(0.7f, ProjectileType()))); diff --git a/Items/Weapons/Magic/SubsumingVortex.cs b/Items/Weapons/Magic/SubsumingVortex.cs index 84eaddb6ba..fefa9fab34 100644 --- a/Items/Weapons/Magic/SubsumingVortex.cs +++ b/Items/Weapons/Magic/SubsumingVortex.cs @@ -34,7 +34,7 @@ namespace CalamityMod.Items.Weapons.Magic public const float ReleaseSpeed = 33f; - public const float ReleaseDamageFactor = 4.48f; + public const float ReleaseDamageFactor = 4.65f; public static readonly SoundStyle ExplosionSound = new("CalamityMod/Sounds/Custom/SubsumingVortexExplosion"); diff --git a/Projectiles/Magic/EnormousConsumingVortex.cs b/Projectiles/Magic/EnormousConsumingVortex.cs index 418c72b519..59e21347fd 100644 --- a/Projectiles/Magic/EnormousConsumingVortex.cs +++ b/Projectiles/Magic/EnormousConsumingVortex.cs @@ -83,7 +83,7 @@ namespace CalamityMod.Projectiles.Magic if (Main.myPlayer == Projectile.owner) { Projectile.velocity = Projectile.SafeDirectionTo(Main.MouseWorld) * SubsumingVortex.ReleaseSpeed; - Projectile.damage = (int)(Projectile.damage * (1f + Time * 0.0145f)); + Projectile.damage = (int)(Projectile.damage * (1f + Time * 0.0152f)); HasBeenReleased = true; Projectile.netUpdate = true; } From 74b484943a3ed4440027bdd7db6d8150ad6993d9 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Fri, 25 Aug 2023 10:18:55 -0400 Subject: [PATCH 017/138] SSV disappearing act --- Projectiles/Magic/EnormousConsumingVortex.cs | 2 -- 1 file changed, 2 deletions(-) diff --git a/Projectiles/Magic/EnormousConsumingVortex.cs b/Projectiles/Magic/EnormousConsumingVortex.cs index 59e21347fd..9e0aacb8b2 100644 --- a/Projectiles/Magic/EnormousConsumingVortex.cs +++ b/Projectiles/Magic/EnormousConsumingVortex.cs @@ -130,8 +130,6 @@ namespace CalamityMod.Projectiles.Magic } Projectile.netUpdate = true; } - else if (!vortexStillInUse) - Projectile.Kill(); } } From edef441be082d3213bee6e5f778f205aaa754c68 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Fri, 25 Aug 2023 10:59:03 -0400 Subject: [PATCH 018/138] Nerfed Prismatic Breaker laser damage --- Items/Weapons/Melee/PrismaticBreaker.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Melee/PrismaticBreaker.cs b/Items/Weapons/Melee/PrismaticBreaker.cs index 76a3836524..43a1e1404d 100644 --- a/Items/Weapons/Melee/PrismaticBreaker.cs +++ b/Items/Weapons/Melee/PrismaticBreaker.cs @@ -84,7 +84,7 @@ namespace CalamityMod.Items.Weapons.Melee } else { - Projectile.NewProjectile(source, position.X, position.Y, velocity.X * 0.5f, velocity.Y * 0.5f, type, (int)(damage * 1.3f), knockback, player.whoAmI); + Projectile.NewProjectile(source, position.X, position.Y, velocity.X * 0.5f, velocity.Y * 0.5f, type, (int)(damage * 1.1f), knockback, player.whoAmI); } return false; } From b6dc1803fb0846d1ecf40bc153ff1c090aec362a Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Fri, 25 Aug 2023 11:01:48 -0400 Subject: [PATCH 019/138] Just realized I somehow fucked up the math and made the beam last 25 seconds instead of 15... --- Projectiles/Melee/PrismaticBeam.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Projectiles/Melee/PrismaticBeam.cs b/Projectiles/Melee/PrismaticBeam.cs index 9eb22b1903..712cd1c434 100644 --- a/Projectiles/Melee/PrismaticBeam.cs +++ b/Projectiles/Melee/PrismaticBeam.cs @@ -48,7 +48,7 @@ namespace CalamityMod.Projectiles.Melee public Player Owner => Main.player[Projectile.owner]; public override Color LaserOverlayColor => CalamityUtils.MulticolorLerp(Main.GlobalTimeWrappedHourly / ColorSet.Length % 1f, ColorSet); public override Color LightCastColor => LaserOverlayColor; - public override float Lifetime => 1500f; + public override float Lifetime => 900f; public override float MaxScale => 1.5f; public override float MaxLaserLength => 2200f; public override Texture2D LaserBeginTexture => ModContent.Request("CalamityMod/ExtraTextures/Lasers/UltimaRayStart", AssetRequestMode.ImmediateLoad).Value; @@ -67,7 +67,7 @@ namespace CalamityMod.Projectiles.Melee Projectile.penetrate = -1; Projectile.tileCollide = false; Projectile.hide = true; - Projectile.timeLeft = 1500; + Projectile.timeLeft = 900; Projectile.usesLocalNPCImmunity = true; Projectile.localNPCHitCooldown = 10; } From 1b4836a55ecbf3649a9b340e4e1f16cca185f762 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Fri, 25 Aug 2023 11:35:18 -0400 Subject: [PATCH 020/138] Reduced Prismatic Breaker's Thanatos resist (why was it 50%?????) --- Balancing/BalancingChangesManager.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Balancing/BalancingChangesManager.cs b/Balancing/BalancingChangesManager.cs index 398ec7fe84..f771e20fad 100644 --- a/Balancing/BalancingChangesManager.cs +++ b/Balancing/BalancingChangesManager.cs @@ -302,9 +302,6 @@ namespace CalamityMod.Balancing // 50% resist to Chicken Cannon. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.5f, ProjectileType())))); - // 50% resist to Prismatic Breaker. (why is this more than BOTH Rancor and Yharim's Crystal? jesus fuck this weapon seriously) - NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.5f, ProjectileType())))); - // 50% resist to Tarragon Throwing Darts Thorns. (LOL) NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.5f, ProjectileType(), ProjectileType())))); @@ -335,6 +332,9 @@ namespace CalamityMod.Balancing // 30% resist to Dragon Scales and The Wand's tornadoes NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.7f, ProjectileType(), ProjectileType())))); + // 30% resist to Prismatic Breaker's laser beam. + NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.7f, ProjectileType())))); + // 25% resist to Dragon Rage projectiles. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileSpecificRequirementBalancingRule(0.75f, DragonRageFilter)))); From e397aa1dd543ce10f9343f426f3e6ea25ef9022e Mon Sep 17 00:00:00 2001 From: Altixal <73398287+Altixal@users.noreply.github.com> Date: Fri, 25 Aug 2023 23:58:49 +0700 Subject: [PATCH 021/138] alcohol buffs and radiant star resprites --- Buffs/Alcohol/BloodyMaryBuff.png | Bin 582 -> 607 bytes Buffs/Alcohol/CaribbeanRumBuff.png | Bin 567 -> 652 bytes Buffs/Alcohol/CinnamonRollBuff.png | Bin 517 -> 584 bytes Buffs/Alcohol/EverclearBuff.png | Bin 633 -> 694 bytes Buffs/Alcohol/EvergreenGinBuff.png | Bin 524 -> 720 bytes Buffs/Alcohol/FireballBuff.png | Bin 561 -> 627 bytes Buffs/Alcohol/GrapeBeerBuff.png | Bin 555 -> 661 bytes Buffs/Alcohol/MargaritaBuff.png | Bin 594 -> 698 bytes Buffs/Alcohol/MoonshineBuff.png | Bin 591 -> 702 bytes Buffs/Alcohol/MoscowMuleBuff.png | Bin 604 -> 776 bytes Buffs/Alcohol/RedWineBuff.png | Bin 552 -> 664 bytes Buffs/Alcohol/RumBuff.png | Bin 591 -> 739 bytes Buffs/Alcohol/ScrewdriverBuff.png | Bin 513 -> 622 bytes Buffs/Alcohol/StarBeamRyeBuff.png | Bin 608 -> 708 bytes Buffs/Alcohol/TequilaBuff.png | Bin 523 -> 639 bytes Buffs/Alcohol/TequilaSunriseBuff.png | Bin 555 -> 557 bytes Buffs/Alcohol/VodkaBuff.png | Bin 540 -> 585 bytes Buffs/Alcohol/WhiskeyBuff.png | Bin 573 -> 720 bytes Buffs/Alcohol/WhiteWineBuff.png | Bin 562 -> 667 bytes Items/Weapons/Rogue/RadiantStar.cs | 4 ++-- Items/Weapons/Rogue/RadiantStar.png | Bin 1331 -> 1064 bytes .../en-US/Mods.CalamityMod.Configs.hjson | 2 +- .../Mods.CalamityMod.Items.SummonItems.hjson | 4 ++-- ...Mods.CalamityMod.Items.Weapons.Magic.hjson | 2 +- Projectiles/Rogue/RadiantStar2.cs | 3 +-- Projectiles/Rogue/RadiantStarKnife.cs | 3 +-- 26 files changed, 8 insertions(+), 10 deletions(-) diff --git a/Buffs/Al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klT_-vOfg z3I7xj^loQ*%$G;p2IYq8gdin1J{TT+S3ogWtnOUw4K>gk;Jyh_x5VYqIf6e52yP#s zd8siCz}L&y0JwFf&)WBT?M<+6<;8z_T==6vrCT)}OI25FdcIf2Lyb{zJ1f-#f4gGA wRYK#Z@h7E25xd#$dM?DSK&2;)3$ZKk58rI0JI)vVo&W#<07*qoM6N<$f-~C%mH+?% diff --git a/Buffs/Alcohol/CaribbeanRumBuff.png b/Buffs/Alcohol/CaribbeanRumBuff.png index b6bd9fb9039c7e4a74781bed2258bd2f04ecc5c7..c3e5464b052914bbf5fe94dcdda758c747c769f1 100644 GIT binary patch delta 628 zcmV-)0*n2(1dIicBYyw^b5ch_0Itp)=>Px%MoC0LR9J=Om(NR7Q545N)0h>7#w@ad zOroGfL=iNEN{oVb6&VG#45U>;|A3p?1+D_yMMMNqE!sp$f*sfw_HM0K}f(lD04pgp;`6 z(J%JlUTYqA2=wQM0O-9b{kAQQ0GL^E@zb6aIC|nJ0GFro05sLhxG}*Cl~=BEhk)uE zi8sLkN+J=_oiG1K3AjfGbwfGg*3 zTjMGJ4zO@PPwmLVFi1fcWLVE`)q7yz|31*?7ROU11Sp8f_l#23#Vb73W6enOBwigSD3c*puo8z?f=lg3ZgTOXEW1!Mp1K%pH__g;pFU zcL=De+U1lh&s<5Ul$c8WKdt`=Kyh1C45hYWEE+iPUndax?)U%s@Axa?jk#Q{;Wf7a O0000zCBfQ5y1Vi7?^NRuJ~v9MSd3k4(EtU?TmfC^ckJbddyYN) zs~-qS0YRR>XnhXAlSH{Q-}t#LC(&l#ykkqTlciI0BW(s>iEtF~Js0G`^jgZ?C^f_5 zil+d?n_mH0W!_&70`RUm>F`9nY4-!dQ9w}4<+<#kL?;0AQon%*4MsJoylw0`gdSyPf`RCTysa&rBhhvkDx{9sxJ@f`!(J=T1xdfoP z>JgAV6H*282;nFYb*r{xxz!chEcmf|oRjG1?v-Qvot5fAxLvW}E1~iG=t4oncl{X& hMOPrk{}}#v{117tuPwMIn)d(z002ovPDHLkV1n+%1y29~ diff --git a/Buffs/Alcohol/CinnamonRollBuff.png b/Buffs/Alcohol/CinnamonRollBuff.png index 2d2e710cd485788d87c318f40114a970e0d119f7..075531eacc35208e68d71faea6966e8add03e85f 100644 GIT binary patch delta 560 zcmV-00?+-01jq!CBYyw^b5ch_0Itp)=>Px%0!c(cR9J=OmrF>LQ5462;|$@VL`;;y zQmHl}iH>Nv@G;WDl@drov{rC65N@=#u2cj;XdSpPA&L-J`GiSSgcjz)2U;?wG5Lxl zlxcD2&UCJyGmL@W=)bw&Ip>~p&-rui<8u*5go}j>Ank$|b$`qv0^loX7KX0;Mn{K^ zjW)b?RL~M51g)ithEOK z|BI)N@h+W#SPzU=4Fd7X)4j41|MRw#0)O54k#^QA~|9$T>0CG#q0Qk8u zFXow;s_6ruY9b)?_At=5KMp|Posui=+ykI6J6|cn(s4DYPC#GF6KNQnbX>@+T*Dp) zG-6CFrxqx${O-9Du#W)^&4fnjRW;tKRA;~Lfxm^l41b&jz3-DTu*OFrpLHw#dkmP^ zoc#nO-v!pb2U2DrI4}gncY~HI+a8@O0ecvD>1`DTxA%&Wn-)6(xL%?vEvm1Lj>P~Z$XWd&@bipp$@Q#0bTKa@DPBEsH`*A7pjW)(gQ3Oe_@CQtk6o(NkEvzj> z>{LkMPnFWzPMd((S%@TpowcChiV&h0wGe|K*2cz^TI|iiZgP=;a0|X>Z`j#)J8y4h z=OVy2A)+hHmjiUm!(r@Ln{d8HG&_}@?ufXwf2Y}Q@0(_C*MHUln-ma8~rJ~i9)6UBVLq8dyk>`}msTp$t5S2x=;Rdw@v>PWMF-lFbjj{*WYONrb+TQ92~$65u-2jF2(Mc8oS01PB&m0c-oenC9` zdv?`ej{+tnD}T&<7u4Jr0A@B;^@&1RTW3~O6ZR<}JD0qDF21UX!S+PMsd3Ggb;8q> z4IV;QpyLh1oH#Kr147xrUn8&*%6;zFaP`sqc`sQI1oImT>L=_|Kp^*aD(&q&AmI1X z6VRLmqNH2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`2`wJ0r0$|27vm>*8r?Kyk=iu_KNl>AaHv) z5A1DZfm;9Sz|VC6I{v6R@zTT3i`RDr+@4U*1zufoT|8P4@nTOB$VD#oKvspl=K^>A vOYi1f7h}nShz~m%34B+;odbTscLnwVO!m5Wm=zMH00000NkvXXu0mjf2q_mm diff --git a/Buffs/Alcohol/EvergreenGinBuff.png b/Buffs/Alcohol/EvergreenGinBuff.png index c7d719d0655608674c37a24311980027db0f65d8..5e41d87eb635a0b2c7cd52f1cd11632dacd6db1d 100644 GIT binary patch delta 697 zcmV;q0!ICe1keSLBYyw^b5ch_0Itp)=>Px%ib+I4R9J=Om)}d1Q5eTR%g70~hDh+L zZAD!KT7+aJsKfALR|O?R7eRLeyGZa~u(~q5GJ?R1Agaxb=wgJhtshG)A|_Hqwwd8; zxz-wDEf?$Jyl3l-cVk!jM&Fy~oacGYdCv1a&(8DCMiF^77JoK?EgKxv^b~o3cJ~>@ zaM^WIncv`QRU1a;stdf5dI?y7fvu$qnR#o!TQvlP@EmSa)Tys40L;ceR}2*LjR4Sl zeMr%7Is=6o2zK8BikaIrCjjT}Tmm5V<`n?WT0xql-VQ)!^(O%7Yz}}KX9EEF=oA1u z8+uFwTek)zWPj!-&Wf6N6m16J{?Y;fzFZc7Kyxhs-gU9nP*(>4Hu?a_M;`;_nXnE6 zU((+JXj#rF4)cpk01RKe0KlY6)X24oy8w)p_(@p~PduXl?4Rrcti-@*CJeyfLop9- zPl&-&A;t~Ay}OzK7zjrI@ak!0!=NtK9Z9E519nFSm4CT)7?6-mXvy~g1Py)Ap8&wC z?G{q%^@OrsX1@5%oPknUj{ymN&pt6|KO|%_3Bb%jwHFXGel?Aa!fyC!kuU&pVigZy zT?Ps;G8*eY4M0!FQN=u7R|mj|-!BxdmWtcSuGn_P1N;*V7#a@d+ zNv)KF<$t~h$}*tE#XF!&g>koqj3qvPQe@#BsPX{TVc@3bQw)6zAppEPL=D)RL>H93 zKw@tFg))~fr&jV3$}ad@{{=wn^l`vS4Af}b0LVOF1t8RU4}jk3Qve)T{s6#inT_N( zq0Ic5{s4d<$JT^{Zo14u3`jUS>w)53O}THIE;5viNl1SjLad$7N>35!ZH?+@VAC0} f{WbnS{~iAUVa><@T|Dge00000NkvXXu0mjfsL44u delta 499 zcmV5WJRK@@omeOVlOAJW*}#btAsxaxRDErV5@L!23m|6T^uv(Q*i*2Ge()&=LrC& zdWS5YkT+*PfIkWd%DEz!zmORLU?aN&z;IUvfOMi6fR*6>h4~SS&*kw~0k_VTb4Bjr zaQ`T{8vb?zmwzYRXUQ0U6mX%cP!0zk=YX%bzj%HFK&t-98c(j7YB+6Ow|Ju9p8|?l zb$gw=GZQgmRQFOK9ZOXt)_vkBtA+snDezZBDe)8hQ$RV=c^-blA1f2&?@K_r0`5B$ z)lc}RfS_}`KNCE8)|l(kt+mee1u2;?1U&ezfO4)}xoqdTp!)Cb>#+PNxIAvJ=#K(I z*uyz~-OD=wiH3IIs~?cn>8N#4JTClEAnaCyj-{+CE*f*Nw`8U>rnsz002ovPDHLkV1na-@*DsF diff --git a/Buffs/Alcohol/FireballBuff.png b/Buffs/Alcohol/FireballBuff.png index 31c326dcfc22bbf0f15d2582d3982d45805cf108..7ee97843121f56ec1848843fb68c71ba5e16a1b8 100644 GIT binary patch delta 603 zcmV-h0;K)11oH%tBYyw^b5ch_0Itp)=>Px%ElET{R9J=Ompw>ZQ5462@k!NUL>z>G zC`HjBq@aVH;@99EJ`}ucVlnzo)QJUrT^uMvbVWWW_U7T*l_uWVn+G&dAT!w^nY)`yEIV|Mi}tr0Jph#E3V$#X1fZ~>Mv0&9 z=mnsD;HBkw`Y4dhJlmD81pZjq1?plJIPfc^Hh88N(tzzfF0J&Z!VdyC)U8l{p@bVe@}tq_n!cWg{A-~H+KhkZF&gkUk_Y{ z!!KEioj4Iq+eskZApxBf7`x!>ucjs0UUa%_Vv1m}5PyM12q=O`WFaAvB508=h?QWLRZ?isVo?-9ECUHhuvm!2yz^kLuCg{e z;A!UFc{68b&V6_8eP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P4i z`3eBv_w*Y5tJaqSaMU9+OpOh#Co1)3uQiH?J2E9PmuktF#>dC(5y}uJ6J>@Qi=lA! zUB77m5>h!CSr$Nj>reO`qr2%7VO?r13;E{((Kpw2oQSm`QBWkJ={@je0nY5OwtpdEbDc5 z$0D{rbcEt@h>`qMSDMUzJn0?_ zLNi|_GZP6XxsnhN$~GNWB=PMF2)V15W!)?LNqP76&DN||-*^~+^t445K)|k3>1ne5 zcBcKD;V8o84~S#9*mZUmZpY1pl+31`DY8Yj+rE_;(TcB9GI>kA7C`S+@o?eZPutb| z?S8Cg)^B3E+()P=LEP-V!0jM}$fyd(WFGQI|33hnX+H-zZ@pm-z)9hxnB)ImaUG%mo|byLC5a0FxOV5J p)4OiC-kH|GofLuGtjKkQ{sms7xk3>Bn$iFO002ovPDHLkV1l?Dhw}gc diff --git a/Localization/en-US/Mods.CalamityMod.Configs.hjson b/Localization/en-US/Mods.CalamityMod.Configs.hjson index eba58802b8..f2f8a3ade9 100644 --- a/Localization/en-US/Mods.CalamityMod.Configs.hjson +++ b/Localization/en-US/Mods.CalamityMod.Configs.hjson @@ -423,4 +423,4 @@ CalamityConfig: { Label: "[i:Book] Wiki Status Message" Tooltip: Enable or disable the status message promoting the Official Calamity Wiki that plays on world entry. } -} +} \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson b/Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson index ef43f00306..68e9863f99 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.SummonItems.hjson @@ -235,7 +235,7 @@ RuneofKos: { Tooltip: ''' An ornate sigil of the Profaned Flame - Hatred yet burns upon its brow + Hatred yet burns upon its brow [SPAWN] Not consumable ''' @@ -307,4 +307,4 @@ YharonEgg: { Not consumable An effigy of a Phoenix Dragon egg, used in worship ''' -} +} \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson index a52ec10ad9..9b7399e9de 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Magic.hjson @@ -955,4 +955,4 @@ YharimsCrystal: { Tooltip: "[GFB]" TooltipNormal: Fires draconic beams of total annihilation TooltipGFB: ...throughs a pice of dnimite -} +} \ No newline at end of file diff --git a/Projectiles/Rogue/RadiantStar2.cs b/Projectiles/Rogue/RadiantStar2.cs index 6cc2c03ae1..c7a125d31a 100644 --- a/Projectiles/Rogue/RadiantStar2.cs +++ b/Projectiles/Rogue/RadiantStar2.cs @@ -22,8 +22,7 @@ namespace CalamityMod.Projectiles.Rogue public override void SetDefaults() { - Projectile.width = 24; - Projectile.height = 24; + Projectile.width = Projectile.height = 32; Projectile.friendly = true; Projectile.ignoreWater = true; Projectile.penetrate = 1; diff --git a/Projectiles/Rogue/RadiantStarKnife.cs b/Projectiles/Rogue/RadiantStarKnife.cs index c2727d3a69..2b5d9812d3 100644 --- a/Projectiles/Rogue/RadiantStarKnife.cs +++ b/Projectiles/Rogue/RadiantStarKnife.cs @@ -22,8 +22,7 @@ namespace CalamityMod.Projectiles.Rogue public override void SetDefaults() { - Projectile.width = 24; - Projectile.height = 24; + Projectile.width = Projectile.height = 32; Projectile.friendly = true; Projectile.ignoreWater = true; Projectile.penetrate = 4; From 6bf27522344044641773f809d7538b252d981c24 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Fri, 25 Aug 2023 14:54:31 -0400 Subject: [PATCH 022/138] Nerfed SSV damage more, and prevented large vortex from firing small vortices if it has already been released --- Items/Weapons/Magic/SubsumingVortex.cs | 2 +- Projectiles/Magic/EnormousConsumingVortex.cs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Magic/SubsumingVortex.cs b/Items/Weapons/Magic/SubsumingVortex.cs index fefa9fab34..e8f91b17a0 100644 --- a/Items/Weapons/Magic/SubsumingVortex.cs +++ b/Items/Weapons/Magic/SubsumingVortex.cs @@ -45,7 +45,7 @@ namespace CalamityMod.Items.Weapons.Magic public override void SetDefaults() { - Item.damage = 507; + Item.damage = 483; Item.DamageType = DamageClass.Magic; Item.useTime = Item.useAnimation = 20; Item.shootSpeed = 7f; diff --git a/Projectiles/Magic/EnormousConsumingVortex.cs b/Projectiles/Magic/EnormousConsumingVortex.cs index 9e0aacb8b2..942699f649 100644 --- a/Projectiles/Magic/EnormousConsumingVortex.cs +++ b/Projectiles/Magic/EnormousConsumingVortex.cs @@ -112,9 +112,9 @@ namespace CalamityMod.Projectiles.Magic GeneralParticleHandler.SpawnParticle(exoEnergy); } - // Fire vortices at nearby target if not fully charged yet. + // Fire vortices at nearby target if not fully charged and has not been released yet. NPC potentialTarget = Projectile.Center.ClosestNPCAt(SubsumingVortex.SmallVortexTargetRange - 100f); - if (potentialTarget != null && Time % SubsumingVortex.VortexReleaseRate == SubsumingVortex.VortexReleaseRate - 1 && Time < SubsumingVortex.LargeVortexChargeupTime) + if (potentialTarget != null && Time % SubsumingVortex.VortexReleaseRate == SubsumingVortex.VortexReleaseRate - 1 && Time < SubsumingVortex.LargeVortexChargeupTime && !HasBeenReleased) { // CheckMana returns true if the mana cost can be paid.. bool allowContinuedUse = Owner.CheckMana(Owner.ActiveItem(), -1, true, false); From 423fb3b2d60bb52184b5819ebba0882b90098215 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Fri, 25 Aug 2023 18:19:52 -0400 Subject: [PATCH 023/138] severely reduced boss rush damage floor until a proper fix --- CalPlayer/CalamityPlayerHitHurt.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CalPlayer/CalamityPlayerHitHurt.cs b/CalPlayer/CalamityPlayerHitHurt.cs index 106de27fb0..e1cc1677dd 100644 --- a/CalPlayer/CalamityPlayerHitHurt.cs +++ b/CalPlayer/CalamityPlayerHitHurt.cs @@ -1629,9 +1629,10 @@ namespace CalamityMod.CalPlayer private void ModifyHurtInfo_Calamity(ref Player.HurtInfo info) { // Boss Rush's damage floor is implemented as a dirty modifier + // TODO -- implementing this correctly would require fully reimplementing all of DR and ADR if (BossRushEvent.BossRushActive) { - int bossRushDamageFloor = (Main.expertMode ? 400 : 240) + (BossRushEvent.BossRushStage * 2); + int bossRushDamageFloor = (Main.expertMode ? 160 : 100) + (BossRushEvent.BossRushStage * 2); if (info.Damage < bossRushDamageFloor) info.Damage += (bossRushDamageFloor - info.Damage); } From 664b0925351db8ae38cde2d0ffda609f73fce1c7 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Fri, 25 Aug 2023 18:26:48 -0400 Subject: [PATCH 024/138] Empyrean Knives and Poseidon balance Poseidon is definitely not final --- Items/Weapons/Magic/Poseidon.cs | 9 ++++----- Items/Weapons/Melee/EmpyreanKnives.cs | 2 +- Projectiles/Magic/PoseidonTyphoon.cs | 8 +++++--- Projectiles/Melee/EmpyreanKnife.cs | 2 +- 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/Items/Weapons/Magic/Poseidon.cs b/Items/Weapons/Magic/Poseidon.cs index 434ca31c28..d8f8451f9a 100644 --- a/Items/Weapons/Magic/Poseidon.cs +++ b/Items/Weapons/Magic/Poseidon.cs @@ -12,13 +12,13 @@ namespace CalamityMod.Items.Weapons.Magic public new string LocalizationCategory => "Items.Weapons.Magic"; public override void SetDefaults() { - Item.damage = 62; + Item.damage = 52; Item.DamageType = DamageClass.Magic; Item.mana = 12; Item.width = 28; Item.height = 32; - Item.useTime = 45; - Item.useAnimation = 45; + Item.useTime = 49; + Item.useAnimation = 49; Item.useStyle = ItemUseStyleID.Shoot; Item.noMelee = true; Item.knockBack = 6f; @@ -27,13 +27,12 @@ namespace CalamityMod.Items.Weapons.Magic Item.rare = ItemRarityID.Pink; Item.autoReuse = true; Item.shoot = ModContent.ProjectileType(); - Item.shootSpeed = 20f; + Item.shootSpeed = 18f; } public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) { int typhoon = Projectile.NewProjectile(source, position, velocity, type, damage, knockback, player.whoAmI, 0f, 0f); - Main.projectile[typhoon].penetrate = Main.rand.Next(4,11); return false; } } diff --git a/Items/Weapons/Melee/EmpyreanKnives.cs b/Items/Weapons/Melee/EmpyreanKnives.cs index e6a600fb90..61af6ce656 100644 --- a/Items/Weapons/Melee/EmpyreanKnives.cs +++ b/Items/Weapons/Melee/EmpyreanKnives.cs @@ -17,7 +17,7 @@ namespace CalamityMod.Items.Weapons.Melee public override void SetDefaults() { Item.width = 18; - Item.damage = 198; + Item.damage = 207; Item.DamageType = DamageClass.MeleeNoSpeed; Item.noMelee = true; Item.noUseGraphic = true; diff --git a/Projectiles/Magic/PoseidonTyphoon.cs b/Projectiles/Magic/PoseidonTyphoon.cs index ef3a55a3d3..2d2416bbca 100644 --- a/Projectiles/Magic/PoseidonTyphoon.cs +++ b/Projectiles/Magic/PoseidonTyphoon.cs @@ -18,10 +18,12 @@ namespace CalamityMod.Projectiles.Magic Projectile.height = 30; Projectile.friendly = true; Projectile.DamageType = DamageClass.Magic; - Projectile.penetrate = 10; //randomized in the item file now, penetrates 4 to 10 times - Projectile.timeLeft = 300; + Projectile.penetrate = 6; + Projectile.timeLeft = 240; Projectile.ignoreWater = true; Projectile.scale = 1.6f; + Projectile.usesLocalNPCImmunity = true; + Projectile.localNPCHitCooldown = 30; } public override void AI() @@ -31,7 +33,7 @@ namespace CalamityMod.Projectiles.Magic Lighting.AddLight(Projectile.Center, 0, (255 - Projectile.alpha) * 0.7f / 255f, (255 - Projectile.alpha) / 255f); - CalamityUtils.HomeInOnNPC(Projectile, !Projectile.tileCollide, 600f, 6f, 30f); + CalamityUtils.HomeInOnNPC(Projectile, !Projectile.tileCollide, 600f, 10f, 30f); } public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) => target.AddBuff(ModContent.BuffType(), 180); diff --git a/Projectiles/Melee/EmpyreanKnife.cs b/Projectiles/Melee/EmpyreanKnife.cs index 2b4b202b8c..a327401b8f 100644 --- a/Projectiles/Melee/EmpyreanKnife.cs +++ b/Projectiles/Melee/EmpyreanKnife.cs @@ -78,7 +78,7 @@ namespace CalamityMod.Projectiles.Melee public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) { - float healAmt = hit.Damage * 0.005f; + float healAmt = hit.Damage * 0.0075f; if ((int)healAmt == 0) return; From 9e2f0c0fc502733871f56fa1c55e58ecf0e04acb Mon Sep 17 00:00:00 2001 From: Mishiro Usui Date: Fri, 25 Aug 2023 23:33:55 +0100 Subject: [PATCH 025/138] Update ThankYouPainting.cs --- Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs b/Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs index ab2b6a4fb7..e6f9ccb72d 100644 --- a/Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs +++ b/Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs @@ -67,6 +67,7 @@ namespace CalamityMod.Items.Placeables.Furniture.DevPaintings "Ben-TK", "Cei", "Cooper", + "CongratsIsTrash", "CrabBar", "Done", "DylanDoe21", @@ -91,7 +92,6 @@ namespace CalamityMod.Items.Placeables.Furniture.DevPaintings "Shayy", "Spider Prov", "StipulateVenus", - "Sylvium", "Tomat", "Triangle", "Uberransy", @@ -182,6 +182,7 @@ namespace CalamityMod.Items.Placeables.Furniture.DevPaintings "spooktacular", "Spoopyro", "Svante", + "Sylvium", "Teragat", "Terry N. Muse", "ThousandFields", From 678685eae5692fed08cfe497046a5dcc06ae60dc Mon Sep 17 00:00:00 2001 From: Mishiro Usui Date: Fri, 25 Aug 2023 23:39:23 +0100 Subject: [PATCH 026/138] Apparently i don't know the alphabet --- Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs b/Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs index e6f9ccb72d..6b86d860fd 100644 --- a/Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs +++ b/Items/Placeables/Furniture/DevPaintings/ThankYouPainting.cs @@ -66,8 +66,8 @@ namespace CalamityMod.Items.Placeables.Furniture.DevPaintings "Atalya", "Ben-TK", "Cei", - "Cooper", "CongratsIsTrash", + "Cooper", "CrabBar", "Done", "DylanDoe21", From b756e6e924f2f5ed37cd977ab5fd5f5bd05bdddb Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Fri, 25 Aug 2023 19:36:12 -0400 Subject: [PATCH 027/138] Further Poseidon changes --- Projectiles/Magic/PoseidonTyphoon.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Projectiles/Magic/PoseidonTyphoon.cs b/Projectiles/Magic/PoseidonTyphoon.cs index 2d2416bbca..e29fd95186 100644 --- a/Projectiles/Magic/PoseidonTyphoon.cs +++ b/Projectiles/Magic/PoseidonTyphoon.cs @@ -19,11 +19,11 @@ namespace CalamityMod.Projectiles.Magic Projectile.friendly = true; Projectile.DamageType = DamageClass.Magic; Projectile.penetrate = 6; - Projectile.timeLeft = 240; + Projectile.timeLeft = 270; Projectile.ignoreWater = true; Projectile.scale = 1.6f; Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = 30; + Projectile.localNPCHitCooldown = 40; } public override void AI() From 9d3de9f97f5070fe5bca439160e3e691b726221f Mon Sep 17 00:00:00 2001 From: Xyk Date: Fri, 25 Aug 2023 16:48:48 -0700 Subject: [PATCH 028/138] A better Purity sprite --- Items/Accessories/Purity.cs | 2 +- Items/Accessories/Purity.png | Bin 3265 -> 3263 bytes 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index 49e7f8f711..1e65c81fb3 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -17,7 +17,7 @@ namespace CalamityMod.Items.Accessories public override void SetDefaults() { Item.defense = 8; - Item.width = 22; + Item.width = 20; Item.height = 44; Item.accessory = true; Item.value = CalamityGlobalItem.Rarity12BuyPrice; diff --git a/Items/Accessories/Purity.png b/Items/Accessories/Purity.png index 2c81cd5c7cbc747f83788b160e52648d89ed855a..cb0df6f46617e18e03194f21e26d95342a530700 100644 GIT binary patch delta 526 zcmV+p0`dL98NV4JiBL{Q4GJ0x0000DNk~Le0000e0000i2nGNE02goid$A$D3V+K< zL_t(oh3(j}O9F8e!13>GVrz>-v`P_*B27X~H8?jov?dKH=-gjmpj&&;(Cl8|7>W{w z%?>UNExBHcukQD_>wX%7=lM3dcRxPo^M1egbX?bEnNe@GU4WZf)mh|zC$hjHxBwXl zTUZt_@&tBVECTS@?Xn0ox_0In(*#yT&rZvZqaO#q&r@2#NG z2MVOq>jSWp&lw;BN~?jNi39-ELOFgw;LlQ9!6e4B2emErS^#x|qreV8r`LA@4)*s9 z*jW8EBy3B)RzTl{G)!Vwm3D|3wxy0P(Dta)Kn?Tc0rQu7^?`$#P`>h#T7Q6lmR62F zX&MChJ{kd#{F(y6rCxpDq9xWFv))#uz519;0N75Y4Cr(#x#mDm7|lW{pK~_Ad4NGp zf&kBJRU>~ zL_t(oh1JzfC&p{KmHBgJa#D0XN?Z z_zoD+m;E0JpE|{kFnfKtFWv0BKxQ5dok%QU<_%M#vSQi^_XIhFcp- z1K{v3Zi!F_9ADo7u)4khK-3uV7#NtCG69DB`z+C%93843(9vpvq@f)$qJJ@uf&TGH z6QHiM=gVk@>ebMf4^Ax+$)X8lzm}-H19Z`}*Vh30qrxdF?|`mR1Nc}d`yp3eSit8B z2VcL1b~o4l36PhS4#3Uhv(La!hpcOyw7clXfNs%rkIb|b6;=FAz5aTW69(KKb`q78 zG)~%SnlwNcm6X#1XK8T}fMu1LX`g_q#umW+L%%pxEnHT*x^1UtW_<#rbi;N6<`%5c zNcjiYqmp6U7flz9e}EH|os;XTaY8`+4MLd-0(MA-F8@F`)V~MVAt|TEo&oRByqv?k S)epk}0000 Date: Sat, 26 Aug 2023 12:23:13 +0700 Subject: [PATCH 029/138] properly updated tarragon rogue's tooltip --- .../en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson b/Localization/en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson index 62df2dd5c0..eedbe2539a 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson @@ -554,8 +554,8 @@ TarragonHeadRogue: { SetBonus: ''' +115 maximum stealth - After every 25 rogue critical hits you will gain 3 seconds of damage immunity - This effect can only occur once every 30 seconds + After every 50 rogue critical hits you will gain 2.5 seconds of damage immunity + This effect has a cooldown of 25 seconds While under the effects of a debuff you gain 10% increased rogue damage ''' } From d4c4a5f4f97424c74bbdfb3d57f1d43d89b7f44e Mon Sep 17 00:00:00 2001 From: Altixal <73398287+Altixal@users.noreply.github.com> Date: Sat, 26 Aug 2023 16:41:08 +0700 Subject: [PATCH 030/138] arbalest tooltip update --- Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson index b1ec787467..2cd16dd402 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson @@ -62,7 +62,7 @@ Arbalest: { DisplayName: Arbalest Tooltip: ''' - Fires a volley of 10 high-speed arrows + Fires a volley of 6 high-speed arrows Arrows start off small and grow in size with continuous fire Arrow damage, spread and knockback scale with arrow size ''' From 92c768f0e3beecd54053a5d5962646cca139fa23 Mon Sep 17 00:00:00 2001 From: Altixal <73398287+Altixal@users.noreply.github.com> Date: Sat, 26 Aug 2023 18:28:07 +0700 Subject: [PATCH 031/138] community crit tooltip fix imagine adding decimal crits anyway --- Items/Accessories/TheCommunity.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Items/Accessories/TheCommunity.cs b/Items/Accessories/TheCommunity.cs index ccd0f1b00a..becea187c7 100644 --- a/Items/Accessories/TheCommunity.cs +++ b/Items/Accessories/TheCommunity.cs @@ -93,7 +93,7 @@ namespace CalamityMod.Items.Accessories // Damage stat boosts public const float DamageMultiplier = 0.5f; // 2.5% to 10% (x100) - public const float CritMultiplier = 25f; // 1.25% to 5% + public const float CritMultiplier = 25f; // 1.25% to 5% (end result rounded down) // Defensive stat boosts public const float HealthMultiplier = 50f; // 2% to 10% (rounded down) @@ -112,7 +112,7 @@ namespace CalamityMod.Items.Accessories float power = CalculatePower(); string statList = this.GetLocalization("StatsList").Format( (DamageMultiplier * power * 100).ToString("N1"), - (CritMultiplier * power).ToString("N0"), + (int)(CritMultiplier * power), (int)(HealthMultiplier * power), (DRMultiplier * power * 100).ToString("N2"), (int)(DefenseMultiplier * power), From d2302b5f0cb88d5bb9410ebe7604a9b7a94c485c Mon Sep 17 00:00:00 2001 From: Altixal <73398287+Altixal@users.noreply.github.com> Date: Sat, 26 Aug 2023 19:53:21 +0700 Subject: [PATCH 032/138] preventing a crash with YAQOLM there is probably a better way to do this (hi ozz) --- ILEditing/MechanicILChanges.cs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/ILEditing/MechanicILChanges.cs b/ILEditing/MechanicILChanges.cs index a6c0313621..0815435ac2 100644 --- a/ILEditing/MechanicILChanges.cs +++ b/ILEditing/MechanicILChanges.cs @@ -456,8 +456,14 @@ namespace CalamityMod.ILEditing private static string IncorporateEnchantmentInAffix(Terraria.On_Item.orig_AffixName orig, Item self) { string result = orig(self); - if (!self.IsAir && self.Calamity().AppliedEnchantment.HasValue) - result = $"{self.Calamity().AppliedEnchantment.Value.Name} {result}"; + + // This hook could occur before CalamityGlobalItem is loaded and throw an error. + try + { + if (!self.IsAir && self.Calamity().AppliedEnchantment.HasValue) + result = $"{self.Calamity().AppliedEnchantment.Value.Name} {result}"; + } + catch { } return result; } #endregion From 64ecb7b6ac6971d1360bd95bbb465ff092a9a6da Mon Sep 17 00:00:00 2001 From: HaguriHat <141063931+HaguriHat@users.noreply.github.com> Date: Sat, 26 Aug 2023 11:16:58 -0300 Subject: [PATCH 033/138] Dark God's Sheath > Dark Matter Sheath --- Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 5cd7eda970..4740a95ce8 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -481,7 +481,7 @@ DaawnlightSpiritOrigin: { } DarkGodsSheath: { - DisplayName: Dark God's Sheath + DisplayName: Dark Matter Sheath Tooltip: ''' +10 maximum stealth @@ -1991,4 +1991,4 @@ YharimsInsignia: { All melee attacks inflict Holy Flames Increased melee knockback ''' -} \ No newline at end of file +} From 6a60cae57f4a70385e7f5050e9c12b10ea577801 Mon Sep 17 00:00:00 2001 From: HaguriHat <141063931+HaguriHat@users.noreply.github.com> Date: Sat, 26 Aug 2023 11:18:39 -0300 Subject: [PATCH 034/138] Deific Thunderbolt > Twisting Thunder --- Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson index a334f86b58..47e2296970 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson @@ -283,7 +283,7 @@ DefectiveSphere: { } DeificThunderbolt: { - DisplayName: Deific Thunderbolt + DisplayName: Twisting Thunder Tooltip: ''' Fires a lightning bolt to electrocute enemies @@ -1387,4 +1387,4 @@ WulfrumKnife: { Stealth strikes make the knife fly further and hit several times at once Hold to magnetize all nearby fallen knives back to you ''' -} \ No newline at end of file +} From be970e40d6d0ba7f083c41cb8228ddff00bc1c17 Mon Sep 17 00:00:00 2001 From: HaguriHat <141063931+HaguriHat@users.noreply.github.com> Date: Sat, 26 Aug 2023 11:20:09 -0300 Subject: [PATCH 035/138] Gospawn Helix Staff > Starspawn Helix Staff --- .../en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson index 85e1ad5db0..24ea493bdf 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson @@ -403,7 +403,7 @@ GlacialEmbrace: { } GodspawnHelixStaff: { - DisplayName: Godspawn Helix Staff + DisplayName: Starspawn Helix Staff Tooltip: Summons astral probes to protect you } @@ -633,7 +633,7 @@ StormjawStaff: { } SunGodStaff: { - DisplayName: Sun God Staff + DisplayName: Vengeful Sun Staff Tooltip: ''' Summons a solar god spirit to protect you @@ -794,4 +794,4 @@ MirrorofKalandra: { StellarTorusStaff: { DisplayName: Stellar Torus Staff Tooltip: Summons a Torus Orbital that fries foes with a telescoping light beam -} \ No newline at end of file +} From 398adc67478decb268646dd653ece0cf779d204b Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sat, 26 Aug 2023 10:21:14 -0400 Subject: [PATCH 036/138] Dank Staff, Blood Clot Staff, Terra Ray, and The Hive balance --- Items/Weapons/Magic/TerraRay.cs | 2 +- Items/Weapons/Ranged/TheHive.cs | 6 +++--- Items/Weapons/Summon/BloodClotStaff.cs | 2 +- Items/Weapons/Summon/DankStaff.cs | 2 +- Projectiles/Magic/TerraBeam.cs | 6 +++--- Projectiles/Summon/BloodClotMinion.cs | 2 +- Projectiles/Summon/DankCreeperMinion.cs | 2 +- 7 files changed, 11 insertions(+), 11 deletions(-) diff --git a/Items/Weapons/Magic/TerraRay.cs b/Items/Weapons/Magic/TerraRay.cs index 1487295159..3101d05973 100644 --- a/Items/Weapons/Magic/TerraRay.cs +++ b/Items/Weapons/Magic/TerraRay.cs @@ -18,7 +18,7 @@ namespace CalamityMod.Items.Weapons.Magic public override void SetDefaults() { - Item.damage = 50; + Item.damage = 60; Item.DamageType = DamageClass.Magic; Item.mana = 10; Item.width = 54; diff --git a/Items/Weapons/Ranged/TheHive.cs b/Items/Weapons/Ranged/TheHive.cs index ff0d2344a8..1816264b40 100644 --- a/Items/Weapons/Ranged/TheHive.cs +++ b/Items/Weapons/Ranged/TheHive.cs @@ -12,12 +12,12 @@ namespace CalamityMod.Items.Weapons.Ranged public new string LocalizationCategory => "Items.Weapons.Ranged"; public override void SetDefaults() { - Item.damage = 80; + Item.damage = 60; Item.DamageType = DamageClass.Ranged; Item.width = 62; Item.height = 30; - Item.useTime = 21; - Item.useAnimation = 21; + Item.useTime = 34; + Item.useAnimation = 34; Item.useStyle = ItemUseStyleID.Shoot; Item.noMelee = true; Item.knockBack = 3.5f; diff --git a/Items/Weapons/Summon/BloodClotStaff.cs b/Items/Weapons/Summon/BloodClotStaff.cs index 4d53e483aa..0636ef149b 100644 --- a/Items/Weapons/Summon/BloodClotStaff.cs +++ b/Items/Weapons/Summon/BloodClotStaff.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Summon public new string LocalizationCategory => "Items.Weapons.Summon"; public override void SetDefaults() { - Item.damage = 7; + Item.damage = 9; Item.mana = 10; Item.width = 58; Item.height = 64; diff --git a/Items/Weapons/Summon/DankStaff.cs b/Items/Weapons/Summon/DankStaff.cs index c1062c2e63..e56b5e9522 100644 --- a/Items/Weapons/Summon/DankStaff.cs +++ b/Items/Weapons/Summon/DankStaff.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Summon public new string LocalizationCategory => "Items.Weapons.Summon"; public override void SetDefaults() { - Item.damage = 7; + Item.damage = 9; Item.mana = 10; Item.width = 58; Item.height = 58; diff --git a/Projectiles/Magic/TerraBeam.cs b/Projectiles/Magic/TerraBeam.cs index 61d3ad9bee..a8cdb69688 100644 --- a/Projectiles/Magic/TerraBeam.cs +++ b/Projectiles/Magic/TerraBeam.cs @@ -28,7 +28,7 @@ namespace CalamityMod.Projectiles.Magic Projectile.ignoreWater = true; Projectile.penetrate = 10; Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = 8; + Projectile.localNPCHitCooldown = 12; Projectile.tileCollide = false; Projectile.timeLeft = (int)Lifetime; } @@ -90,9 +90,9 @@ namespace CalamityMod.Projectiles.Magic // boxes, but that should be negligible. float lengthFromStart = Projectile.Distance(target.Center); - int totalShards = (int)MathHelper.Lerp(1, 4, MathHelper.Clamp(lengthFromStart / MaxLaserLength * 1.4f, 0f, 1f)); + int totalShards = (int)MathHelper.Lerp(1, 3, MathHelper.Clamp(lengthFromStart / MaxLaserLength * 1.5f, 0f, 1f)); int shardType = ModContent.ProjectileType(); - int shardDamage = (int)(Projectile.damage * 0.6); + int shardDamage = (int)(Projectile.damage * 0.5); for (int i = 0; i < totalShards; i++) { int tries = 0; diff --git a/Projectiles/Summon/BloodClotMinion.cs b/Projectiles/Summon/BloodClotMinion.cs index fb58e7187c..5df7b760fa 100644 --- a/Projectiles/Summon/BloodClotMinion.cs +++ b/Projectiles/Summon/BloodClotMinion.cs @@ -33,7 +33,7 @@ namespace CalamityMod.Projectiles.Summon Projectile.tileCollide = false; Projectile.MaxUpdates = 3; Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = Projectile.MaxUpdates * 24; + Projectile.localNPCHitCooldown = Projectile.MaxUpdates * 30; Projectile.DamageType = DamageClass.Summon; } diff --git a/Projectiles/Summon/DankCreeperMinion.cs b/Projectiles/Summon/DankCreeperMinion.cs index aabd4f4191..666edf8be2 100644 --- a/Projectiles/Summon/DankCreeperMinion.cs +++ b/Projectiles/Summon/DankCreeperMinion.cs @@ -32,7 +32,7 @@ namespace CalamityMod.Projectiles.Summon Projectile.tileCollide = false; Projectile.MaxUpdates = 3; Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = Projectile.MaxUpdates * 24; + Projectile.localNPCHitCooldown = Projectile.MaxUpdates * 30; Projectile.DamageType = DamageClass.Summon; } From a228884ccb9acdbb19e314aedd10484b733123e4 Mon Sep 17 00:00:00 2001 From: HaguriHat <141063931+HaguriHat@users.noreply.github.com> Date: Sat, 26 Aug 2023 11:21:42 -0300 Subject: [PATCH 037/138] God's Bellows > Dead Sun's Wind --- .../en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson index 2cd16dd402..7e1f610c17 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson @@ -519,7 +519,7 @@ Galeforce: { } GodsBellows: { - DisplayName: God's Bellows + DisplayName: Dead Sun's Wind Tooltip: 70% chance to save ammo } @@ -1285,4 +1285,4 @@ WulfrumBlunderbuss: { [c/83B87E:'The good thing about Wulfrum is that while it breaks fast, it can be reused even faster.] [c/83B87E:In fact, it is quite common for a robot to be turned into ammo right after it stops functioning.'] ''' -} \ No newline at end of file +} From 839a23b5419fe1bb7ccc6422ed983e98df1405a9 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sat, 26 Aug 2023 11:17:58 -0400 Subject: [PATCH 038/138] Seeking Scorcher rebalance, with a combo of done and I's balance suggestions Damage to 232, hits 3 enemies --- Items/Weapons/Melee/SeekingScorcher.cs | 2 +- Projectiles/Melee/DivineHatchetBoomerang.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Items/Weapons/Melee/SeekingScorcher.cs b/Items/Weapons/Melee/SeekingScorcher.cs index da30a835ad..9de2ff5f31 100644 --- a/Items/Weapons/Melee/SeekingScorcher.cs +++ b/Items/Weapons/Melee/SeekingScorcher.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Melee public override void SetDefaults() { Item.width = 60; - Item.damage = 177; + Item.damage = 232; Item.noMelee = true; Item.noUseGraphic = true; Item.autoReuse = true; diff --git a/Projectiles/Melee/DivineHatchetBoomerang.cs b/Projectiles/Melee/DivineHatchetBoomerang.cs index dc7bf20165..bb9734bcd1 100644 --- a/Projectiles/Melee/DivineHatchetBoomerang.cs +++ b/Projectiles/Melee/DivineHatchetBoomerang.cs @@ -32,7 +32,7 @@ namespace CalamityMod.Projectiles.Melee Projectile.height = 60; Projectile.friendly = true; Projectile.tileCollide = false; - Projectile.penetrate = 4; + Projectile.penetrate = 3; Projectile.timeLeft = Lifetime; Projectile.DamageType = DamageClass.MeleeNoSpeed; Projectile.extraUpdates = 1; From f0ab7287488e66959253811ef259fb573d8d783c Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Sat, 26 Aug 2023 11:44:32 -0600 Subject: [PATCH 039/138] More nerfs to locket --- CalPlayer/CalamityPlayer.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index 6ec02390e7..47b6c0ad4f 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -3967,7 +3967,7 @@ namespace CalamityMod.CalPlayer num79 *= num80; float speedX4 = num78 + (float)Main.rand.Next(-30, 31) * 0.02f; float speedY5 = num79 + (float)Main.rand.Next(-30, 31) * 0.02f; - int p = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, (int)(damage * 0.075), knockBack * 0.5f, Player.whoAmI); + int p = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, (int)(damage * 0.07), knockBack * 0.5f, Player.whoAmI); if (p.WithinBounds(Main.maxProjectiles)) { From 94cc0856da1e1d7edb6aba1adc34faa4d6b3ae96 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sat, 26 Aug 2023 15:42:27 -0400 Subject: [PATCH 040/138] Gave Nadir Violet rarity --- Items/Weapons/Melee/Nadir.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Items/Weapons/Melee/Nadir.cs b/Items/Weapons/Melee/Nadir.cs index 09736a0e7d..cdd08c10b9 100644 --- a/Items/Weapons/Melee/Nadir.cs +++ b/Items/Weapons/Melee/Nadir.cs @@ -36,8 +36,8 @@ namespace CalamityMod.Items.Weapons.Melee Item.useStyle = ItemUseStyleID.Shoot; Item.UseSound = SoundID.Item1; - Item.value = CalamityGlobalItem.Rarity14BuyPrice; - Item.rare = ModContent.RarityType(); + Item.value = CalamityGlobalItem.Rarity15BuyPrice; + Item.rare = ModContent.RarityType(); Item.Calamity().donorItem = true; Item.shoot = ModContent.ProjectileType(); From af5e163703f6a65e0875549da403768808299928 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Sat, 26 Aug 2023 15:57:04 -0400 Subject: [PATCH 041/138] Removed redundant WorldSyncingSystem and merged with MiscWorldStateSystem. --- Systems/MiscWorldStateSystem.cs | 297 ++++++++++++++++++++++++++++++ Systems/WorldSyncingSystem.cs | 309 -------------------------------- 2 files changed, 297 insertions(+), 309 deletions(-) delete mode 100644 Systems/WorldSyncingSystem.cs diff --git a/Systems/MiscWorldStateSystem.cs b/Systems/MiscWorldStateSystem.cs index 1f69bbd246..a8b27f7cbd 100644 --- a/Systems/MiscWorldStateSystem.cs +++ b/Systems/MiscWorldStateSystem.cs @@ -1,4 +1,5 @@ using System.Collections.Generic; +using System.IO; using CalamityMod.CustomRecipes; using CalamityMod.Events; using CalamityMod.NPCs; @@ -8,6 +9,7 @@ using Terraria; using Terraria.ID; using Terraria.ModLoader; using Terraria.ModLoader.IO; +using static CalamityMod.DownedBossSystem; using static CalamityMod.World.CalamityWorld; namespace CalamityMod @@ -193,5 +195,300 @@ namespace CalamityMod CavernLabCenter = tag.Get("CavernLabCenter"); } #endregion Saving/Loading + + #region NetSend + public override void NetSend(BinaryWriter writer) + { + BitsByte flags = new BitsByte(); + flags[0] = downedDesertScourge; + flags[1] = downedHiveMind; + flags[2] = downedPerforator; + flags[3] = downedSlimeGod; + flags[4] = downedCryogen; + flags[5] = downedBrimstoneElemental; + flags[6] = downedCalamitasClone; + flags[7] = downedLeviathan; + + BitsByte flags2 = new BitsByte(); + flags2[0] = downedDoG; + flags2[1] = downedPlaguebringer; + flags2[2] = downedGuardians; + flags2[3] = downedProvidence; + flags2[4] = downedCeaselessVoid; + flags2[5] = downedStormWeaver; + flags2[6] = downedSignus; + flags2[7] = downedYharon; + + // Don't write meaningful values for the now-unused vanilla boss booleans + BitsByte flags3 = new BitsByte(); + flags3[0] = downedCalamitas; + flags3[1] = downedDragonfolly; + flags3[2] = downedCrabulon; + flags3[3] = downedBetsy; + flags3[4] = downedRavager; + flags3[5] = false; + flags3[6] = false; + flags3[7] = false; + + BitsByte flags4 = new BitsByte(); + flags4[0] = false; + flags4[1] = false; + flags4[2] = false; + flags4[3] = false; + flags4[4] = false; + flags4[5] = false; + flags4[6] = onionMode; + flags4[7] = revenge; + + BitsByte flags5 = new BitsByte(); + flags5[0] = downedAstrumDeus; + flags5[1] = spawnedBandit; + flags5[2] = spawnedCirrus; + flags5[3] = AcidRainEvent.HasStartedAcidicDownpour; + flags5[4] = false; + flags5[5] = downedPolterghast; + flags5[6] = death; + flags5[7] = downedGSS; + + BitsByte flags6 = new BitsByte(); + flags6[0] = Abyss.AtLeftSideOfWorld; + flags6[1] = downedAquaticScourge; + flags6[2] = downedAstrumAureus; + flags6[3] = false; + flags6[4] = armageddon; + flags6[5] = false; + flags6[6] = false; + flags6[7] = false; + + BitsByte flags7 = new BitsByte(); + flags7[0] = BossRushEvent.BossRushActive; + flags7[1] = downedBoomerDuke; + flags7[2] = downedCLAM; + flags7[3] = false; + flags7[4] = AcidRainEvent.AcidRainEventIsOngoing; + flags7[5] = downedEoCAcidRain; + flags7[6] = downedAquaticScourgeAcidRain; + flags7[7] = AcidRainEvent.HasTriedToSummonOldDuke; + + BitsByte flags8 = new BitsByte(); + flags8[0] = AcidRainEvent.HasBeenForceStartedByEoCDefeat; + flags8[1] = false; + flags8[2] = downedSecondSentinels; + flags8[3] = foundHomePermafrost; + flags8[4] = downedCLAMHardMode; + flags8[5] = catName; + flags8[6] = dogName; + flags8[7] = bunnyName; + + BitsByte flags9 = new BitsByte(); + flags9[0] = false; + flags9[1] = false; + flags9[2] = false; + flags9[3] = false; + flags9[4] = false; + flags9[5] = false; + flags9[6] = false; + flags9[7] = false; + + BitsByte flags10 = new BitsByte(); + flags10[0] = false; + flags10[1] = false; + flags10[2] = AcidRainEvent.OldDukeHasBeenEncountered; + flags10[3] = false; + flags10[4] = false; + flags10[5] = false; + flags10[6] = false; + flags10[7] = false; + + BitsByte flags11 = new BitsByte(); + flags11[0] = false; + flags11[1] = HasGeneratedLuminitePlanetoids; + flags11[2] = downedPrimordialWyrm; + flags11[3] = downedExoMechs; + flags11[4] = downedAres; + flags11[5] = downedThanatos; + flags11[6] = downedArtemisAndApollo; + flags11[7] = TalkedToDraedon; + + BitsByte flags12 = new BitsByte(); + flags12[0] = downedCragmawMire; + flags12[1] = downedMauler; + flags12[2] = downedNuclearTerror; + flags12[3] = downedBossRush; + flags12[4] = DraedonMechdusa; + + writer.Write(flags); + writer.Write(flags2); + writer.Write(flags3); + writer.Write(flags4); + writer.Write(flags5); + writer.Write(flags6); + writer.Write(flags7); + writer.Write(flags8); + writer.Write(flags9); + writer.Write(flags10); + writer.Write(flags11); + writer.Write(flags12); + + RecipeUnlockHandler.SendData(writer); + + writer.Write(Abyss.AbyssChasmBottom); + writer.Write(SulphurousSea.YStart); + writer.Write(AstralBiome.YStart); + writer.Write(AcidRainEvent.AccumulatedKillPoints); + writer.Write(Reforges); + writer.Write(MoneyStolenByBandit); + writer.Write(DraedonSummonCountdown); + writer.Write((int)DraedonMechToSummon); + writer.WriteVector2(DraedonSummonPosition); + writer.WriteVector2(SunkenSeaLabCenter); + writer.WriteVector2(PlanetoidLabCenter); + writer.WriteVector2(JungleLabCenter); + writer.WriteVector2(HellLabCenter); + writer.WriteVector2(IceLabCenter); + writer.WriteVector2(CavernLabCenter); + } + #endregion + + #region NetReceive + public override void NetReceive(BinaryReader reader) + { + BitsByte flags = reader.ReadByte(); + downedDesertScourge = flags[0]; + downedHiveMind = flags[1]; + downedPerforator = flags[2]; + downedSlimeGod = flags[3]; + downedCryogen = flags[4]; + downedBrimstoneElemental = flags[5]; + downedCalamitasClone = flags[6]; + downedLeviathan = flags[7]; + + BitsByte flags2 = reader.ReadByte(); + downedDoG = flags2[0]; + downedPlaguebringer = flags2[1]; + downedGuardians = flags2[2]; + downedProvidence = flags2[3]; + downedCeaselessVoid = flags2[4]; + downedStormWeaver = flags2[5]; + downedSignus = flags2[6]; + downedYharon = flags2[7]; + + // Explicitly discard the now-unused vanilla boss booleans + BitsByte flags3 = reader.ReadByte(); + downedCalamitas = flags3[0]; + downedDragonfolly = flags3[1]; + downedCrabulon = flags3[2]; + downedBetsy = flags3[3]; + downedRavager = flags3[4]; + _ = flags3[5]; + _ = flags3[6]; + _ = flags3[7]; + + BitsByte flags4 = reader.ReadByte(); + _ = flags4[0]; + _ = flags4[1]; + _ = flags4[2]; + _ = flags4[3]; + _ = flags4[4]; + _ = flags4[5]; + onionMode = flags4[6]; + revenge = flags4[7]; + + BitsByte flags5 = reader.ReadByte(); + downedAstrumDeus = flags5[0]; + spawnedBandit = flags5[1]; + spawnedCirrus = flags5[2]; + AcidRainEvent.HasStartedAcidicDownpour = flags5[3]; + _ = flags5[4]; + downedPolterghast = flags5[5]; + death = flags5[6]; + downedGSS = flags5[7]; + + BitsByte flags6 = reader.ReadByte(); + Abyss.AtLeftSideOfWorld = flags6[0]; + downedAquaticScourge = flags6[1]; + downedAstrumAureus = flags6[2]; + _ = flags6[3]; + armageddon = flags6[4]; + _ = flags6[5]; + _ = flags6[6]; + _ = flags6[7]; + + BitsByte flags7 = reader.ReadByte(); + BossRushEvent.BossRushActive = flags7[0]; + downedBoomerDuke = flags7[1]; + downedCLAM = flags7[2]; + _ = flags7[3]; + AcidRainEvent.AcidRainEventIsOngoing = flags7[4]; + downedEoCAcidRain = flags7[5]; + downedAquaticScourgeAcidRain = flags7[6]; + AcidRainEvent.HasTriedToSummonOldDuke = flags7[7]; + + BitsByte flags8 = reader.ReadByte(); + AcidRainEvent.HasBeenForceStartedByEoCDefeat = flags8[0]; + _ = flags8[1]; + downedSecondSentinels = flags8[2]; + foundHomePermafrost = flags8[3]; + downedCLAMHardMode = flags8[4]; + catName = flags8[5]; + dogName = flags8[6]; + bunnyName = flags8[7]; + + BitsByte flags9 = reader.ReadByte(); + _ = flags9[0]; + _ = flags9[1]; + _ = flags9[2]; + _ = flags9[3]; + _ = flags9[4]; + _ = flags9[5]; + _ = flags9[6]; + _ = flags9[7]; + + BitsByte flags10 = reader.ReadByte(); + _ = flags10[0]; + _ = flags10[1]; + AcidRainEvent.OldDukeHasBeenEncountered = flags10[2]; + _ = flags10[3]; + _ = flags10[4]; + _ = flags10[5]; + _ = flags10[6]; + _ = flags10[7]; + + BitsByte flags11 = reader.ReadByte(); + _ = flags11[0]; + HasGeneratedLuminitePlanetoids = flags11[1]; + downedPrimordialWyrm = flags11[2]; + downedExoMechs = flags11[3]; + downedAres = flags11[4]; + downedThanatos = flags11[5]; + downedArtemisAndApollo = flags11[6]; + TalkedToDraedon = flags11[7]; + + BitsByte flags12 = reader.ReadByte(); + downedCragmawMire = flags12[0]; + downedMauler = flags12[1]; + downedNuclearTerror = flags12[2]; + downedBossRush = flags12[3]; + DraedonMechdusa = flags12[4]; + + RecipeUnlockHandler.ReceiveData(reader); + + Abyss.AbyssChasmBottom = reader.ReadInt32(); + SulphurousSea.YStart = reader.ReadInt32(); + AstralBiome.YStart = reader.ReadInt32(); + AcidRainEvent.AccumulatedKillPoints = reader.ReadInt32(); + Reforges = reader.ReadInt32(); + MoneyStolenByBandit = reader.ReadInt32(); + DraedonSummonCountdown = reader.ReadInt32(); + DraedonMechToSummon = (ExoMech)reader.ReadInt32(); + DraedonSummonPosition = reader.ReadVector2(); + SunkenSeaLabCenter = reader.ReadVector2(); + PlanetoidLabCenter = reader.ReadVector2(); + JungleLabCenter = reader.ReadVector2(); + HellLabCenter = reader.ReadVector2(); + IceLabCenter = reader.ReadVector2(); + CavernLabCenter = reader.ReadVector2(); + } + #endregion } } diff --git a/Systems/WorldSyncingSystem.cs b/Systems/WorldSyncingSystem.cs deleted file mode 100644 index 1cabbe8654..0000000000 --- a/Systems/WorldSyncingSystem.cs +++ /dev/null @@ -1,309 +0,0 @@ -using System.IO; -using CalamityMod.CustomRecipes; -using CalamityMod.Events; -using CalamityMod.World; -using Terraria; -using Terraria.ModLoader; -using static CalamityMod.DownedBossSystem; -using static CalamityMod.World.CalamityWorld; - -namespace CalamityMod.Systems -{ - public class WorldSyncingSystem : ModSystem - { - #region NetSend - public override void NetSend(BinaryWriter writer) - { - BitsByte flags = new BitsByte(); - flags[0] = downedDesertScourge; - flags[1] = downedHiveMind; - flags[2] = downedPerforator; - flags[3] = downedSlimeGod; - flags[4] = downedCryogen; - flags[5] = downedBrimstoneElemental; - flags[6] = downedCalamitasClone; - flags[7] = downedLeviathan; - - BitsByte flags2 = new BitsByte(); - flags2[0] = downedDoG; - flags2[1] = downedPlaguebringer; - flags2[2] = downedGuardians; - flags2[3] = downedProvidence; - flags2[4] = downedCeaselessVoid; - flags2[5] = downedStormWeaver; - flags2[6] = downedSignus; - flags2[7] = downedYharon; - - // Don't write meaningful values for the now-unused vanilla boss booleans - BitsByte flags3 = new BitsByte(); - flags3[0] = downedCalamitas; - flags3[1] = downedDragonfolly; - flags3[2] = downedCrabulon; - flags3[3] = downedBetsy; - flags3[4] = downedRavager; - flags3[5] = false; - flags3[6] = false; - flags3[7] = false; - - BitsByte flags4 = new BitsByte(); - flags4[0] = false; - flags4[1] = false; - flags4[2] = false; - flags4[3] = false; - flags4[4] = false; - flags4[5] = false; - flags4[6] = onionMode; - flags4[7] = revenge; - - BitsByte flags5 = new BitsByte(); - flags5[0] = downedAstrumDeus; - flags5[1] = spawnedBandit; - flags5[2] = spawnedCirrus; - flags5[3] = AcidRainEvent.HasStartedAcidicDownpour; - flags5[4] = false; - flags5[5] = downedPolterghast; - flags5[6] = death; - flags5[7] = downedGSS; - - BitsByte flags6 = new BitsByte(); - flags6[0] = Abyss.AtLeftSideOfWorld; - flags6[1] = downedAquaticScourge; - flags6[2] = downedAstrumAureus; - flags6[3] = false; - flags6[4] = armageddon; - flags6[5] = false; - flags6[6] = false; - flags6[7] = false; - - BitsByte flags7 = new BitsByte(); - flags7[0] = BossRushEvent.BossRushActive; - flags7[1] = downedBoomerDuke; - flags7[2] = downedCLAM; - flags7[3] = false; - flags7[4] = AcidRainEvent.AcidRainEventIsOngoing; - flags7[5] = downedEoCAcidRain; - flags7[6] = downedAquaticScourgeAcidRain; - flags7[7] = AcidRainEvent.HasTriedToSummonOldDuke; - - BitsByte flags8 = new BitsByte(); - flags8[0] = AcidRainEvent.HasBeenForceStartedByEoCDefeat; - flags8[1] = false; - flags8[2] = downedSecondSentinels; - flags8[3] = foundHomePermafrost; - flags8[4] = downedCLAMHardMode; - flags8[5] = catName; - flags8[6] = dogName; - flags8[7] = bunnyName; - - BitsByte flags9 = new BitsByte(); - flags9[0] = false; - flags9[1] = false; - flags9[2] = false; - flags9[3] = false; - flags9[4] = false; - flags9[5] = false; - flags9[6] = false; - flags9[7] = false; - - BitsByte flags10 = new BitsByte(); - flags10[0] = false; - flags10[1] = false; - flags10[2] = AcidRainEvent.OldDukeHasBeenEncountered; - flags10[3] = false; - flags10[4] = false; - flags10[5] = false; - flags10[6] = false; - flags10[7] = false; - - BitsByte flags11 = new BitsByte(); - flags11[0] = false; - flags11[1] = HasGeneratedLuminitePlanetoids; - flags11[2] = downedPrimordialWyrm; - flags11[3] = downedExoMechs; - flags11[4] = downedAres; - flags11[5] = downedThanatos; - flags11[6] = downedArtemisAndApollo; - flags11[7] = TalkedToDraedon; - - BitsByte flags12 = new BitsByte(); - flags12[0] = downedCragmawMire; - flags12[1] = downedMauler; - flags12[2] = downedNuclearTerror; - flags12[3] = downedBossRush; - flags12[4] = DraedonMechdusa; - - writer.Write(flags); - writer.Write(flags2); - writer.Write(flags3); - writer.Write(flags4); - writer.Write(flags5); - writer.Write(flags6); - writer.Write(flags7); - writer.Write(flags8); - writer.Write(flags9); - writer.Write(flags10); - writer.Write(flags11); - writer.Write(flags12); - - RecipeUnlockHandler.SendData(writer); - - writer.Write(Abyss.AbyssChasmBottom); - writer.Write(SulphurousSea.YStart); - writer.Write(AstralBiome.YStart); - writer.Write(AcidRainEvent.AccumulatedKillPoints); - writer.Write(Reforges); - writer.Write(MoneyStolenByBandit); - writer.Write(DraedonSummonCountdown); - writer.Write((int)DraedonMechToSummon); - writer.WriteVector2(DraedonSummonPosition); - writer.WriteVector2(SunkenSeaLabCenter); - writer.WriteVector2(PlanetoidLabCenter); - writer.WriteVector2(JungleLabCenter); - writer.WriteVector2(HellLabCenter); - writer.WriteVector2(IceLabCenter); - writer.WriteVector2(CavernLabCenter); - } - #endregion - - #region NetReceive - public override void NetReceive(BinaryReader reader) - { - BitsByte flags = reader.ReadByte(); - downedDesertScourge = flags[0]; - downedHiveMind = flags[1]; - downedPerforator = flags[2]; - downedSlimeGod = flags[3]; - downedCryogen = flags[4]; - downedBrimstoneElemental = flags[5]; - downedCalamitasClone = flags[6]; - downedLeviathan = flags[7]; - - BitsByte flags2 = reader.ReadByte(); - downedDoG = flags2[0]; - downedPlaguebringer = flags2[1]; - downedGuardians = flags2[2]; - downedProvidence = flags2[3]; - downedCeaselessVoid = flags2[4]; - downedStormWeaver = flags2[5]; - downedSignus = flags2[6]; - downedYharon = flags2[7]; - - // Explicitly discard the now-unused vanilla boss booleans - BitsByte flags3 = reader.ReadByte(); - downedCalamitas = flags3[0]; - downedDragonfolly = flags3[1]; - downedCrabulon = flags3[2]; - downedBetsy = flags3[3]; - downedRavager = flags3[4]; - _ = flags3[5]; - _ = flags3[6]; - _ = flags3[7]; - - BitsByte flags4 = reader.ReadByte(); - _ = flags4[0]; - _ = flags4[1]; - _ = flags4[2]; - _ = flags4[3]; - _ = flags4[4]; - _ = flags4[5]; - onionMode = flags4[6]; - revenge = flags4[7]; - - BitsByte flags5 = reader.ReadByte(); - downedAstrumDeus = flags5[0]; - spawnedBandit = flags5[1]; - spawnedCirrus = flags5[2]; - AcidRainEvent.HasStartedAcidicDownpour = flags5[3]; - _ = flags5[4]; - downedPolterghast = flags5[5]; - death = flags5[6]; - downedGSS = flags5[7]; - - BitsByte flags6 = reader.ReadByte(); - Abyss.AtLeftSideOfWorld = flags6[0]; - downedAquaticScourge = flags6[1]; - downedAstrumAureus = flags6[2]; - _ = flags6[3]; - armageddon = flags6[4]; - _ = flags6[5]; - _ = flags6[6]; - _ = flags6[7]; - - BitsByte flags7 = reader.ReadByte(); - BossRushEvent.BossRushActive = flags7[0]; - downedBoomerDuke = flags7[1]; - downedCLAM = flags7[2]; - _ = flags7[3]; - AcidRainEvent.AcidRainEventIsOngoing = flags7[4]; - downedEoCAcidRain = flags7[5]; - downedAquaticScourgeAcidRain = flags7[6]; - AcidRainEvent.HasTriedToSummonOldDuke = flags7[7]; - - BitsByte flags8 = reader.ReadByte(); - AcidRainEvent.HasBeenForceStartedByEoCDefeat = flags8[0]; - _ = flags8[1]; - downedSecondSentinels = flags8[2]; - foundHomePermafrost = flags8[3]; - downedCLAMHardMode = flags8[4]; - catName = flags8[5]; - dogName = flags8[6]; - bunnyName = flags8[7]; - - BitsByte flags9 = reader.ReadByte(); - _ = flags9[0]; - _ = flags9[1]; - _ = flags9[2]; - _ = flags9[3]; - _ = flags9[4]; - _ = flags9[5]; - _ = flags9[6]; - _ = flags9[7]; - - BitsByte flags10 = reader.ReadByte(); - _ = flags10[0]; - _ = flags10[1]; - AcidRainEvent.OldDukeHasBeenEncountered = flags10[2]; - _ = flags10[3]; - _ = flags10[4]; - _ = flags10[5]; - _ = flags10[6]; - _ = flags10[7]; - - BitsByte flags11 = reader.ReadByte(); - _ = flags11[0]; - HasGeneratedLuminitePlanetoids = flags11[1]; - downedPrimordialWyrm = flags11[2]; - downedExoMechs = flags11[3]; - downedAres = flags11[4]; - downedThanatos = flags11[5]; - downedArtemisAndApollo = flags11[6]; - TalkedToDraedon = flags11[7]; - - BitsByte flags12 = reader.ReadByte(); - downedCragmawMire = flags12[0]; - downedMauler = flags12[1]; - downedNuclearTerror = flags12[2]; - downedBossRush = flags12[3]; - DraedonMechdusa = flags12[4]; - - RecipeUnlockHandler.ReceiveData(reader); - - Abyss.AbyssChasmBottom = reader.ReadInt32(); - SulphurousSea.YStart = reader.ReadInt32(); - AstralBiome.YStart = reader.ReadInt32(); - AcidRainEvent.AccumulatedKillPoints = reader.ReadInt32(); - Reforges = reader.ReadInt32(); - MoneyStolenByBandit = reader.ReadInt32(); - DraedonSummonCountdown = reader.ReadInt32(); - DraedonMechToSummon = (ExoMech)reader.ReadInt32(); - DraedonSummonPosition = reader.ReadVector2(); - SunkenSeaLabCenter = reader.ReadVector2(); - PlanetoidLabCenter = reader.ReadVector2(); - JungleLabCenter = reader.ReadVector2(); - HellLabCenter = reader.ReadVector2(); - IceLabCenter = reader.ReadVector2(); - CavernLabCenter = reader.ReadVector2(); - } - #endregion - } -} From f4f46d1fe05890f8c9f8b464c2733948f0599ea5 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Sat, 26 Aug 2023 14:22:13 -0600 Subject: [PATCH 042/138] Executioner's blade buffs and bugfix --- Items/Weapons/Rogue/ExecutionersBlade.cs | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/Items/Weapons/Rogue/ExecutionersBlade.cs b/Items/Weapons/Rogue/ExecutionersBlade.cs index 3ace052a76..3041d19896 100644 --- a/Items/Weapons/Rogue/ExecutionersBlade.cs +++ b/Items/Weapons/Rogue/ExecutionersBlade.cs @@ -18,7 +18,7 @@ namespace CalamityMod.Items.Weapons.Rogue public override void SetDefaults() { Item.width = 64; - Item.damage = 188; + Item.damage = 225; Item.noMelee = true; Item.noUseGraphic = true; Item.useTime = 3; @@ -41,19 +41,15 @@ namespace CalamityMod.Items.Weapons.Rogue { Item.DrawItemGlowmaskSingleFrame(spriteBatch, rotation, ModContent.Request("CalamityMod/Items/Weapons/Rogue/ExecutionersBladeGlow").Value); } - public override bool AdditionalStealthCheck() => counter == 0; + public override float StealthDamageMultiplier => 0.6f; public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) { - bool usingStealth = player.Calamity().StealthStrikeAvailable() && counter == 0; + bool usingStealth = player.Calamity().StealthStrikeAvailable(); int stealth = Projectile.NewProjectile(source, position, velocity, type, damage, knockback, player.whoAmI); if (usingStealth && stealth.WithinBounds(Main.maxProjectiles)) Main.projectile[stealth].Calamity().stealthStrike = true; - - counter++; - if (counter >= Item.useAnimation / Item.useTime) - counter = 0; return false; } From 4902ab5a228651cee29d361a117669bf1e64c86f Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Sat, 26 Aug 2023 16:52:42 -0400 Subject: [PATCH 043/138] Proper hook for resetting world data, courtesy Solxan --- Systems/MiscWorldStateSystem.cs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/Systems/MiscWorldStateSystem.cs b/Systems/MiscWorldStateSystem.cs index a8b27f7cbd..52fca6e672 100644 --- a/Systems/MiscWorldStateSystem.cs +++ b/Systems/MiscWorldStateSystem.cs @@ -16,8 +16,8 @@ namespace CalamityMod { public class MiscWorldStateSystem : ModSystem { - #region Resetting - public static void ResetWorldData() + #region Clear World Data (Reset) + public override void ClearWorld() { CalamityGlobalNPC.holyBoss = -1; CalamityGlobalNPC.doughnutBoss = -1; @@ -71,10 +71,6 @@ namespace CalamityMod AcidRainEvent.AcidRainEventIsOngoing = false; AcidRainEvent.CountdownUntilForcedAcidRain = 0; } - - public override void OnWorldLoad() => ResetWorldData(); - - public override void OnWorldUnload() => ResetWorldData(); #endregion #region Saving/Loading From da560e70e0560f14f2425f32799add963c4eda30 Mon Sep 17 00:00:00 2001 From: Xyk Date: Sat, 26 Aug 2023 14:19:19 -0700 Subject: [PATCH 044/138] 90 -> 60 frame defense tick down --- CalPlayer/CalamityPlayerLifeRegen.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index 5d370e5d72..e58a599036 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -566,7 +566,7 @@ namespace CalamityMod.CalPlayer if (PurityHealSpeed == 5) ReducedHealingCounter = 0; //Bonus defense goes down by 1 every second after - if (Player.miscCounter % 90 == 0 && PurityBonusDefense > 0) + if (Player.miscCounter % 60 == 0 && PurityBonusDefense > 0) PurityBonusDefense--; } @@ -580,7 +580,7 @@ namespace CalamityMod.CalPlayer if (!hasAnyDebuffs) { //Bonus defense goes down by 1 every second after - if (Player.miscCounter % 90 == 0 && InfectedJewelBonusDefense > 0) + if (Player.miscCounter % 60 == 0 && InfectedJewelBonusDefense > 0) InfectedJewelBonusDefense--; } for (int l = 0; l < Player.MaxBuffs; l++) @@ -609,7 +609,7 @@ namespace CalamityMod.CalPlayer if (!hasAnyDebuffs) { //Bonus defense goes down by 1 every second after - if (Player.miscCounter % 90 == 0 && CrownJewelBonusDefense > 0) + if (Player.miscCounter % 60 == 0 && CrownJewelBonusDefense > 0) CrownJewelBonusDefense--; } for (int l = 0; l < Player.MaxBuffs; l++) From 63d54ed1622e3e49bf05748f8b7aaa40e11624d0 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Sat, 26 Aug 2023 17:27:09 -0400 Subject: [PATCH 045/138] HIJACK: Platinum armor buff --- Items/VanillaArmorChanges/PlatinumArmorSetChange.cs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Items/VanillaArmorChanges/PlatinumArmorSetChange.cs b/Items/VanillaArmorChanges/PlatinumArmorSetChange.cs index 19b239eb06..9f7cd286e1 100644 --- a/Items/VanillaArmorChanges/PlatinumArmorSetChange.cs +++ b/Items/VanillaArmorChanges/PlatinumArmorSetChange.cs @@ -18,9 +18,10 @@ namespace CalamityMod.Items.VanillaArmorChanges public const float HeadDamage = 0.06f; public const float ChestCrit = 5f; public const float LegsMoveSpeed = 0.1f; - public const float SetBonusLifeRegenPerDefense = 0.0666667f; // 15 defense = +1 life regen - public const float SetBonusCritPerDefense = 0.0666667f; // 15 defense = +1% crit chance - public const int SetBonusDefenseCap = 45; + public const float SetBonusLifeRegenPerDefense = 0.1f; // 10 defense = +1 life regen + public const float SetBonusDamagePerDefense = 0.1f; // 10 defense = +1% damage + public const float SetBonusCritPerDefense = 0.1f; // 10 defense = +1% crit chance + public const int SetBonusDefenseCap = 40; public override void ApplyHeadPieceEffect(Player player) => player.GetDamage() += HeadDamage; @@ -31,7 +32,7 @@ namespace CalamityMod.Items.VanillaArmorChanges public override void UpdateSetBonusText(ref string setBonusText) { StringBuilder sb = new StringBuilder(256); - sb.Append("\nEvery 15 defense gives you +1 life regen and 1% increased critical strike chance\nThese effects both cap at 45 defense"); + sb.Append("\nEvery 10 defense gives you +0.5 HP/s life regen, 1% increased damage and 1% increased critical strike chance\nThese effects cap at 40 defense"); setBonusText += sb.ToString(); } @@ -41,6 +42,7 @@ namespace CalamityMod.Items.VanillaArmorChanges if (defense > SetBonusDefenseCap) defense = SetBonusDefenseCap; player.lifeRegen += (int)(defense * SetBonusLifeRegenPerDefense); + player.GetDamage() += defense * SetBonusDamagePerDefense; player.GetCritChance() += defense * SetBonusCritPerDefense; } } From bdbf7db1753573996928396c705d72855715b3b8 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Sat, 26 Aug 2023 19:56:05 -0400 Subject: [PATCH 046/138] Life regen tooltips on vanilla armor changes: +X HP/s life regen --- CalPlayer/CalamityPlayerLifeRegen.cs | 6 ++++-- Items/VanillaArmorChanges/IronArmorSetChange.cs | 2 +- Items/VanillaArmorChanges/LeadArmorSetChange.cs | 2 +- Items/VanillaArmorChanges/SilverArmorSetChange.cs | 2 +- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index e58a599036..8152d3c468 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -572,7 +572,8 @@ namespace CalamityMod.CalPlayer } - if (infectedJewel && !purity) + // Infected Jewel will not stack with Purity + else if (infectedJewel) { bool hasAnyDebuffs = false; Player.lifeRegen += 2; @@ -601,7 +602,8 @@ namespace CalamityMod.CalPlayer } } - if (crownJewel && !infectedJewel && !purity) + // Crown Jewel will not stack with Purity or Infected Jewel + else if (crownJewel) { bool hasAnyDebuffs = false; Player.lifeRegen += 1; diff --git a/Items/VanillaArmorChanges/IronArmorSetChange.cs b/Items/VanillaArmorChanges/IronArmorSetChange.cs index 3bf3a7a576..a5af707c1c 100644 --- a/Items/VanillaArmorChanges/IronArmorSetChange.cs +++ b/Items/VanillaArmorChanges/IronArmorSetChange.cs @@ -29,7 +29,7 @@ namespace CalamityMod.Items.VanillaArmorChanges public override void UpdateSetBonusText(ref string setBonusText) { StringBuilder sb = new StringBuilder(256); - sb.Append("\nIncreases damage reduction by 6%\n+2 life regen"); + sb.Append("\nIncreases damage reduction by 6%\n+1 HP/s life regen"); setBonusText += sb.ToString(); } diff --git a/Items/VanillaArmorChanges/LeadArmorSetChange.cs b/Items/VanillaArmorChanges/LeadArmorSetChange.cs index 5683e3af9d..0f35ce35f1 100644 --- a/Items/VanillaArmorChanges/LeadArmorSetChange.cs +++ b/Items/VanillaArmorChanges/LeadArmorSetChange.cs @@ -27,7 +27,7 @@ namespace CalamityMod.Items.VanillaArmorChanges public override void UpdateSetBonusText(ref string setBonusText) { StringBuilder sb = new StringBuilder(256); - sb.Append("\nIncreases damage reduction by 3%\n+1 life regen\nGrants immunity to knockback"); + sb.Append("\nIncreases damage reduction by 3%\n+0.5 HP/s life regen\nGrants immunity to knockback"); setBonusText += sb.ToString(); } diff --git a/Items/VanillaArmorChanges/SilverArmorSetChange.cs b/Items/VanillaArmorChanges/SilverArmorSetChange.cs index e7fa03d65f..c9e6246e0f 100644 --- a/Items/VanillaArmorChanges/SilverArmorSetChange.cs +++ b/Items/VanillaArmorChanges/SilverArmorSetChange.cs @@ -34,7 +34,7 @@ namespace CalamityMod.Items.VanillaArmorChanges public override void UpdateSetBonusText(ref string setBonusText) { StringBuilder sb = new StringBuilder(256); - sb.Append("\n+1 life regen\nTwo seconds after getting hit for 20 or more damage, you heal for 10\nGetting hit again resets the timer, delaying the heal"); + sb.Append("\n+0.5 HP/s life regen\nTwo seconds after getting hit for 20 or more damage, you heal for 10\nGetting hit again resets the timer, delaying the heal"); setBonusText += sb.ToString(); } From 70de2601e4bfc1f79f87fe99321d13ff57e93cea Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Sat, 26 Aug 2023 20:46:43 -0400 Subject: [PATCH 047/138] almost all life regen tooltips are +X HP/s life regen --- CalPlayer/CalamityPlayerOnHit.cs | 2 +- Items/Accessories/AngelicAlliance.cs | 2 +- Items/Accessories/TheCommunity.cs | 2 +- Items/Accessories/TheEvolution.cs | 2 +- Items/Armor/GemTech/GemTechHeadgear.cs | 7 +- .../Mods.CalamityMod.Items.Accessories.hjson | 68 ++++++++++--------- ...ods.CalamityMod.Items.Armor.Hardmode.hjson | 6 +- ...CalamityMod.Items.Armor.PostMoonLord.hjson | 16 ++--- ....CalamityMod.Items.Armor.PreHardmode.hjson | 10 +-- 9 files changed, 60 insertions(+), 55 deletions(-) diff --git a/CalPlayer/CalamityPlayerOnHit.cs b/CalPlayer/CalamityPlayerOnHit.cs index 0784b84d49..c47b1dddc8 100644 --- a/CalPlayer/CalamityPlayerOnHit.cs +++ b/CalPlayer/CalamityPlayerOnHit.cs @@ -707,7 +707,7 @@ namespace CalamityMod.CalPlayer } } - // Fearmonger set's colossal life regeneration + // Fearmonger set gains +10 frames (max 90) of regen when any minion lands any hit if (fearmongerSet) { fearmongerRegenFrames += 10; diff --git a/Items/Accessories/AngelicAlliance.cs b/Items/Accessories/AngelicAlliance.cs index a4817de3e4..aa7c22ee77 100644 --- a/Items/Accessories/AngelicAlliance.cs +++ b/Items/Accessories/AngelicAlliance.cs @@ -35,7 +35,7 @@ namespace CalamityMod.Items.Accessories player.GetDamage() += 0.08f; player.GetDamage() += 0.07f; //7% + 8% = 15% player.maxMinions += 2; - if (player.controlJump) + if (player.wingTime < player.wingTimeMax) player.lifeRegen += 4; } diff --git a/Items/Accessories/TheCommunity.cs b/Items/Accessories/TheCommunity.cs index ccd0f1b00a..6a80090419 100644 --- a/Items/Accessories/TheCommunity.cs +++ b/Items/Accessories/TheCommunity.cs @@ -116,7 +116,7 @@ namespace CalamityMod.Items.Accessories (int)(HealthMultiplier * power), (DRMultiplier * power * 100).ToString("N2"), (int)(DefenseMultiplier * power), - 1 + (int)(RegenMultiplier * power), + (0.5f * (1f + (int)(RegenMultiplier * power))).ToString("n1"), (SpeedMultiplier * power * 100).ToString("N1"), (FlightMultiplier * power * 100).ToString("N1"), (CalculatePower(true) * 100).ToString("N0")); diff --git a/Items/Accessories/TheEvolution.cs b/Items/Accessories/TheEvolution.cs index fc43a7c998..f7cae5cd24 100644 --- a/Items/Accessories/TheEvolution.cs +++ b/Items/Accessories/TheEvolution.cs @@ -12,7 +12,7 @@ namespace CalamityMod.Items.Accessories public new string LocalizationCategory => "Items.Accessories"; public override void SetStaticDefaults() { - Main.RegisterItemAnimation(Item.type, new DrawAnimationVertical(6, 10)); + Main.RegisterItemAnimation(Item.type, new DrawAnimationVertical(6, 10)); ItemID.Sets.AnimatesAsSoul[Type] = true; } diff --git a/Items/Armor/GemTech/GemTechHeadgear.cs b/Items/Armor/GemTech/GemTechHeadgear.cs index 1b212d446b..8a0b35a901 100644 --- a/Items/Armor/GemTech/GemTechHeadgear.cs +++ b/Items/Armor/GemTech/GemTechHeadgear.cs @@ -138,12 +138,15 @@ namespace CalamityMod.Items.Armor.GemTech tooltips.Insert(setBonusIndex, purpleGemTooltip); setBonusIndex++; - TooltipLine pinkGemTooltip = new TooltipLine(item.Mod, "CalamityMod:SetBonus7", CalamityUtils.GetTextFromModItem("PinkGemInfo").Format(BaseGemDefenseBoost, BaseGemLifeRegenBoost)); + string pinkLifeRegenString = (0.5f * BaseGemLifeRegenBoost).ToString("n1"); + TooltipLine pinkGemTooltip = new TooltipLine(item.Mod, "CalamityMod:SetBonus7", CalamityUtils.GetTextFromModItem("PinkGemInfo").Format(BaseGemDefenseBoost, pinkLifeRegenString)); pinkGemTooltip.OverrideColor = new Color(255, 115, 206); tooltips.Insert(setBonusIndex, pinkGemTooltip); setBonusIndex++; - TooltipLine liferegenTooltip = new TooltipLine(item.Mod, "CalamityMod:SetBonus8", CalamityUtils.GetTextFromModItem("GemBonusInfo").Format(AllGemsWeaponUseLifeRegenBoost, AllGemsLifeRegenBoostTime / 60, AllGemsMultiWeaponUseLifeRegenBoost, AllGemsMultiWeaponLifeRegenBoostTime / 60f)); + string baseLifeRegenString = (0.5f * AllGemsWeaponUseLifeRegenBoost).ToString("n1"); + string multiclassLifeRegenString = (0.5f * AllGemsMultiWeaponUseLifeRegenBoost).ToString("n1"); + TooltipLine liferegenTooltip = new TooltipLine(item.Mod, "CalamityMod:SetBonus8", CalamityUtils.GetTextFromModItem("GemBonusInfo").Format(baseLifeRegenString, AllGemsLifeRegenBoostTime / 60, multiclassLifeRegenString, AllGemsMultiWeaponLifeRegenBoostTime / 60f)); liferegenTooltip.OverrideColor = new Color(230, 230, 230); tooltips.Insert(setBonusIndex, liferegenTooltip); } diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 3d732505e0..59a1cef57e 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -74,7 +74,7 @@ Affliction: { DisplayName: Affliction Tooltip: ''' - Gives you and all other players on your team +1 life regen, + Gives you and all other players on your team +0.5 HP/s life regen, +10% max life, 7% damage reduction, 13 defense and 10% increased damage ''' } @@ -117,7 +117,7 @@ AmbrosialAmpoule: { ''' You emit light +50 max life - Your life regen is increased by 5 + +2.5 HP/s life regen Your natural life regen is greatly improved Halves how long you are afflicted with sickness debuffs When you are afflicted with a sickness debuff you quickly heal @@ -155,7 +155,7 @@ AngelicAlliance: { Call upon the force of heaven to empower your attacks and minions Courage, Enlightenment, Bliss. United in Judgement +2 max minions, 15% increased summon damage, and 8% increased damage to all other classes - Life regeneration is boosted while jumping + +2 HP/s life regen while airborne using wings Press [KEY] to grace yourself in divinity for 15 seconds While under the effects of Divine Bless, for every minion you have, an archangel shall be summoned to aid you in combat Each spawned angel will instantly heal you for two health @@ -221,7 +221,7 @@ AsgardianAegis: { ''' Grants immunity to knockback Immune to most debuffs - +40 max life and increased life regeneration + +40 max life and +0.5 HP/s life regen Grants a cosmic inferno dash which can slam through enemies without taking damage Can be used to ram enemies +20 defense while submerged in liquid @@ -247,8 +247,8 @@ Purity: { A once infected crystal, now perfectly purified You emit light +80 max life - Your life regen is increased by 5 - You gain an additional 5 life regen while afflicted with a debuff + +2.5 HP/s life regen + You gain an additional +2.5 HP/s life regen while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff Your natural life regen is massively improved Greatly reduces how long you are afflicted with debuffs @@ -325,8 +325,9 @@ BloomStone: { DisplayName: Bloom Stone Tooltip: ''' - You quickly regenerate life while on the ground - This effect works best during daytime + Grants between +1 HP/s and +3 HP/s life regen depending on time of day + Accelerates life regen based on time of day + Both of these effects are maximized from noon to sunset Flowers grow if you are standing on grass Random dye plants will grow while standing on grassless dirt One of the ancient relics @@ -361,8 +362,8 @@ InfectedJewel: { Tooltip: ''' A beautiful gem that has been corrupted by the astral infection - Life regen increased by 2 - You gain an additional 4 life regen while afflicted with a debuff + +1 HP/s life regen + You gain an additional +2 HP/s life regen while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff When afflicted with a debuff, you will gain 14 defense This defense will begin to fade away when you are no longer debuffed @@ -460,8 +461,8 @@ CrownJewel: { DisplayName: Crown Jewel Tooltip: ''' - Life regen increased by 1 - You gain an additional 3 life regen while afflicted with a debuff + +0.5 HP/s life regen + You gain an additional +1.5 HP/s life regen while afflicted with a debuff Your life regen is still increased even when afflicted with a damage over time debuff When afflicted with a debuff, you will gain 8 defense This defense will begin to fade away when you are no longer debuffed @@ -511,11 +512,11 @@ DarkSunRing: { Tooltip: ''' 12% increase to damage - +1 life regen and +2 max minions + +0.5 HP/s life regen and +2 max minions Increased minion knockback - During the day the player has +4 life regen - During the night the player has +20 defense - During an eclipse the player has +2 life regen and +10 defense + During the day, grants +2 HP/s life regen + During the night, grants +20 defense + During an eclipse, grants +1 HP/s life regen and +10 defense 'Contains the power of the dark sun' ''' } @@ -543,7 +544,8 @@ DeificAmulet: { Tooltip: ''' Causes stars to fall and grants increased immune time when damaged - Provides life regeneration and reduces the cooldown of healing potions + +0.5 HP/s life regen + Reduces the cooldown of healing potions ''' } @@ -796,7 +798,7 @@ FungalSymbiote: { Tooltip: ''' You grow mushrooms on the grass beneath you - Consuming mushrooms provides the Mushy buff, increasing defense by 6 and life regen by 2 + Consuming mushrooms provides the Mushy buff, increasing defense by 6 and granting 0.5 HP/s life regen All mushroom-based weapons deal 10% more damage and emit non-damaging mushrooms ''' } @@ -876,7 +878,7 @@ GrandGelatin: { 10% increased movement speed and jump speed Using a healing potion will spawn a cleansing aura Walking into the aura removes all debuffs and defense damage one time - The aura provides increased life regen for all players inside for 8 seconds + The aura grants +2.5 HP/s life regen for all players inside for 8 seconds ''' } @@ -1016,7 +1018,7 @@ LifeJelly: { Tooltip: ''' Using a healing potion will spawn a lingering aura - The aura provides increased life regen for all players inside for 5 seconds + The aura grants +2 HP/s life regen for all players inside for 5 seconds ''' } @@ -1059,7 +1061,7 @@ ManaPolarizer: { Tooltip: ''' Increases max mana by 50 and magic damage by 6% - Life regen lowered by 3 if mana is above 50% of its maximum + -1.5 HP/s life regen if mana is above 50% of its maximum Grants spectre healing, the amount healed scales with your mana The healing only works while holding a magic weapon The more mana you have, the more you heal @@ -1231,8 +1233,8 @@ PermafrostsConcoction: { Tooltip: ''' Increases maximum mana by 50 and reduces mana cost by 15% - Increases life regen as life decreases - Increases life regen when afflicted with any fire debuff + +0.5 HP/s life regen below half health, +1 HP/s when below 25% health and +2 HP/s when below 10% health + +3 HP/s life regen while afflicted with any fire debuff You will survive fatal damage and revive with 30% life on a 3 minute cooldown You are encased in an ice barrier for 3 seconds when revived ''' @@ -1325,7 +1327,7 @@ RadiantOoze: { Tooltip: ''' You produce light - Your life regen is increased by 3 + +1.5 HP/s life regen Your natural life regen is improved ''' } @@ -1344,7 +1346,7 @@ RampartofDeities: { Tooltip: ''' Causes stars to fall and gives increased immune time when damaged - Provides life regeneration and reduces the cooldown of healing potions + +0.5 HP/s life regen and reduces the cooldown of healing potions Absorbs 15% of damage done to players on your team This effect is only active above 25% life Grants immunity to knockback @@ -1366,7 +1368,7 @@ Regenator: { DisplayName: Regenator Tooltip: ''' - Greatly improves life regeneration + +6 HP/s life regen and massively accelerated natural life regen However, your health cannot exceed 50% of its maximum ''' } @@ -1436,7 +1438,7 @@ SandCloak: { Tooltip: ''' 5% increased movement speed - Press [KEY] to consume 10% of your maximum stealth to create a protective dust veil which provides +6 defense and +2 life regen + Press [KEY] to consume 10% of your maximum stealth to create a protective dust veil which provides +6 defense and +1 HP/s life regen This effect has a 30 second cooldown before it can be used again ''' } @@ -1465,7 +1467,7 @@ ShatteredCommunity: { ''' 'Ruined by unknowable hatred, it still contains (most of) the power of The Community...' Increases damage by 10% and critical strike chance by 5% - Increases max health by 10%, damage reduction by 5%, defense by 10 and life regen by 2 + Increases max health by 10%, damage reduction by 5%, defense by 10, and life regen by 1 HP/s Increases movement speed by 10% and flight time by 20% [RAGEDESC] Taking damage gives rage, this effect is not hindered by your defensive stats @@ -1503,7 +1505,7 @@ ShieldoftheOcean: { Tooltip: ''' Increased defense by 5 when submerged in liquid - Increases movement speed and life regen while wearing the Victide armor + 10% increased movement speed and +1 HP/s life regen while wearing Victide armor ''' } @@ -1721,7 +1723,7 @@ TheAbsorber: { Enemies take immense damage when they touch you and are afflicted with a debuff that reduces damage reduction significantly Using a healing potion will spawn a cleansing aura Walking into the aura removes all debuffs and defense damage one time - The aura provides greatly increased life regen, damage, and damage reduction for all players inside for 15 seconds + The aura grants +3 HP/s life regen, +10% damage, and +7% damage reduction for all players inside for 15 seconds 5% of the damage from enemy attacks is absorbed and converted into healing ''' } @@ -1776,7 +1778,7 @@ TheCommunity: { ''' Increases damage by {0}% and critical strike chance by {1}% Increases max health by {2}%, damage reduction by {3}%, and defense by {4} - Increases life regen by {5} while under damage over time effects + +{5} HP/s life regen while suffering from damage over time debuffs Increases movement speed by {6}% and flight time by {7}% Become more powerful as you defeat bosses ({8}% Power) ''' @@ -1789,7 +1791,7 @@ TheEvolution: { You reflect projectiles when they hit you Reflected projectiles deal no damage to you This reflect has a 90 second cooldown which is shared with all other dodges and reflects - If this effect triggers you get a health regeneration boost for 5 seconds + After reflecting something, grants +1 HP/s life regen and accelerated life regen for 5 seconds If the same enemy projectile type hits you again you will resist its damage by 15% ''' } @@ -1842,7 +1844,7 @@ TrinketofChi: { Tooltip: ''' Provides 10% damage reduction after not being hit for 15 seconds, this is removed when you are hit - Provides 2 life regen for you and everyone on your team + +1 HP/s life regen for you and everyone on your team ''' } diff --git a/Localization/en-US/Mods.CalamityMod.Items.Armor.Hardmode.hjson b/Localization/en-US/Mods.CalamityMod.Items.Armor.Hardmode.hjson index 5c1780a4f0..7066cfd499 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Armor.Hardmode.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Armor.Hardmode.hjson @@ -172,7 +172,7 @@ FathomSwarmerBreastplate: { ''' 6% increased damage reduction 6% increased summon damage - Boosted defense and regen increased while submerged in liquid + Increases defense by 10 and grants +2.5 HP/s life regen while submerged in liquid Reduces defense loss within the Abyss ''' } @@ -488,11 +488,11 @@ ReaverHeadTank: { ''' 15% increased damage reduction but 30% decreased damage +50 max life - Passively regenerates one health point every second + Restores 1 HP every second, this applies separately from life regen ''' SetBonus: ''' - +10 defense and +3 life regen + +10 defense and +1.5 HP/s life regen Enemies are more likely to target you Reduces the life regen lost from damage over time debuffs by 20% All attacks have a small chance to steal life and speed up the rate of life regen diff --git a/Localization/en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson b/Localization/en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson index 2fb71fc5aa..d5007eb970 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Armor.PostMoonLord.hjson @@ -82,7 +82,7 @@ BloodflareBodyArmor: { ''' CommonSetBonus: ''' - Greatly increases life regen + Greatly increased life regen, equivalent to Crimson armor Enemies below 50% life drop a heart when struck This effect has a 5 second cooldown ''' @@ -152,7 +152,7 @@ BloodflareHeadSummon: { 50% increased summon damage and +3 max minions Summons polterghast mines to circle you At 90% life and above you gain 10% increased summon damage - At 50% life and below you gain 20 defense and 2 life regen + At 50% life and below you gain 20 defense and +1 HP/s life regen ''' } @@ -163,7 +163,7 @@ DemonshadeBreastplate: { 25% increased melee speed, 15% increased damage and critical strike chance Enemies take ungodly damage when they touch you Increased max life and mana by 200 - Standing still lets you absorb the shadows and boost your life regen + Standing still absorbs shadows to grant exponentially accelerating life regen ''' } @@ -233,7 +233,7 @@ FearmongerGreathelm: { 20% increased summon damage and +2 max minions Minions no longer deal less damage while wielding non-summoner weapons Immunity to all forms of frost and flame - All minion attacks grant colossal life regeneration + Minion attacks grant +3.5 HP/s life regen and massively accelerate life regen 15% increased damage reduction during the Pumpkin and Frost Moons This extra damage reduction ignores the soft cap ''' @@ -288,11 +288,11 @@ GemTechHeadgear: { GreenGemInfo: "[i:Emerald] The green gem provides increased ranged stats and causes flechettes to fly swiftly towards targets when they are damaged by a ranged projectile" BlueGemInfo: "[i:Sapphire] The blue gem grants {0} extra maximum minions, increased summon damage, and negates the summon damage penalty while wielding non-summoner weapons" PurpleGemInfo: "[i:Amethyst] The violet gem grants {0} extra maximum mana, increased magic stats, and makes mana rapidly regenerate when holding a non-magic weapon" - PinkGemInfo: "[i:Diamond] The pink base gem grants {0} extra defense, extra damage reduction, increased movement speed, jump speed, and +{1} life regen" + PinkGemInfo: "[i:Diamond] The pink base gem grants {0} extra defense, extra damage reduction, increased movement speed, jump speed, and +{1} HP/s life regen" GemBonusInfo: ''' - When all gems exist simultaneously, hitting a target with any weapon grants you +{0} life regen for {1} seconds - This is increased to +{2} life regen if a weapon of another class is used during that {1} second period for {3} seconds + When all gems exist simultaneously, hitting a target with any weapon grants you +{0} HP/s life regen for {1} seconds + This is increased to +{2} HP/s life regen if a weapon of another class is used during that {1} second period for {3} seconds ''' } @@ -492,7 +492,7 @@ TarragonBreastplate: { Tooltip: ''' 10% increased damage and 5% increased critical strike chance - +2 life regen and +40 max life + +1 HP/s life regen and +40 max life ''' CommonSetBonus: ''' diff --git a/Localization/en-US/Mods.CalamityMod.Items.Armor.PreHardmode.hjson b/Localization/en-US/Mods.CalamityMod.Items.Armor.PreHardmode.hjson index c27cf40941..547aa65183 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Armor.PreHardmode.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Armor.PreHardmode.hjson @@ -238,7 +238,7 @@ VictideGreaves: { VictideHeadMagic: { DisplayName: Victide Hermit Helmet Tooltip: 5% increased magic damage - SetBonus: +3 life regen and 10% increased magic damage while submerged in liquid + SetBonus: +1.5 HP/s life regen and 10% increased magic damage while submerged in liquid } VictideHeadMelee: { @@ -247,14 +247,14 @@ VictideHeadMelee: { SetBonus: ''' Enemies are more likely to target you - +3 life regen and 10% increased melee damage while submerged in liquid + +1.5 HP/s life regen and 10% increased melee damage while submerged in liquid ''' } VictideHeadRanged: { DisplayName: Victide Coral Turban Tooltip: 5% increased ranged damage - SetBonus: +3 life regen and 10% increased ranged damage while submerged in liquid + SetBonus: +1.5 HP/s life regen and 10% increased ranged damage while submerged in liquid } VictideHeadRogue: { @@ -263,7 +263,7 @@ VictideHeadRogue: { SetBonus: ''' +60 maximum stealth - +3 life regen and 10% increased rogue damage while submerged in liquid + +1.5 HP/s life regen and 10% increased rogue damage while submerged in liquid ''' } @@ -274,7 +274,7 @@ VictideHeadSummon: { ''' +1 max minion Summons a sea snail to protect you - +3 life regen and 10% increased summon damage while submerged in liquid + +1.5 HP/s life regen and 10% increased summon damage while submerged in liquid ''' } From af79e8a58e0c9d749226c1e8817120846d457a73 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Sat, 26 Aug 2023 22:51:53 -0600 Subject: [PATCH 048/138] Eradicator buffs, vfx and some autolocalization shit that Tml did (it does not like empty spaces inside localization files) --- Items/Weapons/Rogue/Eradicator.cs | 4 +- .../Mods.CalamityMod.Items.Accessories.hjson | 2 +- ...ods.CalamityMod.Items.Weapons.Ranged.hjson | 2 +- ...Mods.CalamityMod.Items.Weapons.Rogue.hjson | 2 +- ...ods.CalamityMod.Items.Weapons.Summon.hjson | 2 +- Projectiles/Rogue/EradicatorProjectile.cs | 49 ++++++++++++++++--- 6 files changed, 47 insertions(+), 14 deletions(-) diff --git a/Items/Weapons/Rogue/Eradicator.cs b/Items/Weapons/Rogue/Eradicator.cs index 3a90a57e57..2283706320 100644 --- a/Items/Weapons/Rogue/Eradicator.cs +++ b/Items/Weapons/Rogue/Eradicator.cs @@ -17,7 +17,7 @@ namespace CalamityMod.Items.Weapons.Rogue { Item.width = 62; Item.height = 58; - Item.damage = 563; + Item.damage = 620; Item.noMelee = true; Item.noUseGraphic = true; Item.autoReuse = true; @@ -33,7 +33,7 @@ namespace CalamityMod.Items.Weapons.Rogue Item.DamageType = RogueDamageClass.Instance; } - public override float StealthDamageMultiplier => 0.5f; + public override float StealthDamageMultiplier => 0.75f; public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) { diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 4740a95ce8..ea423332a5 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -1991,4 +1991,4 @@ YharimsInsignia: { All melee attacks inflict Holy Flames Increased melee knockback ''' -} +} \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson index 7e1f610c17..adedb1f7e7 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson @@ -1285,4 +1285,4 @@ WulfrumBlunderbuss: { [c/83B87E:'The good thing about Wulfrum is that while it breaks fast, it can be reused even faster.] [c/83B87E:In fact, it is quite common for a robot to be turned into ammo right after it stops functioning.'] ''' -} +} \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson index 47e2296970..69377fae41 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson @@ -1387,4 +1387,4 @@ WulfrumKnife: { Stealth strikes make the knife fly further and hit several times at once Hold to magnetize all nearby fallen knives back to you ''' -} +} \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson index 24ea493bdf..c41f64d8b5 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Summon.hjson @@ -794,4 +794,4 @@ MirrorofKalandra: { StellarTorusStaff: { DisplayName: Stellar Torus Staff Tooltip: Summons a Torus Orbital that fries foes with a telescoping light beam -} +} \ No newline at end of file diff --git a/Projectiles/Rogue/EradicatorProjectile.cs b/Projectiles/Rogue/EradicatorProjectile.cs index 92ef2ca750..7fb2693bb0 100644 --- a/Projectiles/Rogue/EradicatorProjectile.cs +++ b/Projectiles/Rogue/EradicatorProjectile.cs @@ -1,5 +1,6 @@ using CalamityMod.Buffs.DamageOverTime; using CalamityMod.Items.Weapons.Rogue; +using CalamityMod.Particles; using CalamityMod.Projectiles.Melee; using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Graphics; @@ -14,10 +15,10 @@ namespace CalamityMod.Projectiles.Rogue { public new string LocalizationCategory => "Projectiles.Rogue"; public override string Texture => "CalamityMod/Items/Weapons/Rogue/Eradicator"; - private const float RotationIncrement = 0.09f; - private const int Lifetime = 350; - public const int StealthExtraLifetime = 240; // 1 extra update means this is double what you'd expect for 2 seconds - private const float ReboundTime = 40f; + private static float RotationIncrement = 0.15f; + private static int Lifetime = 350; + public static int StealthExtraLifetime = 240; // 1 extra update means this is double what you'd expect for 2 seconds + private static int ReboundTime = 60; private float randomLaserCharge = 0f; @@ -29,7 +30,7 @@ namespace CalamityMod.Projectiles.Rogue public override void SetDefaults() { - Projectile.width = Projectile.height = 58; + Projectile.width = Projectile.height = 62; Projectile.friendly = true; Projectile.tileCollide = false; Projectile.ignoreWater = true; @@ -116,7 +117,7 @@ namespace CalamityMod.Projectiles.Rogue { // Fire lasers at up to 2 nearby targets every 8 frames for 40% damage. // Stealth strike lasers have an intentionally lower ratio of 12%. - double laserDamageRatio = Projectile.Calamity().stealthStrike ? 0.12D : 0.4D; + double laserDamageRatio = Projectile.Calamity().stealthStrike ? 0.15D : 0.4D; float laserFrames = Projectile.MaxUpdates * 8f; CalamityUtils.MagnetSphereHitscan(Projectile, 300f, 6f, laserFrames, 2, ModContent.ProjectileType(), laserDamageRatio, true); } @@ -167,7 +168,39 @@ namespace CalamityMod.Projectiles.Rogue } } - public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) => target.AddBuff(ModContent.BuffType(), 180); + public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) + { + target.AddBuff(ModContent.BuffType(), 180); + + // Spawn sparks; taken from Despair stone then adapted to a projectile + Vector2 particleSpawnDisplacement; + Vector2 splatterDirection; + + particleSpawnDisplacement = new Vector2(2f * -Projectile.ai[2], 2f * -Projectile.ai[2]); + splatterDirection = new Vector2(Projectile.velocity.X, Projectile.velocity.Y); + + Vector2 SparkSpawnPosition = target.Center + particleSpawnDisplacement; + + if (Projectile.ai[1] % 4 == 0) + { + for (int i = 0; i < 2; i++) + { + int sparkLifetime = Main.rand.Next(14, 21); + float sparkScale = Main.rand.NextFloat(0.8f, 1f) + 1f * 0.05f; + Color sparkColor = Color.Lerp(Color.Fuchsia, Color.AliceBlue, Main.rand.NextFloat(0.5f)); + sparkColor = Color.Lerp(sparkColor, Color.Cyan, Main.rand.NextFloat()); + + if (Main.rand.NextBool(5)) + sparkScale *= 1.4f; + + Vector2 sparkVelocity = splatterDirection.RotatedByRandom(MathHelper.TwoPi); + sparkVelocity.Y -= 6f; + SparkParticle spark = new SparkParticle(SparkSpawnPosition, sparkVelocity, true, sparkLifetime, sparkScale, sparkColor); + GeneralParticleHandler.SpawnParticle(spark); + } + } + + } public override void OnHitPlayer(Player target, Player.HurtInfo info) => target.AddBuff(ModContent.BuffType(), 180); @@ -175,7 +208,7 @@ namespace CalamityMod.Projectiles.Rogue private void OnHit() { - // Non-stealth strikes do nothing special on hit. + // Non-stealth strikes do not stick on hit. if (!Projectile.Calamity().stealthStrike) return; From 40ba56f3809483c2db4554141d2593bf471bf5a8 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Sun, 27 Aug 2023 01:27:43 -0400 Subject: [PATCH 049/138] 1 - Collaborative review of life regen accessories between Xyk and Ozzatron. Massive changes 2 - Massive improvements to various aspects of life regen code 3 - Death Mode consistently increases debuff DoT by +50% for both vanilla and Calamity debuffs 4 - Fixed all Shiny Stone-like standing still regen effects and removed their hardcap (they are affected by life regen softcap anyway) 5 - Fixed the amount of Living Shards used by Terra Flameburster and Miracle Fruit 6 - Added a fire debuff list (NOT used in Fab's elemental weakness system yet) --- CalPlayer/CalamityPlayer.cs | 24 +- CalPlayer/CalamityPlayerLifeRegen.cs | 713 +++++++----------- CalPlayer/CalamityPlayerMiscEffects.cs | 102 +-- CalamityLists.cs | 31 +- Items/Accessories/AmbrosialAmpoule.cs | 27 +- Items/Accessories/HoneyDew.cs | 12 +- Items/Accessories/InfectedJewel.cs | 6 +- Items/Accessories/LivingDew.cs | 23 +- Items/Accessories/Purity.cs | 38 +- Items/Accessories/RadiantOoze.cs | 21 +- Items/PermanentBoosters/MiracleFruit.cs | 2 +- Items/Weapons/Ranged/TerraFlameburster.cs | 2 +- .../Mods.CalamityMod.Items.Accessories.hjson | 70 +- Utilities/PlayerUtils.cs | 8 +- 14 files changed, 444 insertions(+), 635 deletions(-) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index ea481e8755..4a14987880 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -470,18 +470,11 @@ namespace CalamityMod.CalPlayer public bool gShell = false; public bool tortShell = false; public bool absorber = false; - public bool hDew = false; - public int HoneyDewHealCooldown = 0; - public int HoneyDewHealSpeed = 12; - public int AmbrosialAmpouleHealCooldown = 0; - public int AmbrosialAmpouleHealSpeed = 9; - public int PurityHealCooldown = 0; - public int PurityHealSpeed = 5; - //Used to time until you get reduced healing - public int ReducedHealingCounter = 0; - public int CrownJewelBonusDefense = 0; - public int InfectedJewelBonusDefense = 0; - public int PurityBonusDefense = 0; + public bool alwaysHoneyRegen = false; + public bool honeyTurboRegen = false; + public bool honeyDewHalveDebuffs = false; + public bool livingDewHalveDebuffs = false; + public int jewelBonusDefense = 0; public bool aAmpoule = false; public bool rOoze = false; public bool JustWasDebuffed = false; @@ -532,6 +525,7 @@ namespace CalamityMod.CalPlayer public bool crownJewel = false; public bool infectedJewel = false; public bool purity = false; + public int PurityHealSlowdownFrames = 0; public bool harpyRing = false; public bool angelTreads = false; public bool harpyWingBoost = false; //harpy wings + harpy ring @@ -1585,7 +1579,10 @@ namespace CalamityMod.CalPlayer gShell = false; tortShell = false; absorber = false; - hDew = false; + alwaysHoneyRegen = false; + honeyTurboRegen = false; + honeyDewHalveDebuffs = false; + livingDewHalveDebuffs = false; aAmpoule = false; rOoze = false; fBarrier = false; @@ -2257,6 +2254,7 @@ namespace CalamityMod.CalPlayer vaporfied = false; banishingFire = false; wither = false; + PurityHealSlowdownFrames = 0; #endregion #region Rogue diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index 8152d3c468..35a1fda95e 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -1,20 +1,18 @@ -using CalamityMod.Items.Accessories; +using System; +using System.Linq; using CalamityMod.Buffs.Alcohol; using CalamityMod.Buffs.DamageOverTime; using CalamityMod.Cooldowns; -using CalamityMod.Events; +using CalamityMod.Items.Accessories; using CalamityMod.NPCs; using CalamityMod.Projectiles.Ranged; +using CalamityMod.Systems; using CalamityMod.World; using Microsoft.Xna.Framework; -using System; using Terraria; -using Terraria.ModLoader; using Terraria.DataStructures; -using CalamityMod.Systems; -using System.Linq; -using CalamityMod.Buffs.Pets; -using CalamityMod.Particles; +using Terraria.ID; +using Terraria.ModLoader; namespace CalamityMod.CalPlayer { @@ -26,141 +24,94 @@ namespace CalamityMod.CalPlayer if (Player.ownedProjectileCounts[ModContent.ProjectileType()] > 0) noLifeRegen = true; - bool death = CalamityWorld.death || BossRushEvent.BossRushActive; - double lifeRegenMult = death ? 1.5 : 1D; - if (reaverDefense) - lifeRegenMult *= 0.8; - int lifeRegenLost = 0; + // Universal +50% increase to DoT debuff damage in Death Mode + float deathNegativeRegenBonus = 0.5f; + float calamityDebuffMultiplier = 1f + (CalamityWorld.death ? deathNegativeRegenBonus : 0f); - // Initial Debuffs + // Cumulative amount of DoT debuff negative life regen from Calamity debuffs (or changes to vanilla debuffs) + float totalNegativeLifeRegen = 0; - // Get fucked, Nebula Armor - Player.nebulaLevelLife = 0; + #region Damage over Time Debuffs (Negative Life Regen) - // Vanilla - if (death) + // Vanilla debuffs (+50% damage over time in Death Mode is applied here) + if (CalamityWorld.death) { - if (Player.poisoned) - lifeRegenLost += 4; + int totalVanillaDoT = 0; - if (Player.onFire) - lifeRegenLost += 8; + if (Player.poisoned && !purity) + totalVanillaDoT += 4; + + if (Player.onFire && !purity) + totalVanillaDoT += 8; if (Player.tongued) - lifeRegenLost += 100; + totalVanillaDoT += 100; - if (Player.venom) - lifeRegenLost += 12; + if (Player.venom && !purity) + totalVanillaDoT += 12; - if (Player.onFrostBurn) - lifeRegenLost += 12; + if (Player.onFrostBurn && !purity) + totalVanillaDoT += 12; - if (Player.onFire2) - lifeRegenLost += 12; + if (Player.onFire2 && !purity) + totalVanillaDoT += 12; if (Player.burned) - lifeRegenLost += 60; + totalVanillaDoT += 60; if (Player.suffocating) - lifeRegenLost += 40; + totalVanillaDoT += 40; - if (Player.electrified) + if (Player.electrified && !purity) { - lifeRegenLost += 8; + totalVanillaDoT += 8; if (Player.controlLeft || Player.controlRight) - lifeRegenLost += 32; + totalVanillaDoT += 32; } + + // Tally up total current vanilla DoT so it can be added as extra DoT from Death Mode + totalNegativeLifeRegen += totalVanillaDoT * deathNegativeRegenBonus; } - // Calamity - if (shadowflame) + // + // Calamity debuffs (Vanilla Shadowflame is added here) + // + void ApplyDoTDebuff(bool hasDebuff, int negativeLifeRegenToApply, bool immuneCondition = false) { + if (!hasDebuff || immuneCondition) + return; + if (Player.lifeRegen > 0) Player.lifeRegen = 0; Player.lifeRegenTime = 0; - lifeRegenLost += 30; + totalNegativeLifeRegen += negativeLifeRegenToApply * calamityDebuffMultiplier; } - if (wDeath) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; + // Whispering Death sets positive regen to zero but doesn't actually deal any damage + ApplyDoTDebuff(wDeath, 0); - Player.lifeRegenTime = 0; - } - - if (weakBrimstoneFlames) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 7; - } - - if (bFlames) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 16; - } - - if (nightwither) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 16; - } - - if (vaporfied) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 8; - } - - if (cragsLava) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 30; - } - - if (gsInferno) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += profanedCrystalBuffs ? 35 : 30; - } - - if (astralInfection) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 20; - } - - if (irradiated) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 4; - } + ApplyDoTDebuff(irradiated, 4, purity); + int sulphurDoT = 6 - (sulfurSet ? 2 : 0) - (sulphurskin ? 2 : 0); + ApplyDoTDebuff(sulphurPoison, sulphurDoT, purity); + ApplyDoTDebuff(rTide, 6, purity); + ApplyDoTDebuff(weakBrimstoneFlames, 7); + ApplyDoTDebuff(bBlood, 8, purity); + ApplyDoTDebuff(vaporfied, 8, purity); + ApplyDoTDebuff(bFlames, 16, purity); + ApplyDoTDebuff(nightwither, 16, purity); + ApplyDoTDebuff(hFlames, 16, purity); + ApplyDoTDebuff(vHex, 16); + ApplyDoTDebuff(cDepth, 18, purity); + ApplyDoTDebuff(astralInfection, 20, infectedJewel || purity); + ApplyDoTDebuff(pFlames, 20, purity); + ApplyDoTDebuff(cragsLava, 30); + ApplyDoTDebuff(shadowflame, 30, purity); + // Profaned Soul Crystal turns you into Providence, a God, and you take more damage from God Slayer Inferno + ApplyDoTDebuff(gsInferno, profanedCrystalBuffs ? 35 : 30); + ApplyDoTDebuff(dragonFire, 36); + ApplyDoTDebuff(miracleBlight, 40); + ApplyDoTDebuff(banishingFire, 60); // Slowly increase the sulphuric water poisoning effect. Once it's high enough, the player starts taking damage over time. bool nearSafeZone = false; @@ -201,116 +152,20 @@ namespace CalamityMod.CalPlayer } else SulphWaterPoisoningLevel = MathHelper.Clamp(SulphWaterPoisoningLevel - 1f / SulphSeaWaterRecoveryTime, 0f, 1f); + #endregion - if (sulphurPoison) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 6; - if (sulfurSet) - { - lifeRegenLost -= 2; - } - if (sulphurskin) - { - lifeRegenLost -= 2; - } - } - - if (hFlames) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 16; - } - - if (banishingFire) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 60; - } - - if (pFlames) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 20; - } - - if (bBlood) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 8; - } - - if (vHex) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 16; - } - - if (dragonFire) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 36; - } - - if (miracleBlight) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 40; - } - - if (cDepth) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 18; - } - - if (rTide) - { - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - - Player.lifeRegenTime = 0; - lifeRegenLost += 6; - } - + #region Alcohol if (vodka) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; } if (redWine) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; if (baguette) - lifeRegenLost += 3; + totalNegativeLifeRegen += 3; } if (grapeBeer) { @@ -319,7 +174,7 @@ namespace CalamityMod.CalPlayer if (moonshine) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; } if (rum) { @@ -332,7 +187,7 @@ namespace CalamityMod.CalPlayer if (fireball) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; } if (whiskey) { @@ -341,27 +196,27 @@ namespace CalamityMod.CalPlayer if (everclear) { alcoholPoisonLevel += 2; - lifeRegenLost += 10; + totalNegativeLifeRegen += 10; } if (bloodyMary) { alcoholPoisonLevel++; - lifeRegenLost += 4; + totalNegativeLifeRegen += 4; } if (tequila) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; } if (tequilaSunrise) { alcoholPoisonLevel++; - lifeRegenLost += 2; + totalNegativeLifeRegen += 2; } if (screwdriver) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; } if (caribbeanRum) { @@ -374,27 +229,27 @@ namespace CalamityMod.CalPlayer if (margarita) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; } if (starBeamRye) { alcoholPoisonLevel++; - lifeRegenLost += 2; + totalNegativeLifeRegen += 2; } if (moscowMule) { alcoholPoisonLevel++; - lifeRegenLost += 4; + totalNegativeLifeRegen += 4; } if (whiteWine) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; } if (evergreenGin) { alcoholPoisonLevel++; - lifeRegenLost += 1; + totalNegativeLifeRegen += 1; } if (Player.tipsy) { @@ -412,14 +267,16 @@ namespace CalamityMod.CalPlayer Player.lifeRegen = 0; Player.lifeRegenTime = 0; - lifeRegenLost += 3 * alcoholPoisonLevel; + totalNegativeLifeRegen += 3 * alcoholPoisonLevel; } + #endregion if (manaOverloader) { if (Player.statMana > (int)(Player.statManaMax2 * 0.5)) - lifeRegenLost += 3; + totalNegativeLifeRegen += 3; } + if (brimflameFrenzy) { Player.manaRegen = 0; @@ -427,7 +284,7 @@ namespace CalamityMod.CalPlayer Player.manaRegenDelay = (int) Player.maxRegenDelay; if (Player.lifeRegen > 0) Player.lifeRegen = 0; - lifeRegenLost += 42; //the meaning of death + totalNegativeLifeRegen += 42; //the meaning of death } if (witheredDebuff) @@ -439,7 +296,7 @@ namespace CalamityMod.CalPlayer } else { - lifeRegenLost += (int)(5D * Math.Pow(1.5D, witheredWeaponHoldTime / 87D)); + totalNegativeLifeRegen += (int)(5D * Math.Pow(1.5D, witheredWeaponHoldTime / 87D)); if (Player.lifeRegen > 0) Player.lifeRegen = 0; } @@ -452,14 +309,62 @@ namespace CalamityMod.CalPlayer int debuffIndex = Player.FindBuffIndex(ModContent.BuffType()); float debuffIntensity = debuffIndex == -1 ? 0f : Player.buffTime[debuffIndex] / (float)Player.manaSickTimeMax; - lifeRegenLost += (int)(Math.Sqrt(debuffIntensity) * Math.Pow(6D, debuffIntensity + 1f)); + totalNegativeLifeRegen += (int)(Math.Sqrt(debuffIntensity) * Math.Pow(6D, debuffIntensity + 1f)); if (Player.lifeRegen > 0) Player.lifeRegen = 0; } - Player.lifeRegen -= (int)(lifeRegenLost * lifeRegenMult); + // + // ACTUALLY APPLY NEGATIVE LIFE REGEN + // - // Buffs + // At the last second, Reaver defense helm reduces DoT debuffs by 20% + if (reaverDefense) + totalNegativeLifeRegen = (int)(0.8f * totalNegativeLifeRegen); + + Player.lifeRegen -= (int)totalNegativeLifeRegen; + + #region Life Regen That Works Even During DoT Debuffs + + // Honey Dew (and upgrades) + if (alwaysHoneyRegen) + { + // Exact copy of vanilla Honey behavior, but does not stack with actually standing in Honey + if (!Player.honey) + { + Player.lifeRegen += 2; + Player.lifeRegenTime += 1; + + // Grants +2 life regen if negative life regen would otherwise occur. + // However, this can't bring regen into the positives. + if (Player.lifeRegen < 0) + { + Player.lifeRegen += 2; + if (Player.lifeRegen > 0) + Player.lifeRegen = 0; + } + } + } + + if (honeyDewHalveDebuffs) + { + // Tick down all sickness debuffs; this makes them expire 2x faster + // Upgrades increase the sets of debuffs which expire faster + for (int l = 0; l < Player.MaxBuffs; ++l) + { + int buffID = Player.buffType[l]; + if (Player.buffTime[l] <= 2) + continue; + bool shouldHalveDuration = CalamityLists.sicknessDebuffList.Contains(buffID); + if (livingDewHalveDebuffs) + shouldHalveDuration |= CalamityLists.fireDebuffList.Contains(buffID); + if (purity) + shouldHalveDuration |= CalamityLists.debuffList.Contains(buffID); + + if (shouldHalveDuration) + --Player.buffTime[l]; + } + } if (divineBless) { @@ -498,144 +403,113 @@ namespace CalamityMod.CalPlayer } // Permafrost's Concoction increases life regen while afflicted with a fire debuff - if (permafrostsConcoction) + if (permafrostsConcoction && Player.buffType.Any(CalamityLists.fireDebuffList.Contains)) { - if (Player.onFire || Player.onFire2 || Player.onFire3 || Player.burned || shadowflame || weakBrimstoneFlames || bFlames || cragsLava || gsInferno || hFlames || banishingFire || dragonFire) - { - if (Player.lifeRegenTime < 1800) - Player.lifeRegenTime = 1800; + if (Player.lifeRegenTime < 1800) + Player.lifeRegenTime = 1800; - Player.lifeRegen += 6; - } + Player.lifeRegen += 6; } if (purity) { - Player.lifeRegen += 5; - Player.lifeRegenTime += 6; - Player.statDefense += PurityBonusDefense; - //heal every 5 frames - if (PurityHealCooldown == PurityHealSpeed) - PurityHealCooldown = 0; - Player.statLifeMax2 += 80; - bool hasAnyDebuffs = false; - for (int l = 0; l < Player.MaxBuffs; l++) + int currentDebuffs = Player.buffType.Count(CalamityLists.debuffList.Contains); + if (currentDebuffs > 0) { - int hasBuff = Player.buffType[l]; - if (CalamityLists.debuffList.Contains(hasBuff)) - { - if (Player.buffTime[l] > 3) - { - hasAnyDebuffs = true; - //JustWasDebuffed = false; - Player.buffTime[l] -= 2; + // Healing rate is normally 5 HP/s (+1 every 12 frames) + // However, that 12 frames can and will slowly increase if you try to abuse this accessory + int healFrameCadence = 12; - if (Player.lifeRegenTime < 1800) - Player.lifeRegenTime = 1800; - //add extra regen when effected by a debuff - Player.lifeRegen += 5; - PurityBonusDefense = 18; - if (ReducedHealingCounter < 120) - ReducedHealingCounter++; + // Healing slows down after 5 seconds (300 frames) debuffed. For every 15 frames thereafter the cadence slows + // There is no upper limit to how slow it can get and it can take a very long time to reset to normal + int punishmentFrames = PurityHealSlowdownFrames - 300; + healFrameCadence += (punishmentFrames < 0) ? 0 : punishmentFrames / 15; - //If it's been over 2 seconds with a debuff, Every 15 frames increase the ammount of frames between healing 1, up to a max of 4x the original frames - if (ReducedHealingCounter == 120 && PurityHealSpeed < 20) - if (Player.miscCounter % 15 == 0) - { - PurityHealSpeed++; - } + if (Player.miscCounter % healFrameCadence == healFrameCadence - 1) + Player.Heal(1); - if (PurityHealCooldown == 0) - { - PurityHealCooldown++; - Player.Heal(1); - } - else - PurityHealCooldown++; - } - } + if (Player.lifeRegenTime < 1800) + Player.lifeRegenTime = 1800; + + jewelBonusDefense = 40 + (currentDebuffs - 1) * 10; + + // Count up total frames spent healing for slowdown. + ++PurityHealSlowdownFrames; } - - if (!hasAnyDebuffs) + else if (Player.miscCounter % 20 == 0 && jewelBonusDefense > 0) + --jewelBonusDefense; + + // If the player is clear of all debuffs then gradually reduce the slowdown frames + if (currentDebuffs <= 0) { - //recover any heal penalty youve gained as long as youre not currently debuffed - if (PurityHealSpeed > 5) - if (Player.miscCounter % 15 == 0) - PurityHealSpeed--; - //If you're not debuffed and you are back to full healing speed, give the 3 second countdown back - if (PurityHealSpeed == 5) - ReducedHealingCounter = 0; - //Bonus defense goes down by 1 every second after - if (Player.miscCounter % 60 == 0 && PurityBonusDefense > 0) - PurityBonusDefense--; + --PurityHealSlowdownFrames; + if (PurityHealSlowdownFrames < 0) + PurityHealSlowdownFrames = 0; } - + + Player.statDefense += jewelBonusDefense; } - // Infected Jewel will not stack with Purity + // Infected Jewel does not stack with Purity else if (infectedJewel) { - bool hasAnyDebuffs = false; Player.lifeRegen += 2; - Player.statDefense += InfectedJewelBonusDefense; - if (!hasAnyDebuffs) + + // If the player has any debuffs, give the extra life regen and defense + // More defense is given for each additional debuff + int currentDebuffs = Player.buffType.Count(CalamityLists.debuffList.Contains); + if (currentDebuffs > 0) { - //Bonus defense goes down by 1 every second after - if (Player.miscCounter % 60 == 0 && InfectedJewelBonusDefense > 0) - InfectedJewelBonusDefense--; - } - for (int l = 0; l < Player.MaxBuffs; l++) - { - int hasBuff = Player.buffType[l]; - if (CalamityLists.debuffList.Contains(hasBuff)) - { - if (Player.buffTime[l] > 2) - { - hasAnyDebuffs = true; - if (Player.lifeRegenTime < 1800) - Player.lifeRegenTime = 1800; - //add extra regen when effected by a debuff - Player.lifeRegen += 4; - InfectedJewelBonusDefense = 14; - } - } + Player.lifeRegen += 4; + if (Player.lifeRegenTime < 1800) + Player.lifeRegenTime = 1800; + + jewelBonusDefense = 16 + (currentDebuffs - 1) * 4; } + + // Otherwise tick down the defense, one point per second + else if (Player.miscCounter % 60 == 0 && jewelBonusDefense > 0) + --jewelBonusDefense; + + Player.statDefense += jewelBonusDefense; } - // Crown Jewel will not stack with Purity or Infected Jewel + // Crown Jewel does not stack with Purity or Infected Jewel else if (crownJewel) { - bool hasAnyDebuffs = false; - Player.lifeRegen += 1; - Player.statDefense += CrownJewelBonusDefense; - if (!hasAnyDebuffs) + Player.lifeRegen += 2; + + // If any debuff is detected, provide even more life regen and massively accelerate it + if (Player.buffType.Any(CalamityLists.debuffList.Contains)) { - //Bonus defense goes down by 1 every second after - if (Player.miscCounter % 60 == 0 && CrownJewelBonusDefense > 0) - CrownJewelBonusDefense--; - } - for (int l = 0; l < Player.MaxBuffs; l++) - { - int hasBuff = Player.buffType[l]; - if (CalamityLists.debuffList.Contains(hasBuff)) - { - if (Player.buffTime[l] > 2) - { - hasAnyDebuffs = true; - if (Player.lifeRegenTime < 1800) - Player.lifeRegenTime = 1800; - //add extra regen when effected by a debuff - Player.lifeRegen += 3; - CrownJewelBonusDefense = 8; - } - } + Player.lifeRegen += 3; + if (Player.lifeRegenTime < 1800) + Player.lifeRegenTime = 1800; } } + #endregion - // Last Debuffs + // During Silva revive or God Slayer dash, all negative life regen is canceled + if ((silvaCountdown > 0 && hasSilvaEffect && silvaSet) || (DashID == GodSlayerDash.ID && Player.dashDelay < 0)) + { + if (Player.lifeRegen < 0) + Player.lifeRegen = 0; + } + + #region Things That Disable Even That Life Regen + // + // Yes, really, there's a list of conditions under which life regen doesn't work + // even if it's life regen that normally works during a damage over time debuff. + // + // 1. No life regen bool (Blood Boiler usage or wearing Omega Blue armor) + // 2. Being too far from Providence cocoon ("Holy Inferno") + // 3. Air drowning in the Abyss + // if (noLifeRegen) { + Player.nebulaLevelLife = 0; + if (Player.lifeRegen > 0) Player.lifeRegen = 0; @@ -655,7 +529,7 @@ namespace CalamityMod.CalPlayer Player.lifeRegen = 0; Player.lifeRegenTime = 0; - Player.lifeRegen -= (int)(hInfernoBoost * lifeRegenMult); + Player.lifeRegen -= (int)(hInfernoBoost * calamityDebuffMultiplier); if (Player.lifeRegen < -200) Player.lifeRegen = -200; @@ -675,22 +549,18 @@ namespace CalamityMod.CalPlayer Player.lifeRegen = 0; Player.lifeRegenTime = 0; - Player.lifeRegen -= (int)(160D * lifeRegenMult); + Player.lifeRegen -= (int)(160D * calamityDebuffMultiplier); } } } + // TODO -- Why is this here? if (weakPetrification) { if (Player.mount.Active) Player.mount.Dismount(Player); } - - if ((silvaCountdown > 0 && hasSilvaEffect && silvaSet) || (DashID == GodSlayerDash.ID && Player.dashDelay < 0)) - { - if (Player.lifeRegen < 0) - Player.lifeRegen = 0; - } + #endregion } #endregion @@ -743,17 +613,6 @@ namespace CalamityMod.CalPlayer if (trinketOfChi || chiRegen) Player.lifeRegen += 2; - if (rOoze && !aAmpoule && !purity) - { - Player.lifeRegen += 3; - Player.lifeRegenTime += 2; - } - - if (aAmpoule && !purity) - { - Player.lifeRegen += 5; - Player.lifeRegenTime += 4; - } if (ursaSergeant) { @@ -888,101 +747,55 @@ namespace CalamityMod.CalPlayer Player.lifeRegenTime += (int)MathHelper.Lerp(1f, 3f, regenBenefitFactor); } - // Standing still healing bonuses (all exclusive with vanilla Shiny Stone) - if (!Player.shinyStone) - { - int lifeRegenTimeMaxBoost = areThereAnyDamnBosses ? 450 : 1800; - int lifeRegenMaxBoost = areThereAnyDamnBosses ? 1 : 4; - float lifeRegenLifeRegenTimeMaxBoost = areThereAnyDamnBosses ? 8f : 30f; + #region Standing Still Life Regen + // Standing still healing bonuses (all are exclusive with vanilla Shiny Stone, but all function similarly) + if (!Player.shinyStone && Player.StandingStill() && Player.itemAnimation == 0) + { + bool honeyDewWorking = honeyTurboRegen && Player.honey; + bool anyStandingStillLifeRegen = shadeRegen || cFreeze || honeyDewWorking || photosynthesis; + bool onlyPhotosynthesisAtNight = !shadeRegen && !cFreeze && !honeyDewWorking && photosynthesis && !Main.dayTime; - if (Player.StandingStill() && Player.itemAnimation == 0) + // Divides all negative life regen by two before applying any other effects. + if (anyStandingStillLifeRegen && Player.lifeRegen < 0) + Player.lifeRegen /= 2; + + // Spawn dust of some flavor while actually regenerating + if (Player.lifeRegen > 0 && Player.statLife < actualMaxLife) { - bool boostedRegen = false; - bool noSunlight = false; - if (shadeRegen) + int dustType = shadeRegen ? 173 : cFreeze ? 67 : honeyDewWorking ? DustID.Honey2 : photosynthesis ? 244 : -1; + bool dustSpawnRolled = Main.rand.Next(30000) < Player.lifeRegenTime || Main.rand.NextBool(30); + if (dustType != -1 && dustSpawnRolled) { - boostedRegen = true; - if (Player.lifeRegen > 0 && Player.statLife < actualMaxLife) - { - if (Main.rand.Next(30000) < Player.lifeRegenTime || Main.rand.NextBool(30)) - { - int regen = Dust.NewDust(Player.position, Player.width, Player.height, 173, 0f, 0f, 200, default, 1f); - Main.dust[regen].noGravity = true; - Main.dust[regen].fadeIn = 1.3f; - Vector2 velocity = CalamityUtils.RandomVelocity(100f, 50f, 100f, 0.04f); - Main.dust[regen].velocity = velocity; - velocity.Normalize(); - velocity *= 34f; - Main.dust[regen].position = Player.Center - velocity; - } - } - } - else if (cFreeze) - { - boostedRegen = true; - if (Player.lifeRegen > 0 && Player.statLife < actualMaxLife) - { - if (Main.rand.Next(30000) < Player.lifeRegenTime || Main.rand.NextBool(30)) - { - int regen = Dust.NewDust(Player.position, Player.width, Player.height, 67, 0f, 0f, 200, new Color(150, Main.DiscoG, 255), 0.75f); - Main.dust[regen].noGravity = true; - Main.dust[regen].fadeIn = 1.3f; - Vector2 velocity = CalamityUtils.RandomVelocity(100f, 50f, 100f, 0.04f); - Main.dust[regen].velocity = velocity; - velocity.Normalize(); - velocity *= 34f; - Main.dust[regen].position = Player.Center - velocity; - } - } - } - else if (photosynthesis) - { - boostedRegen = true; - if (!Main.dayTime) - noSunlight = true; - if (Player.lifeRegen > 0 && Player.statLife < actualMaxLife) - { - if (Main.rand.Next(30000) < Player.lifeRegenTime || Main.rand.NextBool(2)) - { - int regen = Dust.NewDust(Player.position, Player.width, Player.height, 244, 0f, 0f, 200, default, 1f); - Main.dust[regen].noGravity = true; - Main.dust[regen].fadeIn = 1.3f; - Vector2 velocity = CalamityUtils.RandomVelocity(100f, 50f, 100f, 0.04f); - Main.dust[regen].velocity = velocity; - velocity.Normalize(); - velocity *= 34f; - Main.dust[regen].position = Player.Center - velocity; - } - } - } - if (boostedRegen) - { - int lifeRegenTimeMaxBoost2 = !noSunlight ? lifeRegenTimeMaxBoost : (lifeRegenTimeMaxBoost / 5); - int lifeRegenMaxBoost2 = !noSunlight ? lifeRegenMaxBoost : (lifeRegenMaxBoost / 5); - float lifeRegenLifeRegenTimeMaxBoost2 = !noSunlight ? lifeRegenLifeRegenTimeMaxBoost : (lifeRegenLifeRegenTimeMaxBoost / 5); - - if (Player.lifeRegenTime > 90 && Player.lifeRegenTime < lifeRegenTimeMaxBoost2) - Player.lifeRegenTime = lifeRegenTimeMaxBoost2; - - Player.lifeRegenTime += lifeRegenMaxBoost2; - Player.lifeRegen += lifeRegenMaxBoost2; - - float num3 = Player.lifeRegenTime * 2.5f; // lifeRegenTime max is 3600 - num3 /= 300f; - if (num3 > 0f) - { - if (num3 > lifeRegenLifeRegenTimeMaxBoost2) - num3 = lifeRegenLifeRegenTimeMaxBoost2; - - Player.lifeRegen += (int)num3; - } - if (Player.lifeRegen > 0 && Player.statLife < actualMaxLife) - { - Player.lifeRegenCount++; - } + int regen = Dust.NewDust(Player.position, Player.width, Player.height, dustType, 0f, 0f, 200, default, 1f); + Main.dust[regen].noGravity = true; + Main.dust[regen].fadeIn = 1.3f; + Vector2 velocity = CalamityUtils.RandomVelocity(100f, 50f, 100f, 0.04f); + Main.dust[regen].velocity = velocity; + velocity.Normalize(); + velocity *= 34f; + Main.dust[regen].position = Player.Center - velocity; } } + + // Actually apply "standing still" regeneration (the stats are granted even at full health) + float regenTimeNeededForTurboRegen = shadeRegen ? 40f : cFreeze ? 60f : honeyDewWorking ? 90f : photosynthesis ? 90f : -1f; + + // 4 = vanilla Shiny Stone + int turboRegenPower = shadeRegen || cFreeze ? 4 : honeyDewWorking ? 3 : photosynthesis ? 1 : -1; + + if (turboRegenPower > 0) + { + // After a brief delay determined by your form of standing still regen, min-cap life regen time at 1800 / 3600. + // Photosynthesis Potion does not do this at night. + if (Player.lifeRegenTime > regenTimeNeededForTurboRegen && Player.lifeRegenTime < 1800f && !onlyPhotosynthesisAtNight) + Player.lifeRegenTime = 1800f; + + Player.lifeRegen += turboRegenPower; + Player.lifeRegenTime += turboRegenPower; + } + } + #endregion // The Camper counteracts the regen loss while moving horizontally if (camper && (Player.velocity.X != 0 && Player.grappling[0] <= 0)) diff --git a/CalPlayer/CalamityPlayerMiscEffects.cs b/CalPlayer/CalamityPlayerMiscEffects.cs index 60d6b4fa58..47dbbaa803 100644 --- a/CalPlayer/CalamityPlayerMiscEffects.cs +++ b/CalPlayer/CalamityPlayerMiscEffects.cs @@ -1,8 +1,6 @@ using System; using System.Collections.Generic; using System.Linq; -using System.Security.Cryptography.X509Certificates; -using System.Text; using CalamityMod.Balancing; using CalamityMod.Buffs.DamageOverTime; using CalamityMod.Buffs.Potions; @@ -1578,93 +1576,7 @@ namespace CalamityMod.CalPlayer Player.GetDamage() += 0.1f; } - if (hDew && !aAmpoule && !purity) - { - //heal ever 12 frames - if (HoneyDewHealCooldown == HoneyDewHealSpeed) - HoneyDewHealCooldown = 0; - Player.statLifeMax2 += 30; - for (int l = 0; l < Player.MaxBuffs; l++) - { - int hasBuff = Player.buffType[l]; - if (Player.buffTime[l] > 2 && CalamityLists.sicknessDebuffList.Contains(hasBuff)) - { - Player.buffTime[l]--; - if (HoneyDewHealCooldown == 0) - { - HoneyDewHealCooldown++; - Player.Heal(1); - } - else - HoneyDewHealCooldown++; - } - } - //Honey Like life regen, does not work if you have honey buff - if (!Player.honey && Player.lifeRegen < 0) - { - Player.lifeRegen += 2; - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - } - if (!Player.honey) - { - Player.lifeRegenTime += 1; - Player.lifeRegen += 2; - } - } - - // Radiant Ooze light-granting float[] light = new float[3]; - if (rOoze && !aAmpoule && !purity) - { - light[0] += 1f; - light[1] += 1f; - light[2] += 0.6f; - } - - // Ambrosial Ampoule bonus and other light-granting bonuses - if (aAmpoule && !purity) - { - light[0] += 1.3f; - light[1] += 1.3f; - light[2] += 0.8f; - } - if (purity) - { - light[0] += 1.2f; - light[1] += 1.7f; - light[2] += 2.7f; - } - if (aAmpoule && !purity) - { - //heal every 9 frames - if (AmbrosialAmpouleHealCooldown == AmbrosialAmpouleHealSpeed) - AmbrosialAmpouleHealCooldown = 0; - Player.statLifeMax2 += 50; - for (int l = 0; l < Player.MaxBuffs; l++) - { - int hasBuff = Player.buffType[l]; - if (Player.buffTime[l] > 2 && CalamityLists.sicknessDebuffList.Contains(hasBuff)) - { - Player.buffTime[l]--; - if (AmbrosialAmpouleHealCooldown == 0) - { - AmbrosialAmpouleHealCooldown++; - Player.Heal(1); - } - else - AmbrosialAmpouleHealCooldown++; - } - } - if (Player.lifeRegen < 0) - { - Player.lifeRegen += 2; - if (Player.lifeRegen > 0) - Player.lifeRegen = 0; - } - - - } if (cFreeze) { light[0] += 0.3f; @@ -2769,25 +2681,25 @@ namespace CalamityMod.CalPlayer Player.lifeMagnet = true; } - if (wDeath) + if (wDeath && !purity) Player.GetDamage() -= 0.25f; - if (astralInfection) + if (astralInfection && !(infectedJewel || purity)) Player.GetDamage() -= 0.15f; - if (pFlames) + if (pFlames && !purity) { Player.blind = true; Player.GetDamage() -= 0.15f; } - if (aCrunch && !laudanum) + if (aCrunch && !laudanum && !purity) { Player.statDefense -= ArmorCrunch.DefenseReduction; Player.endurance *= ArmorCrunch.MultiplicativeDamageReductionPlayer; } - if (wither) + if (wither && !purity) { Player.statDefense -= WitherDebuff.DefenseReduction; } @@ -2800,10 +2712,10 @@ namespace CalamityMod.CalPlayer Player.velocity.Y = 15f; } - if (eutrophication) + if (eutrophication && !purity) Player.velocity = Vector2.Zero; - if (vaporfied || galvanicCorrosion) + if ((vaporfied && !purity) || galvanicCorrosion) Player.velocity *= 0.98f; if (molluskSet) diff --git a/CalamityLists.cs b/CalamityLists.cs index d7901c66f4..988d6e8de1 100644 --- a/CalamityLists.cs +++ b/CalamityLists.cs @@ -1,20 +1,18 @@ -using CalamityMod.Buffs; +using System.Collections.Generic; +using CalamityMod.Buffs; using CalamityMod.Buffs.Alcohol; using CalamityMod.Buffs.Cooldowns; using CalamityMod.Buffs.DamageOverTime; using CalamityMod.Buffs.Potions; using CalamityMod.Buffs.StatDebuffs; using CalamityMod.Items.Accessories; -using CalamityMod.Items.Accessories.Vanity; using CalamityMod.Items.Armor.Vanity; using CalamityMod.Items.DraedonMisc; -using CalamityMod.Items.Fishing.BrimstoneCragCatches; using CalamityMod.Items.Fishing.FishingRods; using CalamityMod.Items.LoreItems; using CalamityMod.Items.Materials; using CalamityMod.Items.Placeables; using CalamityMod.Items.Placeables.Furniture.Trophies; -using CalamityMod.Items.SummonItems; using CalamityMod.Items.TreasureBags; using CalamityMod.Items.Weapons.Magic; using CalamityMod.Items.Weapons.Melee; @@ -68,7 +66,6 @@ using CalamityMod.Projectiles.Rogue; using CalamityMod.Projectiles.Summon; using CalamityMod.Projectiles.Typeless; using CalamityMod.Tiles.LivingFire; -using System.Collections.Generic; using Terraria; using Terraria.ID; using Terraria.ModLoader; @@ -91,6 +88,7 @@ namespace CalamityMod public static List friendlyBeeList; public static List hardModeNerfList; public static List debuffList; + public static List fireDebuffList; public static List sicknessDebuffList; public static List alcoholList; public static List spearAutoreuseList; @@ -1166,14 +1164,31 @@ namespace CalamityMod BuffType(), BuffType(), BuffType(), - BuffType(), - BuffType(), + BuffType(), + // BuffType(), BuffType(), BuffType(), BuffType(), BuffType() }; + fireDebuffList = new List() + { + BuffID.OnFire, + BuffID.OnFire3, // Hellfire + BuffID.Burning, // Touching meteorite ore or hellstone without obsidian skull + BuffID.CursedInferno, + BuffID.ShadowFlame, // Vanilla Shadowflame, can normally never be applied to players + BuffType(), // Calamity Shadowflame copy for players + BuffType(), // Crags lava + BuffType(), + BuffType(), + BuffType(), + BuffType(), + BuffType(), // Aflame enchant self damage + BuffType(), + }; + sicknessDebuffList = new List() { BuffID.Poisoned, @@ -2714,6 +2729,8 @@ namespace CalamityMod beeProjectileList = null; hardModeNerfList = null; debuffList = null; + fireDebuffList = null; + sicknessDebuffList = null; alcoholList = null; spearAutoreuseList = null; pumpkinMoonBuffList = null; diff --git a/Items/Accessories/AmbrosialAmpoule.cs b/Items/Accessories/AmbrosialAmpoule.cs index 96716ea559..c5f62d8f3c 100644 --- a/Items/Accessories/AmbrosialAmpoule.cs +++ b/Items/Accessories/AmbrosialAmpoule.cs @@ -1,6 +1,6 @@ using CalamityMod.CalPlayer; using CalamityMod.Items.Materials; -using CalamityMod.Items.Placeables; +using Microsoft.Xna.Framework; using Terraria; using Terraria.ID; using Terraria.ModLoader; @@ -22,16 +22,37 @@ namespace CalamityMod.Items.Accessories public override void UpdateAccessory(Player player, bool hideVisual) { CalamityPlayer modPlayer = player.Calamity(); + player.statLifeMax2 += 70; + + // Grant life regen based on missing health + if (!(modPlayer.rOoze || modPlayer.purity)) + { + float missingLifeRatio = (player.statLifeMax2 - player.statLife) / player.statLifeMax2; + float lifeRegenToGive = MathHelper.Lerp(4f, 12f, missingLifeRatio); + player.lifeRegen += (int)lifeRegenToGive; + } + + // bool left in for abyss light purposes modPlayer.aAmpoule = true; + + // Inherits all effects of Honey Dew and Living Dew + modPlayer.alwaysHoneyRegen = true; + modPlayer.honeyTurboRegen = true; + modPlayer.honeyDewHalveDebuffs = true; + modPlayer.livingDewHalveDebuffs = true; + + // Add light if the other accessories aren't equipped and visibility is turned on + if (!(modPlayer.rOoze || modPlayer.purity) && !hideVisual) + Lighting.AddLight(player.Center, new Vector3(1.2f, 1.7f, 2.7f)); } public override void AddRecipes() { CreateRecipe(). - AddIngredient(). + AddIngredient(). AddIngredient(). AddIngredient(3). - AddTile(TileID.MythrilAnvil). + AddTile(TileID.LunarCraftingStation). Register(); } } diff --git a/Items/Accessories/HoneyDew.cs b/Items/Accessories/HoneyDew.cs index 044ec06780..b4e86d1337 100644 --- a/Items/Accessories/HoneyDew.cs +++ b/Items/Accessories/HoneyDew.cs @@ -20,17 +20,19 @@ namespace CalamityMod.Items.Accessories public override void UpdateAccessory(Player player, bool hideVisual) { + player.statLifeMax2 += 30; CalamityPlayer modPlayer = player.Calamity(); - modPlayer.hDew = true; + modPlayer.alwaysHoneyRegen = true; + modPlayer.honeyTurboRegen = true; + modPlayer.honeyDewHalveDebuffs = true; } public override void AddRecipes() { CreateRecipe(). - AddIngredient(ItemID.JungleSpores, 12). - AddIngredient(5). - AddIngredient(3). - AddIngredient(ItemID.BottledHoney, 5). + AddIngredient(ItemID.BottledHoney, 10). + AddIngredient(ItemID.BeeWax, 3). + AddIngredient(3). AddTile(TileID.Anvils). Register(); } diff --git a/Items/Accessories/InfectedJewel.cs b/Items/Accessories/InfectedJewel.cs index 6accf136d1..cd5e261296 100644 --- a/Items/Accessories/InfectedJewel.cs +++ b/Items/Accessories/InfectedJewel.cs @@ -1,8 +1,6 @@ -using CalamityMod.Items.Placeables; -using CalamityMod.CalPlayer; -using CalamityMod.Items.Potions; -using System.Collections.Generic; +using CalamityMod.CalPlayer; using CalamityMod.Items.Materials; +using CalamityMod.Items.Potions; using Terraria; using Terraria.ID; using Terraria.ModLoader; diff --git a/Items/Accessories/LivingDew.cs b/Items/Accessories/LivingDew.cs index 9827ad277f..ab38badbea 100644 --- a/Items/Accessories/LivingDew.cs +++ b/Items/Accessories/LivingDew.cs @@ -1,4 +1,5 @@ -using CalamityMod.Items.Materials; +using CalamityMod.CalPlayer; +using CalamityMod.Items.Materials; using Terraria; using Terraria.ID; using Terraria.ModLoader; @@ -19,21 +20,25 @@ namespace CalamityMod.Items.Accessories public override void UpdateAccessory(Player player, bool hideVisual) { - //20% Movespeed and Jumpspeed, 12% reduced damage - player.moveSpeed += 0.2f; - player.jumpSpeedBoost += 1f; - player.GetDamage() -= 0.12f; + player.statLifeMax2 += 50; + + // Inherits all effects of Honey Dew + CalamityPlayer modPlayer = player.Calamity(); + modPlayer.alwaysHoneyRegen = true; + modPlayer.honeyTurboRegen = true; + modPlayer.honeyDewHalveDebuffs = true; + modPlayer.livingDewHalveDebuffs = true; } public override void AddRecipes() { CreateRecipe(). - AddIngredient(ItemID.JungleSpores, 12). - AddIngredient(5). + AddIngredient(). AddIngredient(3). - //replace with water essence later + AddIngredient(6). + // TODO -- Replace with Water Essence AddIngredient(5). - AddTile(TileID.Anvils). + AddTile(TileID.MythrilAnvil). Register(); } } diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index 1e65c81fb3..83964712e4 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -1,11 +1,9 @@ -using CalamityMod.Buffs.DamageOverTime; -using CalamityMod.CalPlayer; +using CalamityMod.CalPlayer; using CalamityMod.Items.Materials; -using CalamityMod.Items.Placeables; using CalamityMod.Rarities; -using System.Collections.Generic; +using CalamityMod.Tiles.Furniture.CraftingStations; +using Microsoft.Xna.Framework; using Terraria; -using Terraria.ID; using Terraria.ModLoader; namespace CalamityMod.Items.Accessories @@ -27,18 +25,38 @@ namespace CalamityMod.Items.Accessories public override void UpdateAccessory(Player player, bool hideVisual) { CalamityPlayer modPlayer = player.Calamity(); + player.statLifeMax2 += 100; + + // Grant life regen based on missing health + if (!(modPlayer.rOoze || modPlayer.aAmpoule)) + { + float missingLifeRatio = (player.statLifeMax2 - player.statLife) / player.statLifeMax2; + float lifeRegenToGive = MathHelper.Lerp(6f, 14f, missingLifeRatio); + player.lifeRegen += (int)lifeRegenToGive; + } + + // Abyss light, debuff near-immunity, and massively enhances debuff halving modPlayer.purity = true; + + // Inherits effects from Honey Dew and Living Dew + modPlayer.alwaysHoneyRegen = true; + modPlayer.honeyTurboRegen = true; + modPlayer.honeyDewHalveDebuffs = true; + modPlayer.livingDewHalveDebuffs = true; + + // Add light if the other accessories aren't equipped and visibility is turned on + if (!(modPlayer.rOoze || modPlayer.purity) && !hideVisual) + Lighting.AddLight(player.Center, new Vector3(0.688f, 0.829f, 1.402f)); } public override void AddRecipes() { CreateRecipe(). - AddIngredient(). AddIngredient(). - AddIngredient(1). - AddIngredient(8). - AddIngredient(8). - AddTile(TileID.LunarCraftingStation). + AddIngredient(). + AddIngredient(4). + AddIngredient(5). + AddTile(ModContent.TileType()). Register(); } } diff --git a/Items/Accessories/RadiantOoze.cs b/Items/Accessories/RadiantOoze.cs index 52825d6ca9..6e71d23589 100644 --- a/Items/Accessories/RadiantOoze.cs +++ b/Items/Accessories/RadiantOoze.cs @@ -1,4 +1,6 @@ -using CalamityMod.Items.Materials; +using CalamityMod.CalPlayer; +using CalamityMod.Items.Materials; +using Microsoft.Xna.Framework; using Terraria; using Terraria.ID; using Terraria.ModLoader; @@ -19,7 +21,22 @@ namespace CalamityMod.Items.Accessories public override void UpdateAccessory(Player player, bool hideVisual) { - player.Calamity().rOoze = true; + CalamityPlayer modPlayer = player.Calamity(); + + // Grant life regen based on missing health + if (!(modPlayer.aAmpoule || modPlayer.purity)) + { + float missingLifeRatio = (player.statLifeMax2 - player.statLife) / player.statLifeMax2; + float lifeRegenToGive = MathHelper.Lerp(4f, 12f, missingLifeRatio); + player.lifeRegen += (int)lifeRegenToGive; + } + + // bool left in for abyss light purposes + modPlayer.rOoze = true; + + // Add light if the other accessories aren't equipped and visibility is turned on + if (!(modPlayer.aAmpoule || modPlayer.purity) && !hideVisual) + Lighting.AddLight(player.Center, new Vector3(1f, 1f, 0.6f)); } public override void AddRecipes() diff --git a/Items/PermanentBoosters/MiracleFruit.cs b/Items/PermanentBoosters/MiracleFruit.cs index 4b6d640f7a..7ff881db9a 100644 --- a/Items/PermanentBoosters/MiracleFruit.cs +++ b/Items/PermanentBoosters/MiracleFruit.cs @@ -73,7 +73,7 @@ namespace CalamityMod.Items.PermanentBoosters AddIngredient(ItemID.LifeFruit, 5). AddIngredient(5). AddIngredient(5). - AddIngredient(10). + AddIngredient(12). AddTile(TileID.MythrilAnvil). Register(); } diff --git a/Items/Weapons/Ranged/TerraFlameburster.cs b/Items/Weapons/Ranged/TerraFlameburster.cs index 977c3893db..301887cddb 100644 --- a/Items/Weapons/Ranged/TerraFlameburster.cs +++ b/Items/Weapons/Ranged/TerraFlameburster.cs @@ -47,7 +47,7 @@ namespace CalamityMod.Items.Weapons.Ranged CreateRecipe(). AddIngredient(ItemID.Flamethrower). AddIngredient(). - AddIngredient(7). + AddIngredient(12). AddIngredient(5). AddTile(TileID.MythrilAnvil). Register(); diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 59a1cef57e..5d26c42ec1 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -115,12 +115,12 @@ AmbrosialAmpoule: { DisplayName: Ambrosial Ampoule Tooltip: ''' - You emit light - +50 max life - +2.5 HP/s life regen - Your natural life regen is greatly improved - Halves how long you are afflicted with sickness debuffs - When you are afflicted with a sickness debuff you quickly heal + +70 max life + Grants +2 to +6 HP/s life regen based on missing health + Provides life regeneration equivalent to standing in Honey + Standing still in Honey grants extremely powerful regen + Halves how long you are afflicted with fire and sickness debuffs + You emit yellow light if visibility is enabled ''' } @@ -244,16 +244,18 @@ Purity: { DisplayName: Purity Tooltip: ''' - A once infected crystal, now perfectly purified - You emit light - +80 max life - +2.5 HP/s life regen - You gain an additional +2.5 HP/s life regen while afflicted with a debuff - Your life regen is still increased even when afflicted with a damage over time debuff - Your natural life regen is massively improved - Greatly reduces how long you are afflicted with debuffs - When afflicted with a debuff, you will gain 18 defense - This defense will begin to fade away when you are no longer debuffed + +100 max life + Grants +3 to +7 HP/s life regen based on missing health + Provides life regeneration equivalent to standing in Honey + Standing still grants extremely powerful regen + Grants 40 defense and continuous healing while afflicted with any debuff + The healing eventually slows down if debuffed for an extended period of time + Massively boosts natural life regen while afflicted with any debuff + Each debuff beyond the first grants 10 additional defense + Granted defense fades away slowly when not afflicted with any debuffs + Makes weak damage over time debuffs harmless and halves the duration of all but the strongest debuffs + You emit shining blue light if visibility is enabled + 'A once putrid crystal, now glimmering with immaculate purity' ''' } @@ -361,12 +363,13 @@ InfectedJewel: { DisplayName: Infected Jewel Tooltip: ''' - A beautiful gem that has been corrupted by the astral infection +1 HP/s life regen - You gain an additional +2 HP/s life regen while afflicted with a debuff - Your life regen is still increased even when afflicted with a damage over time debuff - When afflicted with a debuff, you will gain 14 defense - This defense will begin to fade away when you are no longer debuffed + Grants 16 defense and +2 HP/s life regen while afflicted with any debuff + Massively boosts natural life regen while afflicted with any debuff + Each debuff beyond the first grants 4 additional defense + Granted defense fades away slowly when not afflicted with any debuffs + Makes the Astral Infection debuff harmless + 'A beautiful gemstone tarnished by spaceborne rot' ''' } @@ -461,11 +464,9 @@ CrownJewel: { DisplayName: Crown Jewel Tooltip: ''' - +0.5 HP/s life regen - You gain an additional +1.5 HP/s life regen while afflicted with a debuff - Your life regen is still increased even when afflicted with a damage over time debuff - When afflicted with a debuff, you will gain 8 defense - This defense will begin to fade away when you are no longer debuffed + +1 HP/s life regen + You gain an additional +1.5 HP/s life regen while afflicted with any debuff + Massively boosts natural life regen while afflicted with any debuff ''' } @@ -952,9 +953,9 @@ HoneyDew: { Tooltip: ''' +30 max life - You have Honey-like life regen + Provides life regeneration equivalent to standing in Honey + Standing still in Honey grants extremely powerful regen Halves how long you are afflicted with sickness debuffs - When you are afflicted with a sickness debuff you quickly heal ''' } @@ -1024,7 +1025,13 @@ LifeJelly: { LivingDew: { DisplayName: Living Dew - Tooltip: 20% increased movement and jump speed, but 12% reduced damage + Tooltip: + ''' + +50 max life + Provides life regeneration equivalent to standing in Honey + Standing still in Honey grants extremely powerful regen + Halves how long you are afflicted with fire and sickness debuffs + ''' } LumenousAmulet: { @@ -1326,9 +1333,8 @@ RadiantOoze: { DisplayName: Radiant Ooze Tooltip: ''' - You produce light - +1.5 HP/s life regen - Your natural life regen is improved + Grants +2 to +6 HP/s life regen based on missing health + You emit yellow light if visibility is enabled ''' } diff --git a/Utilities/PlayerUtils.cs b/Utilities/PlayerUtils.cs index 3bb1704ce4..2c835c9d85 100644 --- a/Utilities/PlayerUtils.cs +++ b/Utilities/PlayerUtils.cs @@ -173,9 +173,9 @@ namespace CalamityMod light += 1; if (mp.aquaticHeart) light += 1; - if (mp.aAmpoule) - light += 1; - else if (mp.rOoze) // radiant ooze and ampoule/higher don't stack + if (mp.purity) // does not stack with downgrades + light += 2; + else if (mp.rOoze || mp.aAmpoule) // the two "yellow lights" do not stack with each other light += 1; if (mp.aquaticEmblem && underwater) light += 1; @@ -245,6 +245,8 @@ namespace CalamityMod return true; } + // See also: Player.IsStandingStillForSpecialEffects (Vanilla shiny stone + standing still mana regen) + // That is more or less equivalent to this with the default value of 0.05 public static bool StandingStill(this Player player, float velocity = 0.05f) => player.velocity.Length() < velocity; /// From e287c780784cef3911ab6b98c57ca2cf07a08a14 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Sun, 27 Aug 2023 01:33:14 -0400 Subject: [PATCH 050/138] Fixed rarity and sell price of tier shuffled accessories --- Items/Accessories/AmbrosialAmpoule.cs | 4 ++-- Items/Accessories/HoneyDew.cs | 4 ++-- Items/Accessories/LivingDew.cs | 4 ++-- Items/Accessories/Purity.cs | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Items/Accessories/AmbrosialAmpoule.cs b/Items/Accessories/AmbrosialAmpoule.cs index c5f62d8f3c..486893b49c 100644 --- a/Items/Accessories/AmbrosialAmpoule.cs +++ b/Items/Accessories/AmbrosialAmpoule.cs @@ -14,8 +14,8 @@ namespace CalamityMod.Items.Accessories { Item.width = 20; Item.height = 20; - Item.value = CalamityGlobalItem.Rarity8BuyPrice; - Item.rare = ItemRarityID.Yellow; + Item.value = CalamityGlobalItem.Rarity9BuyPrice; + Item.rare = ItemRarityID.Cyan; Item.accessory = true; } diff --git a/Items/Accessories/HoneyDew.cs b/Items/Accessories/HoneyDew.cs index b4e86d1337..247b8ed539 100644 --- a/Items/Accessories/HoneyDew.cs +++ b/Items/Accessories/HoneyDew.cs @@ -13,8 +13,8 @@ namespace CalamityMod.Items.Accessories { Item.width = 20; Item.height = 20; - Item.value = CalamityGlobalItem.Rarity5BuyPrice; - Item.rare = ItemRarityID.Pink; + Item.value = CalamityGlobalItem.Rarity2BuyPrice; + Item.rare = ItemRarityID.Green; Item.accessory = true; } diff --git a/Items/Accessories/LivingDew.cs b/Items/Accessories/LivingDew.cs index c32c604721..1ef0b8db2c 100644 --- a/Items/Accessories/LivingDew.cs +++ b/Items/Accessories/LivingDew.cs @@ -13,8 +13,8 @@ namespace CalamityMod.Items.Accessories { Item.width = 34; Item.height = 22; - Item.value = CalamityGlobalItem.Rarity5BuyPrice; - Item.rare = ItemRarityID.Pink; + Item.value = CalamityGlobalItem.Rarity7BuyPrice; + Item.rare = ItemRarityID.Lime; Item.accessory = true; } diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index 83964712e4..0b366d6afe 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -18,8 +18,8 @@ namespace CalamityMod.Items.Accessories Item.width = 20; Item.height = 44; Item.accessory = true; - Item.value = CalamityGlobalItem.Rarity12BuyPrice; - Item.rare = ModContent.RarityType(); + Item.value = CalamityGlobalItem.Rarity15BuyPrice; + Item.rare = ModContent.RarityType(); } public override void UpdateAccessory(Player player, bool hideVisual) From 4a8c3a496016e9c9fbd67ba535626b8281ff7ce8 Mon Sep 17 00:00:00 2001 From: Xyk Date: Sun, 27 Aug 2023 00:09:37 -0700 Subject: [PATCH 051/138] Slightly better Purity sprite and light fixed purity light (sort of, it still looks bad) --- CalPlayer/CalamityPlayerLifeRegen.cs | 2 +- Items/Accessories/Purity.cs | 6 +++--- Items/Accessories/Purity.png | Bin 3263 -> 3270 bytes 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index 35a1fda95e..831e0fafa7 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -436,7 +436,7 @@ namespace CalamityMod.CalPlayer // Count up total frames spent healing for slowdown. ++PurityHealSlowdownFrames; } - else if (Player.miscCounter % 20 == 0 && jewelBonusDefense > 0) + else if (Player.miscCounter % 20 == 0 && jewelBonusDefense > 0) //TODO reduce defense and put cooldown at 60 like infected jewel --jewelBonusDefense; // If the player is clear of all debuffs then gradually reduce the slowdown frames diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index 0b366d6afe..01b3cae591 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -15,7 +15,7 @@ namespace CalamityMod.Items.Accessories public override void SetDefaults() { Item.defense = 8; - Item.width = 20; + Item.width = 18; Item.height = 44; Item.accessory = true; Item.value = CalamityGlobalItem.Rarity15BuyPrice; @@ -45,8 +45,8 @@ namespace CalamityMod.Items.Accessories modPlayer.livingDewHalveDebuffs = true; // Add light if the other accessories aren't equipped and visibility is turned on - if (!(modPlayer.rOoze || modPlayer.purity) && !hideVisual) - Lighting.AddLight(player.Center, new Vector3(0.688f, 0.829f, 1.402f)); + if (!(modPlayer.rOoze || modPlayer.aAmpoule) && !hideVisual) + Lighting.AddLight(player.Center, new Vector3(1.376f, 1.658f, 2.103f)); } public override void AddRecipes() diff --git a/Items/Accessories/Purity.png b/Items/Accessories/Purity.png index cb0df6f46617e18e03194f21e26d95342a530700..c710af531dd7301be7beb119b34f926d730b460e 100644 GIT binary patch delta 533 zcmV+w0_y$08O9kQiBL{Q4GJ0x0000DNk~Le0000c0000i2nGNE012kb$gv^53V+f` zL_t(oh2_}4PQp+W$MJ7Bg3n-FiN-)6#)-j6Lzo>HoJ@2Q5_D8!T-CrUI5;>HR|iG| zDKQ$Hc>xz$uS*YUkNpQ~LfhZM(A%32Ik&gx)-uN6&Ik-Z5iI^7?M~MK+_su?&1WSB zCiyK;Ks(hc0MGqC^8k|v^8wE8aesb|a~=2fcBc!#$?=hAp4Yc`0Itq&0C;(N2n8k= zCV<{x2*7Hk?17+4EhW^j&s+|G!&)Q#Fd(#~u|SfE^9Q3!nrN6FU@52t&>IX5z~;uf z2Q*PjKoV8bRKR>E&>+d0D&YukqDq=bnBG8R!8FJ<4v1gU<%QXfOfOQ|7Jp>IdZp~S zF>VRveu>QgF&+bu|C$0nOS-(UMN6qSRJ}b&q}`GBM>1W>rw`@<>XJsm1f(Ot^uqMZ zTS|NHG=vAOrf2-3Fx`454;FM734&^vB<|u*J}fG(gRJj$y|D&?Bta^qxac`e8x9sEt%2 zt$N*Qy|V+`sx=J2+1-UNEa-r%n}+PbH1P8JG!$gpwgD)WO8>K6BnGB|QJ*$-mKOF6 XU|+e#>5w=l00000NkvXXu0mjfQ(*3` delta 526 zcmV+p0`dLE8NV4JiBL{Q4GJ0x0000DNk~Le0000e0000i2nGNE02goid$A$D3V+K< zL_t(oh3(j}O9F8e!13>GVrz>-v`P_*B27X~H8?jov?dKH=-gjmpj&&;(Cl8|7>W{w z%?>UNExBHcukQD_>wX%7=lM3dcRxPo^M1egbX?bEnNe@GU4WZf)mh|zC$hjHxBwXl zTUZt_@&tBVECTS@?Xn0ox_0In(*#yT&rZvZqaO#q&r@2#NG z2MVOq>jSWp&lw;BN~?jNi39-ELOFgw;LlQ9!6e4B2emErS^#x|qreV8r`LA@4)*s9 z*jW8EBy3B)RzTl{G)!Vwm3D|3wxy0P(Dta)Kn?Tc0rQu7^?`$#P`>h#T7Q6lmR62F zX&MChJ{kd#{F(y6rCxpDq9xWFv))#uz519;0N75Y4Cr(#x#mDm7|lW{pK~_Ad4NGp zf&kBJRU>~ Date: Sun, 27 Aug 2023 17:01:32 +0700 Subject: [PATCH 052/138] Resprites + Eclipse's Fall changes - Resprited Accel Round, Night's Ray, Storm Ruler beam - Added an explosion sprite to Umbraphile armor - Visually tweaked EF to look better with its sprite - Also did some balancing for EF --- Items/Ammo/AccelerationRound.cs | 4 +- Items/Ammo/AccelerationRound.png | Bin 253 -> 269 bytes Items/Weapons/Magic/NightsRay.cs | 7 +-- Items/Weapons/Magic/NightsRay.png | Bin 714 -> 954 bytes Items/Weapons/Rogue/EclipsesFall.cs | 2 +- .../Mods.CalamityMod.Projectiles.Rogue.hjson | 1 + Projectiles/Melee/StormRulerProj.cs | 5 +- Projectiles/Melee/StormRulerProj.png | Bin 444 -> 675 bytes Projectiles/Rogue/EclipseStealthBoom.cs | 39 ++++++++++++ Projectiles/Rogue/EclipseStealthBoom.png | Bin 0 -> 1967 bytes Projectiles/Rogue/EclipsesFallMain.cs | 47 +++++++------- Projectiles/Rogue/EclipsesSmol.cs | 33 ++-------- Projectiles/Rogue/EclipsesStealth.cs | 59 ++++++++++-------- Projectiles/Rogue/UmbraphileBoom.cs | 34 +++++----- Projectiles/Rogue/UmbraphileBoom.png | Bin 0 -> 1058 bytes 15 files changed, 127 insertions(+), 104 deletions(-) create mode 100644 Projectiles/Rogue/EclipseStealthBoom.cs create mode 100644 Projectiles/Rogue/EclipseStealthBoom.png create mode 100644 Projectiles/Rogue/UmbraphileBoom.png diff --git a/Items/Ammo/AccelerationRound.cs b/Items/Ammo/AccelerationRound.cs index c7b8def04d..7d95498944 100644 --- a/Items/Ammo/AccelerationRound.cs +++ b/Items/Ammo/AccelerationRound.cs @@ -19,8 +19,8 @@ namespace CalamityMod.Items.Ammo { Item.damage = 10; Item.DamageType = DamageClass.Ranged; - Item.width = 8; - Item.height = 8; + Item.width = 10; + Item.height = 16; Item.maxStack = 9999; Item.consumable = true; Item.knockBack = 1.25f; diff --git a/Items/Ammo/AccelerationRound.png b/Items/Ammo/AccelerationRound.png index aaae66b94b9b5a0fd5c984f86d6494c923fa7af4..c2c6a926ad476821f19cfb3ef2bab1e988cec2f0 100644 GIT binary patch literal 269 zcmeAS@N?(olHy`uVBq!ia0vp^AhrMp8<5nmf9C+C7>k44ofy`glX(f`to3wp4AGc) zcA_E|lcR*&{S$G{vWB^a6->TnbJK2aNfJ4@#a-ZboCA+sLa)*zUXjI)5g%C0PFuCj zWRx`U`Rr{UU$JLC|DKf0MVn17*2RDBj_=&($*}q5kx;3Go%gyF7R}(FqWCqM;m&JW zhI#piE#~tj_9b00&^vm{Ecy3`t=tV#afdo4_J}eZ|HI}Gn#+)3U&U}@$ItSzopr08GYR=l}o! literal 253 zcmeAS@N?(olHy`uVBq!ia0vp^96&6jA5L~c#`DCC7XMsm# zF#`j)FbFd;%$g$s6l5>)^mS!_$i&L5Zsz?uq5vq=<>}%WqH#VsrGbgr`0{@qj|YcV zUhd%m0v{e025z6_^%WY-Kydi7dw*il|4yUEkMDU_oO+T9Qo^%7-p$Ye2srW^H577~ z&hV;D6B7`gw?6>{DtJ!1VAAn^3Ldf%E-J jA0Iw;SMpt8Va9lNrJj?}i^}alS21|H`njxgN@xNAkl#-< diff --git a/Items/Weapons/Magic/NightsRay.cs b/Items/Weapons/Magic/NightsRay.cs index 6bc2641140..0fb6594049 100644 --- a/Items/Weapons/Magic/NightsRay.cs +++ b/Items/Weapons/Magic/NightsRay.cs @@ -12,7 +12,7 @@ namespace CalamityMod.Items.Weapons.Magic public new string LocalizationCategory => "Items.Weapons.Magic"; public override void SetStaticDefaults() { - Item.staff[Item.type] = true; + Item.staff[Item.type] = true; } public override void SetDefaults() @@ -20,8 +20,8 @@ namespace CalamityMod.Items.Weapons.Magic Item.damage = 24; Item.DamageType = DamageClass.Magic; Item.mana = 10; - Item.width = 50; - Item.height = 50; + Item.width = 58; + Item.height = 54; Item.useTime = 20; Item.useAnimation = 20; Item.useStyle = ItemUseStyleID.Shoot; @@ -34,7 +34,6 @@ namespace CalamityMod.Items.Weapons.Magic Item.shoot = ModContent.ProjectileType(); Item.shootSpeed = 6f; } - public override void AddRecipes() { diff --git a/Items/Weapons/Magic/NightsRay.png b/Items/Weapons/Magic/NightsRay.png index 39da37b60d9d9012c1ebfd0a8e31123e53e8e454..ce0d6dcdad6368ce9ec4a0f328e47681fcd41ee3 100644 GIT binary patch literal 954 zcmV;r14aCaP)Z>vCtw}*t zt8GEFm(axT0z^4!nX0Q2)lTSi5ppg?^4%q=i1a3jwA~ifwZ66uF>@qaB1@vIwu`)j z(sja4)HXu%lVb5Sl9nc_ZC_t6V%F|mlII$IH!&vJRaNS{04 zNZ`T4dyxFo*P0}P{ZAiC^CYD9#HFcQaHyoJ29e$j8&TT{Ey~S7vTIsf5I-dTKx7X~ z662@p@%4L)sLm;|F2rt^U-Ibi&?v@Se=S4QwnEDel!C~)&KroADzgw9&x&fiKXao* z)RXNA+!4P2k_@{?RifGmWrI*%P=qAE_fH^l{T!J5DtV3rl1%r;V9NL4jUZ^y(+0iB zLcRsmUZ~pY8D*UF?3755^SH?S)bxJ;o#?#_yH#;r!DX zG=D}OR@cYbCV$?DYA=*6-i}{&NcKmsc)!}`|16R}{z-yhRBd_ETnVbAO($v_q3SKm zb&?rY37SQ0Ca;=KR9m6yrjW4YQ~ilFHp)mErs0}zuSlML*I7`-{4 z$x~(@580#I3snWitq@Nk8U5lpu_yHzBKJb9LXvmJtcluAXiml|64=vhH^|k{v0YH0*V? z7fOLAqZ@+SBhpDucSg1mdUWeC>^wJ2T!(n>Bu8p>HC#t+CzP3B4;$*6@cCN*%(||F cM0FSX7woL8Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0$)i)K~!i%?U*}g z6j2z3S3!_nP@}9w47jpJi6ANpV$?!>G=hlOh=o=bHWDPIV3o!q*w{)+A%zHbmO%*! zD#`|5pcqh$;)@MhMedpTmgJCOL*l~D=6*1od$*Wn&YAz-f9{Gx&e*c1e2#FvZt}U*lh}D++q?;lp44{ zIwh@*znxPf-M>!+i3w!lJ0*|^Tq|Faj?X-lj{dzP^#q*09VO|+tGbkgASU2sC31W3 zu=L8)0qOoTiKD%{lA3w*V(t#^!~_-#iFg9%uO~s_JPtP_CeVzm8t^{e@m^}=*#oJs z`%X;2Apzd;qeqhU|MJNZX-~OZdTjGPse|)QRuVA*#}iKS-hZ6-?}~UT0sqT+@LKR1@!D9v3E;@ZJ*PBZs`CpaE1}L$z@Oav z`c^yNjLu2G&+9p-$8l&E=b`fw;G~Sxg4MO-(spwma-Trs0m3^UuHbyQ!igEDX6;P= wYk+m0(*pW=C)PlVXe7{#c5@zbo{L#g(tuARZ(kPWg!x=Wq;ZK9cnN2a zy#?e95B8~~qDpaGe{pw%Qar)u3cxgX|@BD+mh#fgp%28JK_i@T|V#Y{K^= zT?1pjHgR;|Y4gH*N$4t5^MXhO1npS4Qw{1J(rFfgOQ&J(M8n>s6%pbDp_dM2cywe) zjo`ilohH13??v$LL(tj91#M-iY6SHF+<&k~@O=n6QRyDV1Kh|# zag=R|5RhiduqlI;9v2CLIo7=(<;p;{{v*q}4+$z*wF>eJIaVaubq`nV00000NkvXX Ju0mjf000DoG>8BI literal 444 zcmV;t0Ym3ZH`|>d$yS?tEJ15)>l9fos!H5b)&ne|&fG2ta*&?3NyBUN^#3D${$i$8e mx*3F1z#?dKVPj{Xo5438B8cEo4UioG0000 "Projectiles.Rogue"; + + public const int Lifetime = 35; // 7 animation frames, 12 FPS + + public override void SetStaticDefaults() + { + Main.projFrames[Type] = 7; + } + + public override void SetDefaults() + { + Projectile.width = Projectile.height = 102; + Projectile.friendly = true; + Projectile.ignoreWater = true; + Projectile.tileCollide = false; + Projectile.DamageType = RogueDamageClass.Instance; + Projectile.penetrate = -1; + Projectile.timeLeft = Lifetime; + Projectile.usesLocalNPCImmunity = true; + Projectile.localNPCHitCooldown = -1; + } + + public override void AI() + { + Projectile.frameCounter++; + Projectile.frame = Projectile.frameCounter / 5; + + if (Projectile.frameCounter > Lifetime) + Projectile.Kill(); + } + } +} diff --git a/Projectiles/Rogue/EclipseStealthBoom.png b/Projectiles/Rogue/EclipseStealthBoom.png new file mode 100644 index 0000000000000000000000000000000000000000..e8611cd39b686b655bc3719b8a052337bef3d5d4 GIT binary patch literal 1967 zcmZWqc~sJg7DglmO{GkQT#>}lO!3E{4-FS`NgryZlL@-`mZU>I54~4);}K+u+I;v(4&YHrsQp zDNv7kD|`1bI1 zZ>iMakS3KO@A)yrr#;!_+msC|n++bBxu*iouF?<}V*cYxoTZhv!NL$u4PaA|m4Q7% zxA$QHfSz>~s1VFS?T|WD^>Uw>R`u?Sc4hoQU|uQ;1{LN<_<@k$3I0n{adoUOoAB$K zrUJB;6!jZsZ~N3-q?yJctWC1R9^fI*~T(9te?+zxb&FLDMC#W z`9%;^Z1%lpcDRn)DDrmZF*A)7cE-dC2Zn8c&)K%h@^T^>;)nFg#N_Ie5oc)zeQDQJ(SOSnmTv&|>3;Wde=(TsmV-FM_FPpLJW1W{*Jl=iF z389z9ILuefG*O@G!zbP4gN0S!<^-`QNDNIvnPD8|T}%|+J(1pmQ1M6B_BF1 z@T~XvHP!c)q+@|9TO>_4bt<+7no?)aSSeuLoH=o9U*Ay@X9m>6UE=|@7l};A110h3 z#{SM=OV<+odJ`VQ%8!?MrU%|SO-&6(T`Rsvy_N)-PJI7?c=CfaBJ@GAhk-`_aaw zIfcGcbNQW73Xd}^Wb6AX!)As2y=qEy`s$SECgs)wP6L?((bGS$@-a-Hn~pp(;Srzd zih_@!RPvG!<~g2ry;u`-sBH1d73_@Q3b zy~MNrWFpg33ZaeCA?j;A$$@pC$p(3*p*{V)xTG!NH%~%)kA=f?^W2&8tT=J_)@%pd z(K}OUi!T%5=MI8nNVW%^_3e?W+9v#Dg3E4^Yluf}S7Fsnyi~P){9(Dr=lAYM>QbK| z0x--Be{Rn$VOG2OGvIY;f`GNGaJi;`RjHILoLtMZWF7$s8+R-%e=__?ruM_SM?5Vx ztL4@Amyu-d{iivEoa<57>1SGjg;yU{tT z=6T)4m-3Ri%j8vo#2#%|uKjx8ZS!6&sUUkaK5?3|OeT~Ze3TK1$?nuSWTbDc#Z8*) zy;1QzpG_y=!Lg(E^ant$h+A7}fz?QN{`zT{gh}8RvsT0byxO~Z;)4;C%6=Yw;L;U_ zZCRKl8>ansR$dQf37uo^_9O{KG={P}Py4%kOq%z{8|xH(5N}Q(h-Ux^h@HcY3xd)H z#_J0Y)8!!D7{T*Il9XEv&wZ7}iu_wLD$JH!%!Y&LZLAX!^g^NEAp_Yx0)kIvEDAS4 z(Zef`2b*W&{)~I`eBL4^^pO=i-ZQByE!Uf<1>$bb|CF&!0vHr!>_Mt{LkIs5HuOk=4&Qot(erG{865=XX+c#=ilhVU@4| literal 0 HcmV?d00001 diff --git a/Projectiles/Rogue/EclipsesFallMain.cs b/Projectiles/Rogue/EclipsesFallMain.cs index 890660b424..099b807166 100644 --- a/Projectiles/Rogue/EclipsesFallMain.cs +++ b/Projectiles/Rogue/EclipsesFallMain.cs @@ -1,4 +1,5 @@ -using Microsoft.Xna.Framework; +using CalamityMod.Particles; +using Microsoft.Xna.Framework; using Terraria; using Terraria.ID; using Terraria.ModLoader; @@ -10,6 +11,10 @@ namespace CalamityMod.Projectiles.Rogue public new string LocalizationCategory => "Projectiles.Rogue"; public override string Texture => "CalamityMod/Items/Weapons/Rogue/EclipsesFall"; + // these also affect KB + public const float RainDamageMultMin = 0.4f; + public const float RainDamageMultMax = 0.5f; + public override void SetStaticDefaults() { ProjectileID.Sets.TrailCacheLength[Projectile.type] = 6; @@ -20,44 +25,42 @@ namespace CalamityMod.Projectiles.Rogue { Projectile.width = Projectile.height = 40; Projectile.friendly = true; - Projectile.penetrate = -1; - Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = 10; - Projectile.extraUpdates = 1; Projectile.ignoreWater = true; Projectile.tileCollide = false; - Projectile.timeLeft = 300; Projectile.DamageType = RogueDamageClass.Instance; + Projectile.MaxUpdates = 2; + Projectile.penetrate = 3; + Projectile.usesLocalNPCImmunity = true; + Projectile.localNPCHitCooldown = 6 * Projectile.MaxUpdates; + Projectile.timeLeft = 150 * Projectile.MaxUpdates; } public override void AI() { - if (Main.rand.NextBool(8)) - { - Dust.NewDust(Projectile.position + Projectile.velocity, Projectile.width, Projectile.height, 138, Projectile.velocity.X * 0.5f, Projectile.velocity.Y * 0.5f); - } + Lighting.AddLight(Projectile.Center, 1f, 0.8f, 0.3f); Projectile.rotation = Projectile.velocity.ToRotation() + MathHelper.PiOver4; + if (Main.rand.NextBool(5)) + { + Vector2 trailPos = Projectile.Center + Vector2.UnitY.RotatedBy(Projectile.rotation) * Main.rand.NextFloat(-16f, 16f); + float trailScale = Main.rand.NextFloat(0.8f, 1.2f); + Color trailColor = Main.rand.NextBool() ? Color.Indigo : Color.DarkOrange; + Particle eclipseTrail = new SparkParticle(trailPos, Projectile.velocity * 0.2f, false, 60, trailScale, trailColor); + GeneralParticleHandler.SpawnParticle(eclipseTrail); + } } - public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) - { - SpawnSpears(target.Center); - } + public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) => SpawnSpears(target.Center); - public override void OnHitPlayer(Player target, Player.HurtInfo info) - { - SpawnSpears(target.Center); - } + public override void OnHitPlayer(Player target, Player.HurtInfo info) => SpawnSpears(target.Center); private void SpawnSpears(Vector2 targetPos) { - int spearAmt = Main.rand.Next(3, 6); //3 to 5 spears + int spearAmt = Main.rand.Next(3, 5 + 1); // 3 to 5 spears var source = Projectile.GetSource_FromThis(); for (int n = 0; n < spearAmt; n++) { - float dmgMult = 0.08f * Main.rand.NextFloat(4f, 7f); - float kBMult = 0.1f * Main.rand.NextFloat(7f, 10f); - CalamityUtils.ProjectileRain(source, targetPos, 400f, 100f, 500f, 800f, 29f, ModContent.ProjectileType(), (int)(Projectile.damage * dmgMult), Projectile.knockBack * kBMult, Projectile.owner); + float dmgMult = Main.rand.NextFloat(RainDamageMultMin, RainDamageMultMax); + CalamityUtils.ProjectileRain(source, targetPos, 400f, 100f, 500f, 800f, 29f, ModContent.ProjectileType(), (int)(Projectile.damage * dmgMult), Projectile.knockBack * dmgMult, Projectile.owner); } } diff --git a/Projectiles/Rogue/EclipsesSmol.cs b/Projectiles/Rogue/EclipsesSmol.cs index 7746962ca8..a4073c7426 100644 --- a/Projectiles/Rogue/EclipsesSmol.cs +++ b/Projectiles/Rogue/EclipsesSmol.cs @@ -1,9 +1,8 @@ using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Graphics; using Terraria; -using Terraria.ID; using Terraria.ModLoader; -using Terraria.Audio; + namespace CalamityMod.Projectiles.Rogue { public class EclipsesSmol : ModProjectile, ILocalizedModType @@ -15,38 +14,16 @@ namespace CalamityMod.Projectiles.Rogue Projectile.friendly = true; Projectile.tileCollide = false; Projectile.ignoreWater = true; - Projectile.timeLeft = 150; - Projectile.extraUpdates = 1; Projectile.DamageType = RogueDamageClass.Instance; + Projectile.MaxUpdates = 2; + Projectile.timeLeft = 75 * Projectile.MaxUpdates; } public override void AI() { + Lighting.AddLight(Projectile.Center, 0.5f, 0.4f, 0.15f); Projectile.rotation = Projectile.velocity.ToRotation() + MathHelper.PiOver4; - CalamityUtils.HomeInOnNPC(Projectile, true, 200f, 12f, 20f); - } - - public override void Kill(int timeLeft) - { - SoundEngine.PlaySound(SoundID.Item14, Projectile.Center); - for (int i = 0; i < 2; i++) - { - int dustInt = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, 138, 0f, 0f, 100, default, 1.2f); - Main.dust[dustInt].velocity *= 3f; - if (Main.rand.NextBool(2)) - { - Main.dust[dustInt].scale = 0.5f; - Main.dust[dustInt].fadeIn = 1f + (float)Main.rand.Next(10) * 0.1f; - } - } - for (int j = 0; j < 3; j++) - { - int moreDust = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, 138, 0f, 0f, 100, default, 1.7f); - Main.dust[moreDust].noGravity = true; - Main.dust[moreDust].velocity *= 5f; - moreDust = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, 138, 0f, 0f, 100, default, 1f); - Main.dust[moreDust].velocity *= 2f; - } + CalamityUtils.HomeInOnNPC(Projectile, true, 200f, 16f, 20f); } public override bool PreDraw(ref Color lightColor) diff --git a/Projectiles/Rogue/EclipsesStealth.cs b/Projectiles/Rogue/EclipsesStealth.cs index e87f3cd117..9f935f2652 100644 --- a/Projectiles/Rogue/EclipsesStealth.cs +++ b/Projectiles/Rogue/EclipsesStealth.cs @@ -1,5 +1,7 @@ -using Microsoft.Xna.Framework; +using CalamityMod.Particles; +using Microsoft.Xna.Framework; using Terraria; +using Terraria.Audio; using Terraria.ID; using Terraria.ModLoader; @@ -10,6 +12,10 @@ namespace CalamityMod.Projectiles.Rogue public new string LocalizationCategory => "Projectiles.Rogue"; public override string Texture => "CalamityMod/Items/Weapons/Rogue/EclipsesFall"; + // these also affect KB + public const float RainDamageMult = 0.25f; + public const float ExplosionDamageMult = 0.5f; + // For more consistent DPS, always alternates between spawning 1 and 2 spears instead of picking randomly private bool spawnTwoSpears = true; private bool changedTimeLeft = false; @@ -22,30 +28,35 @@ namespace CalamityMod.Projectiles.Rogue public override void SetDefaults() { - Projectile.width = 25; - Projectile.height = 25; + Projectile.width = Projectile.height = 40; Projectile.friendly = true; - Projectile.penetrate = -1; - Projectile.timeLeft = 300; Projectile.ignoreWater = true; - Projectile.tileCollide = false; + Projectile.tileCollide = false; + Projectile.DamageType = RogueDamageClass.Instance; + Projectile.MaxUpdates = 2; + Projectile.penetrate = -1; Projectile.usesLocalNPCImmunity = true; Projectile.localNPCHitCooldown = -1; - Projectile.DamageType = RogueDamageClass.Instance; + Projectile.timeLeft = 150 * Projectile.MaxUpdates; } // Uses localAI[1] to decide how many frames until the next spear drops. public override void AI() { + Lighting.AddLight(Projectile.Center, 1f, 0.8f, 0.3f); // Behavior when not sticking to anything if (Projectile.ai[0] == 0f) { // Keep the spear oriented in the correct direction Projectile.rotation = Projectile.velocity.ToRotation() + MathHelper.PiOver4; - - // Spawn dust while flying - if (Main.rand.NextBool(8)) - Dust.NewDust(Projectile.position + Projectile.velocity, Projectile.width, Projectile.height, 138, Projectile.velocity.X * 0.5f, Projectile.velocity.Y * 0.5f); + if (Main.rand.NextBool(5)) + { + Vector2 trailPos = Projectile.Center + Vector2.UnitY.RotatedBy(Projectile.rotation) * Main.rand.NextFloat(-16f, 16f); + float trailScale = Main.rand.NextFloat(0.8f, 1.2f); + Color trailColor = Main.rand.NextBool() ? Color.Indigo : Color.DarkOrange; + Particle eclipseTrail = new SparkParticle(trailPos, Projectile.velocity * 0.2f, false, 60, trailScale, trailColor); + GeneralParticleHandler.SpawnParticle(eclipseTrail); + } } // Behavior when having impaled a target @@ -54,12 +65,12 @@ namespace CalamityMod.Projectiles.Rogue // Eclipse's Fall is guaranteed to impale for 10 seconds, no more, no less if (!changedTimeLeft) { - Projectile.timeLeft = 600; + Projectile.timeLeft = 600 * Projectile.MaxUpdates; changedTimeLeft = true; } // Spawn spears. As this uses local AI, it's done client-side only. - if (Projectile.owner == Main.myPlayer) + if (Projectile.owner == Main.myPlayer && Projectile.FinalExtraUpdate()) { Projectile.localAI[1] -= 1f; @@ -67,16 +78,14 @@ namespace CalamityMod.Projectiles.Rogue if (Projectile.localAI[1] <= 0f) { // Set up the spear counter for next time. Used to be every 5 frames there was a 50% chance; now it's more reliable but slower. - Projectile.localAI[1] = Main.rand.Next(8, 14); // 8 to 13 frames between each spearfall + Projectile.localAI[1] = Main.rand.Next(8, 13); // 8 to 12 frames between each spearfall int type = ModContent.ProjectileType(); - int smolDamage = (int)(Projectile.damage * 0.22f); - float smolKB = 3f; // Used to be a 50% chance each spearfall for 1 or 2. Now is consistent. int numSpears = spawnTwoSpears ? 2 : 1; spawnTwoSpears = !spawnTwoSpears; for (int i = 0; i < numSpears; ++i) - CalamityUtils.ProjectileRain(source, Projectile.Center, 400f, 100f, 500f, 800f, 29f, type, smolDamage, smolKB, Projectile.owner); + CalamityUtils.ProjectileRain(source, Projectile.Center, 400f, 100f, 500f, 800f, 29f, type, (int)(Projectile.damage * RainDamageMult), Projectile.knockBack * RainDamageMult, Projectile.owner); } } } @@ -102,15 +111,15 @@ namespace CalamityMod.Projectiles.Rogue return false; } - public override bool? CanHitNPC(NPC target) - { - if (Projectile.ai[0] == 1f) - { - return false; - } - return null; - } + public override bool? CanHitNPC(NPC target) => Projectile.ai[0] == 1f ? false : base.CanHitNPC(target); public override bool CanHitPvp(Player target) => Projectile.ai[0] != 1f; + + public override void Kill(int timeLeft) + { + SoundEngine.PlaySound(SoundID.Item14, Projectile.Center); + if (Main.myPlayer == Projectile.owner) + Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, Vector2.Zero, ModContent.ProjectileType(), (int)(Projectile.damage * ExplosionDamageMult), Projectile.knockBack * ExplosionDamageMult, Projectile.owner); + } } } diff --git a/Projectiles/Rogue/UmbraphileBoom.cs b/Projectiles/Rogue/UmbraphileBoom.cs index c75540960e..86ae946f4e 100644 --- a/Projectiles/Rogue/UmbraphileBoom.cs +++ b/Projectiles/Rogue/UmbraphileBoom.cs @@ -1,5 +1,4 @@ using CalamityMod.Buffs.DamageOverTime; -using Microsoft.Xna.Framework; using Terraria; using Terraria.ID; using Terraria.ModLoader; @@ -9,36 +8,33 @@ namespace CalamityMod.Projectiles.Rogue public class UmbraphileBoom : ModProjectile, ILocalizedModType { public new string LocalizationCategory => "Projectiles.Rogue"; - public override string Texture => "CalamityMod/Projectiles/InvisibleProj"; + + public const int Lifetime = 35; // 7 animation frames, 12 FPS + + public override void SetStaticDefaults() + { + Main.projFrames[Type] = 7; + } public override void SetDefaults() { - Projectile.width = 60; - Projectile.height = 60; + Projectile.width = Projectile.height = 58; Projectile.friendly = true; Projectile.ignoreWater = true; Projectile.tileCollide = false; Projectile.penetrate = -1; - Projectile.timeLeft = 5; + Projectile.timeLeft = Lifetime; Projectile.usesLocalNPCImmunity = true; Projectile.localNPCHitCooldown = -1; } - public override void Kill(int timeLeft) + public override void AI() { - for (int s = 0; s < 20; s++) - { - int dustType = Main.rand.NextBool() ? 246 : 176; - float dustSpeed = Main.rand.NextFloat(3f, 9f); - Vector2 dustVel = CalamityUtils.RandomVelocity(10f, dustSpeed, dustSpeed, 1f); - int boom = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, dustType, 0f, 0f, 100, default, 1f); - Dust dust = Main.dust[boom]; - dust.noGravity = true; - dust.position = Projectile.Center; - dust.position.X += (float)Main.rand.Next(-10, 11); - dust.position.Y += (float)Main.rand.Next(-10, 11); - dust.velocity = dustVel; - } + Projectile.frameCounter++; + Projectile.frame = Projectile.frameCounter / 5; + + if (Projectile.frameCounter > Lifetime) + Projectile.Kill(); } public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) diff --git a/Projectiles/Rogue/UmbraphileBoom.png b/Projectiles/Rogue/UmbraphileBoom.png new file mode 100644 index 0000000000000000000000000000000000000000..8e6d4ccdf20dfa2ed965d1923a490cd95495e5a5 GIT binary patch literal 1058 zcmV+-1l{|IP)30{{R3SANEw00001b5ch_0Itp) z=>Px#8&FJCMF0Q*%iH`U92x)s0P%%C{=Z89|NmBUwlzm@cRkdV00009bW%=J0RR90 z|NsC0|2G1g)Bpejph-kQRCt{2-06}cD-Z_I4x?P&|A{9sCp*~^s9dPf&hO9d5sqL% z0cv=Eej<@bsWhrGy6ynu2l{Y8UNycxhynlqTaIT2{|9xKLus-|W*aE9e~B)0OVpQ!LE4#&+Yh zrK6L=_@JPnlN)&yG2MUei$tzWTI6?A*uwTw*g8dRDyaB%F3|iSaTkwWnh^#46gmKzZ(W4?2d>WotU?E_B(N&S6T>peyu>IXqup*zSrczj!ZoS4BmO zsR5mB9A1>$B(cGEh&Fsd{(ie(5*f#aZ@O!^8+J$Z57n>tQnCe{}SWd zX+)OSJMcGsAV&j{ms`>Fa9T)Suil4|$AP6CtfH`d@gIOfxd$D6=z1LXG-3LPv;C+Q zy3CHNn8Ga#-J;}AG5khHOmToXypyH_5ypoShFi>^rm8sIc2byZHOz;{o~8=D?h+k- z0VSkRh#;RHNEv8I+le^&mhLo#>R5r6)rIbgX}x&Uq6UKmgEnYWK=Yx$7kT{;d(<(a zd8gZr7$%AxrODUr*e|T=C@5m~bmByZC!(wlKs&mYl?K-6$GrjgGw&UQS zq}&s>+eX!lg3e*RmH5!IxW!(SdjSKaroI1}fHxft%jq#)q`m5N@Y_T2k@_!d%DrXr zru>ubrS(&MKmDFIXSb9m<*_dvZJC~w|5(GG@>Ql#Kzp0;;Q7ty6^q7o?VfFFKmCj= z6Ny}(Q%jv0r6<@=uWWZ0ExUONpP>D%c|Xm87mY+B5iYZhVe%G9K}ByuRdiH5-5?b- c5{WG3AL?p-8E6s<0ssI207*qoM6N<$g4opqnE(I) literal 0 HcmV?d00001 From bef76b90117fabaa8bc3e917079a14c1927d6cd8 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sun, 27 Aug 2023 15:23:07 -0400 Subject: [PATCH 053/138] Added Zenith and Gruesome Eminence to the pierce resist exception list (This would certainly never have immediate disastrous consequences on balance right guys) --- CalamityLists.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CalamityLists.cs b/CalamityLists.cs index d658b3ff3c..5439ad99a8 100644 --- a/CalamityLists.cs +++ b/CalamityLists.cs @@ -1989,6 +1989,7 @@ namespace CalamityMod ProjectileID.MonkStaffT3, ProjectileID.LastPrismLaser, ProjectileID.ChargedBlasterLaser, + ProjectileID.FinalFractal, ProjectileType(), ProjectileType(), ProjectileType(), @@ -2035,6 +2036,7 @@ namespace CalamityMod ProjectileType(), ProjectileType(), ProjectileType(), + ProjectileType(), }; // Lists of enemies that resist piercing to some extent (mostly worms). From 2ddfecfa5797551efb73e4c4941dbfea9b2d05d1 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sun, 27 Aug 2023 15:39:03 -0400 Subject: [PATCH 054/138] Gruesome Eminence attempted rebalance, take 1 --- Items/Weapons/Magic/GruesomeEminence.cs | 2 +- Projectiles/Magic/SpiritCongregation.cs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Magic/GruesomeEminence.cs b/Items/Weapons/Magic/GruesomeEminence.cs index b71835a0fd..928015d4d8 100644 --- a/Items/Weapons/Magic/GruesomeEminence.cs +++ b/Items/Weapons/Magic/GruesomeEminence.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Magic public new string LocalizationCategory => "Items.Weapons.Magic"; public override void SetDefaults() { - Item.damage = 888; + Item.damage = 666; Item.DamageType = DamageClass.Magic; Item.noUseGraphic = true; Item.channel = true; diff --git a/Projectiles/Magic/SpiritCongregation.cs b/Projectiles/Magic/SpiritCongregation.cs index 0831b4b830..c8d121a820 100644 --- a/Projectiles/Magic/SpiritCongregation.cs +++ b/Projectiles/Magic/SpiritCongregation.cs @@ -60,7 +60,7 @@ namespace CalamityMod.Projectiles.Magic Projectile.tileCollide = false; Projectile.ignoreWater = true; Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = 6; + Projectile.localNPCHitCooldown = 10; Projectile.timeLeft = 90000; } @@ -125,7 +125,7 @@ namespace CalamityMod.Projectiles.Magic BaseDamage = Projectile.damage; else { - float damageBoostFactor = MathHelper.SmoothStep(1f, 3.3f, CurrentPower); + float damageBoostFactor = MathHelper.SmoothStep(1f, 2f, CurrentPower); Projectile.damage = (int)(BaseDamage * damageBoostFactor); } From 98071d5ad34659e174026d2b7227c6679f900198 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sun, 27 Aug 2023 15:51:36 -0400 Subject: [PATCH 055/138] Gruesome Eminence, take 2 --- Projectiles/Magic/SpiritCongregation.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Projectiles/Magic/SpiritCongregation.cs b/Projectiles/Magic/SpiritCongregation.cs index c8d121a820..e89c51526b 100644 --- a/Projectiles/Magic/SpiritCongregation.cs +++ b/Projectiles/Magic/SpiritCongregation.cs @@ -60,7 +60,7 @@ namespace CalamityMod.Projectiles.Magic Projectile.tileCollide = false; Projectile.ignoreWater = true; Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = 10; + Projectile.localNPCHitCooldown = 18; Projectile.timeLeft = 90000; } From 32b2686cb74e782327bdeaa38ac50ceb3125b6aa Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sun, 27 Aug 2023 16:04:44 -0400 Subject: [PATCH 056/138] Take 3 (The iframe nerf killed it) --- Projectiles/Magic/SpiritCongregation.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Projectiles/Magic/SpiritCongregation.cs b/Projectiles/Magic/SpiritCongregation.cs index e89c51526b..ac81c8ca39 100644 --- a/Projectiles/Magic/SpiritCongregation.cs +++ b/Projectiles/Magic/SpiritCongregation.cs @@ -60,7 +60,7 @@ namespace CalamityMod.Projectiles.Magic Projectile.tileCollide = false; Projectile.ignoreWater = true; Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = 18; + Projectile.localNPCHitCooldown = 12; Projectile.timeLeft = 90000; } @@ -125,7 +125,7 @@ namespace CalamityMod.Projectiles.Magic BaseDamage = Projectile.damage; else { - float damageBoostFactor = MathHelper.SmoothStep(1f, 2f, CurrentPower); + float damageBoostFactor = MathHelper.SmoothStep(1f, 1.85f, CurrentPower); Projectile.damage = (int)(BaseDamage * damageBoostFactor); } From 3e438c0c77df74af0134ad814c0764d33179d636 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sun, 27 Aug 2023 16:45:51 -0400 Subject: [PATCH 057/138] Ares resists Zenith by 20%, Thanatos by 40% --- Balancing/BalancingChangesManager.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Balancing/BalancingChangesManager.cs b/Balancing/BalancingChangesManager.cs index f771e20fad..51a5b13583 100644 --- a/Balancing/BalancingChangesManager.cs +++ b/Balancing/BalancingChangesManager.cs @@ -264,9 +264,12 @@ namespace CalamityMod.Balancing // 20% resist to Eclipse's Fall. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.AresIDs, Do(new ProjectileResistBalancingRule(0.8f, ProjectileType(), ProjectileType())))); - // 20% resist to Yharim's Crystal + // 20% resist to Yharim's Crystal. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.AresIDs, Do(new ProjectileResistBalancingRule(0.8f, ProjectileType())))); + // 20% resist to Zenith. + NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.AresIDs, Do(new ProjectileResistBalancingRule(0.8f, ProjectileID.FinalFractal)))); + // 15% resist to Enforcer projectiles. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.AresIDs, Do(new ProjectileResistBalancingRule(0.85f, ProjectileType())))); #endregion @@ -317,6 +320,9 @@ namespace CalamityMod.Balancing // 40% resist to Rancor. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.6f, ProjectileType())))); + // 40% resist to Zenith. + NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.6f, ProjectileID.FinalFractal)))); + // 30% resist to the Spin Throw part of the Ark of the Cosmos' combo. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileSpecificRequirementBalancingRule(0.7f, AotCThrowCombo)))); From 05cb3a93dc874015e1e397d3a06d6e37f22118a8 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Sun, 27 Aug 2023 17:14:37 -0400 Subject: [PATCH 058/138] Slightly toned down Thanatos' Zentih resist --- Balancing/BalancingChangesManager.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Balancing/BalancingChangesManager.cs b/Balancing/BalancingChangesManager.cs index 51a5b13583..4ba927c1db 100644 --- a/Balancing/BalancingChangesManager.cs +++ b/Balancing/BalancingChangesManager.cs @@ -320,8 +320,8 @@ namespace CalamityMod.Balancing // 40% resist to Rancor. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.6f, ProjectileType())))); - // 40% resist to Zenith. - NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.6f, ProjectileID.FinalFractal)))); + // 35% resist to Zenith. + NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileResistBalancingRule(0.65f, ProjectileID.FinalFractal)))); // 30% resist to the Spin Throw part of the Ark of the Cosmos' combo. NPCSpecificBalancingChanges.AddRange(Bundle(CalamityLists.ThanatosIDs, Do(new ProjectileSpecificRequirementBalancingRule(0.7f, AotCThrowCombo)))); From ebbef4b90d7b3a56c99a351fd7d8f32dd2e1fa6d Mon Sep 17 00:00:00 2001 From: Altixal <73398287+Altixal@users.noreply.github.com> Date: Mon, 28 Aug 2023 08:54:33 +0700 Subject: [PATCH 059/138] Eclipse's Fall glow + Lifetime restoration --- Items/Weapons/Rogue/EclipsesFall.cs | 3 +++ Items/Weapons/Rogue/EclipsesFallGlow.png | Bin 0 -> 853 bytes Projectiles/Rogue/EclipseStealthBoom.cs | 11 ++++++++++- Projectiles/Rogue/EclipseStealthBoomGlow.png | Bin 0 -> 2638 bytes Projectiles/Rogue/EclipsesFallMain.cs | 13 ++++++++++--- Projectiles/Rogue/EclipsesSmol.cs | 6 ++++++ Projectiles/Rogue/EclipsesSmolGlow.png | Bin 0 -> 1051 bytes Projectiles/Rogue/EclipsesStealth.cs | 18 +++++++++++++----- Projectiles/Rogue/UmbraphileBoom.cs | 9 +++++++++ Projectiles/Rogue/UmbraphileBoomGlow.png | Bin 0 -> 1384 bytes 10 files changed, 51 insertions(+), 9 deletions(-) create mode 100644 Items/Weapons/Rogue/EclipsesFallGlow.png create mode 100644 Projectiles/Rogue/EclipseStealthBoomGlow.png create mode 100644 Projectiles/Rogue/EclipsesSmolGlow.png create mode 100644 Projectiles/Rogue/UmbraphileBoomGlow.png diff --git a/Items/Weapons/Rogue/EclipsesFall.cs b/Items/Weapons/Rogue/EclipsesFall.cs index e352d26708..b914c5c93a 100644 --- a/Items/Weapons/Rogue/EclipsesFall.cs +++ b/Items/Weapons/Rogue/EclipsesFall.cs @@ -3,6 +3,7 @@ using CalamityMod.Projectiles.Rogue; using CalamityMod.Rarities; using CalamityMod.Tiles.Furniture.CraftingStations; using Microsoft.Xna.Framework; +using Microsoft.Xna.Framework.Graphics; using Terraria; using Terraria.DataStructures; using Terraria.ID; @@ -43,6 +44,8 @@ namespace CalamityMod.Items.Weapons.Rogue return false; } + public override void PostDrawInWorld(SpriteBatch spriteBatch, Color lightColor, Color alphaColor, float rotation, float scale, int whoAmI) => Item.DrawItemGlowmaskSingleFrame(spriteBatch, rotation, ModContent.Request(Texture + "Glow").Value); + public override void AddRecipes() { CreateRecipe(). diff --git a/Items/Weapons/Rogue/EclipsesFallGlow.png b/Items/Weapons/Rogue/EclipsesFallGlow.png new file mode 100644 index 0000000000000000000000000000000000000000..f0cd455dd537789f1ec999816ebc8c2fe1adf346 GIT binary patch literal 853 zcmV-b1FHOqP)Px#1ZP1_K>z@;j|==^1poj7OUSV9bqoCG z%w={R5K#$k_SeSlt9m$?t5%|R$r6D@8W~nA1)#o{yNmwu+~)bjpBalZ!XgDZ|4`zu zv%h{_{dC15n^b&}U*0c1*Wnm$q>*W2TcA_0?@58x& z-P7Z37TJbuiUh69|KGR$^RhJg_hJhVL5aX3TT<&^s|_d*yY9-#Pru$Ctos$E;W~M; zjbc&eyWd-GQFmYL(l1_({9|B|Ey=b>z)3es1nkNvQI;xaq;@}u=OvWMB3qJuk#d)o zvs2rZ<$Yji2Ew1~3%_c!RAP}vvMUm^Ep(zCx{uVz87a%uW}t>e8tJ@96bPZ2mpU6k zmRENMYFMO^&WnsycQ#_zZmL9Jkw$t`Wa?>7?5-?#^SW51k?f01Em58$Vm3lkyElt8 z(piyOY1;F027)XN*L`08=9cKPQ?W=RofQf4Hx}*PKW&$lrGET(=-1d2^14{0kx5>aCe?fTT$i^U>K<7Oh}qT^p)x{!-h^T)` zzh4aDuAQ4%EfH8G5fSBQ)_3O+?%Hi*iPN#jrpWT-XK`pU7HQ Lifetime) Projectile.Kill(); } + + public override void PostDraw(Color lightColor) + { + Texture2D glow = ModContent.Request(Texture + "Glow").Value; + Rectangle frame = glow.Frame(1, Main.projFrames[Type], 0, Projectile.frame); + Main.EntitySpriteDraw(glow, Projectile.Center - Main.screenPosition, frame, Color.White, Projectile.rotation, frame.Size() / 2f, Projectile.scale, SpriteEffects.None, 0); + } } } diff --git a/Projectiles/Rogue/EclipseStealthBoomGlow.png b/Projectiles/Rogue/EclipseStealthBoomGlow.png new file mode 100644 index 0000000000000000000000000000000000000000..afa3ecf883338277352408e25e1b19927d865767 GIT binary patch literal 2638 zcmcImeOQuN7N?$S%F?zJE6d!ev=CjRw5EKNv2`L4KO(>c#d=H4&qmE0L8Y0dHnFr+ z6f31tG;#s8(9~YdjA|666g5q8+gUL`fXy#P@nbJd?X%DRwg2q>=bn4s=bm%!IluEe zZ{KW@sOX5kmLkMx(mSJ#M7UtpYfk0Gb zuAV!&9D!J+!h3p>S95B@DkwUe_!PT`}yp-&{^FK zb^}W{!#&NwHnbm6er&|)unT$?b_VKLe96HRFxPSf$%d)KOo>hEG#3(kVqB$vvfX8e zlKquzxt_*dZ;?&bLu%@A?@{Dq>JzOWYo4y~SMRbD#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, Projectile.rotation, glow.Size() / 2f, Projectile.scale, SpriteEffects.None, 0); + } } } diff --git a/Projectiles/Rogue/EclipsesSmol.cs b/Projectiles/Rogue/EclipsesSmol.cs index a4073c7426..1000f9603e 100644 --- a/Projectiles/Rogue/EclipsesSmol.cs +++ b/Projectiles/Rogue/EclipsesSmol.cs @@ -32,5 +32,11 @@ namespace CalamityMod.Projectiles.Rogue Main.EntitySpriteDraw(tex, Projectile.Center - Main.screenPosition, null, Projectile.GetAlpha(lightColor), Projectile.rotation, tex.Size() / 2f, Projectile.scale, SpriteEffects.None, 0); return false; } + + public override void PostDraw(Color lightColor) + { + Texture2D glow = ModContent.Request(Texture + "Glow").Value; + Main.EntitySpriteDraw(glow, Projectile.Center - Main.screenPosition, null, Color.White, Projectile.rotation, glow.Size() / 2f, Projectile.scale, SpriteEffects.None, 0); + } } } diff --git a/Projectiles/Rogue/EclipsesSmolGlow.png b/Projectiles/Rogue/EclipsesSmolGlow.png new file mode 100644 index 0000000000000000000000000000000000000000..0539d70e6469945b44ba29e387a03a66091967d2 GIT binary patch literal 1051 zcmV+$1mydPP)Px#1ZP1_K>z@;j|==^1poj8t4TybRCr$Pnk{b?K@^62YY86-8Uva?fT2iAFo;rv zAt4wP2olhcU{DxBg26Nu7(y#4hChG?gC+qQEQOu)Y3N%H^X}f+_NF~g($2kecXu{B zPtG|zyK_m>l*x8Gb1dCm+uHtESbe&K@Wt_|B&X(`TFB~iF{H3*BL@_5S=mV6<|Aef5kNjCV%K!_FI1WC5@VfW=2KX3FxQN z)$N)2%@03ItNTYLVZzdl^X0pmv$b)hv|1Md=TS2?jWTI&6fi?-PGl5d*7BP>rHy7< zW1GS_829?r^RC%*Ue~_e?wT+*K^kT9->W!;$P~?5Y6K=h&8P@9i1S$g^trV3gM0im z%A~nbQC*~Hwga-(kH-t81-8@d#duMcjZDU{T5N(e%49U7v@QZ>SdEG*XUt;1m8;K6 zi&?}(`WcU`2WqOEeJvD|(Sxr0fU}O8!ZrC2khFbrqSsKfJy<055ufF)j(sBnnc~hDuHIb zT7}Jd_04vWMwv7-Dl$n?v#67_?$SydV>I>+HKZ?Tl*!byq4f(yF-fzTR_amZ&h~1M z8>6NrjWTI&R4uy!&(ZWA4YcmUM9p?;;#g*-Q6|-^&&+|&m}Wb-UcwCa*NQvJj?_~; zw_`td?RzL`l!IX5PxQG|I%j%4(LzBsBoE z4$>Hd5yUE>A4Al<$T0d_XTLPcr1w=-M2|x^PuncE@_lWbEC9=(rnZ>ri^7sU(zU(=Cgz` zdQTTIE5_7FqfDlrMa^nstyv#5X_U#-7pgO<`|Gk8nd~r;t4G5 z*OS;;Cyg@Mv4pkmH0a-?QAu(D%+37<=V5@&?!?X10000EWmrjOO-%qQ0000800000 V0002eQ(Texture + "Glow").Value; + Main.EntitySpriteDraw(glow, Projectile.Center - Main.screenPosition, null, Color.White, Projectile.rotation, glow.Size() / 2f, Projectile.scale, SpriteEffects.None, 0); + } + public override bool? CanHitNPC(NPC target) => Projectile.ai[0] == 1f ? false : base.CanHitNPC(target); public override bool CanHitPvp(Player target) => Projectile.ai[0] != 1f; diff --git a/Projectiles/Rogue/UmbraphileBoom.cs b/Projectiles/Rogue/UmbraphileBoom.cs index 86ae946f4e..fb9924cd18 100644 --- a/Projectiles/Rogue/UmbraphileBoom.cs +++ b/Projectiles/Rogue/UmbraphileBoom.cs @@ -1,4 +1,6 @@ using CalamityMod.Buffs.DamageOverTime; +using Microsoft.Xna.Framework; +using Microsoft.Xna.Framework.Graphics; using Terraria; using Terraria.ID; using Terraria.ModLoader; @@ -54,5 +56,12 @@ namespace CalamityMod.Projectiles.Rogue if (!Main.dayTime || Main.rand.NextBool(3)) //100% at night, 33.33% chance during day target.AddBuff(ModContent.BuffType(), 45); } + + public override void PostDraw(Color lightColor) + { + Texture2D glow = ModContent.Request(Texture + "Glow").Value; + Rectangle frame = glow.Frame(1, Main.projFrames[Type], 0, Projectile.frame); + Main.EntitySpriteDraw(glow, Projectile.Center - Main.screenPosition, frame, Color.White, Projectile.rotation, frame.Size() / 2f, Projectile.scale, SpriteEffects.None, 0); + } } } diff --git a/Projectiles/Rogue/UmbraphileBoomGlow.png b/Projectiles/Rogue/UmbraphileBoomGlow.png new file mode 100644 index 0000000000000000000000000000000000000000..b4c9459bddd0198f96f603f17396026e5799385a GIT binary patch literal 1384 zcmZ`(dr*=I5dZ4zdU)6!rI)686=|a<)G1;ib}FExSg2nlKJv=bbrmH_~g3R|M zyk~HF#Nt$Ejy3o-=Vf?R5#g~i@3~nBo}TeVRL*x7|1SO+*!M#s;OkU0l6MhfmPgPS z$}0V69zwAo;FG^mzv5e7rkKO-cTRF|7(_fyOdST;Cb;F~ng-l9Lvt7d(A zLvQ^nl(J~*8=T-Ik54G+L9|Oa;>oc+?$@orpgwu+pndoDzS3jeyK)4yQVt%cP>sU_ zi;CA(exrG@kqsPiMTbkN+L*kbazf{35%Oqm!^94+u(*~!#HN(nJHi=NdvEbrl*Cw_TPhtP zU{PVAp7lb$vU{PmQg>6uim_(?O6}Q=5mH?ot*Y3=e*9i~a*fG&QZYW9ZHqDIZUg{p z8Iros*q|u7a`xh7p-o7xRw}JqntSZA(!k4rD^2T2=N`rRrl4wFAK966170g~?2kt| zzzyyzZ$4g~Dg5wy@E&I-%xEFy9pbWF=kLRgr*kw?`tlmpOQF^+xM5aAGz%X%ZFXiwN zigVh9_|Eya<0wvf7M_rf=0|lpPO`Uq-@d<(@-hOZL-x0UD;o*?SLMP#vCEywg93Wv z1VXw5m#Pl5xu7QK*EH!|T7n2HU|{|EfOxT%^-QAQz1i&P{OCyl_~_)}e6!1Y=s70x zZd>=(`E=}8V0+6s_R$HGCcQ+~@s{X2HnTXowmN6*xgW7D3_mL^RLlL=6QZM(K=-H!HTh z*%BBMXy_QL_F)9g{t>YlQWrhjOUYhNL**!}Ci90XC(@HAR35)rp-Zk|HcOug6lE=5 zcO|YcE|Hr~of6uv8CA$KEmDJh@GX~!iyAg&qAA&P+E-%;7&p4FBVH;i{H+U_s(}XG z5!FOZLdvn>YOUh-CX3R>1+e;9$SH>;|+K1Wh5ip2%WgB@7b3s)+0sD$F9KG{F+K zg7d2$W9m~;47BD7DTSdAI!54^D_xqi@2E14T*pHsf@nsjI#k`RQ}!TA_V_S4jqj9> zDz^bvaK-M){94iaonRYk4TUMd4mDqRxKqdg;b2LuuCQ+Ou*8^w5Hz0}qV)$5_yc}p z@wgDU0nf&i1=$DizpvH-D)<+X2myGJSLC&S05t}Y8~^|S literal 0 HcmV?d00001 From 11a8771afc7407a94c593664d72497f26a5a973d Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Sun, 27 Aug 2023 22:24:49 -0400 Subject: [PATCH 060/138] sponge recharge time 6s -> 9s --- Items/Accessories/TheSponge.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Accessories/TheSponge.cs b/Items/Accessories/TheSponge.cs index b9f75fbe5d..99a96e5c64 100644 --- a/Items/Accessories/TheSponge.cs +++ b/Items/Accessories/TheSponge.cs @@ -30,7 +30,7 @@ namespace CalamityMod.Items.Accessories public static readonly SoundStyle BreakSound = new("CalamityMod/Sounds/Custom/RoverDriveBreak") { Volume = 0.75f }; public static int ShieldDurabilityMax = 180; - public static int ShieldRechargeDelay = CalamityUtils.SecondsToFrames(6); + public static int ShieldRechargeDelay = CalamityUtils.SecondsToFrames(9); // was 6 public static int TotalShieldRechargeTime = CalamityUtils.SecondsToFrames(6); // While active, The Sponge gives 30 defense and 30% DR From 2d019ed2386b2bb4bc79835ce7bba897e8e4c2f1 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Sun, 27 Aug 2023 21:04:05 -0600 Subject: [PATCH 061/138] Made Plasma Grenade flashier and nerfed its values a bit before I start more rigourous testing. --- Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs | 9 +++------ .../DraedonsArsenal/PlasmaGrenadeProjectile.cs | 17 ++++++++++------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs b/Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs index f25fbec3e2..96a00c9a1d 100644 --- a/Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs +++ b/Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs @@ -26,7 +26,7 @@ namespace CalamityMod.Items.Weapons.DraedonsArsenal Item.width = 22; Item.height = 28; - Item.damage = 1378; + Item.damage = 1000; Item.noMelee = true; Item.noUseGraphic = true; Item.consumable = false; @@ -40,19 +40,16 @@ namespace CalamityMod.Items.Weapons.DraedonsArsenal Item.rare = ModContent.RarityType(); Item.shoot = ModContent.ProjectileType(); - Item.shootSpeed = 14f; + Item.shootSpeed = 10f; Item.DamageType = RogueDamageClass.Instance; modItem.UsesCharge = true; modItem.MaxCharge = 250f; - modItem.ChargePerUse = 0.2f; + modItem.ChargePerUse = 0.25f; } public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) { - if (player.Calamity().StealthStrikeAvailable()) - damage = (int)(damage * 1.05); - int proj = Projectile.NewProjectile(source, position, velocity, type, damage, knockback, player.whoAmI); if (proj.WithinBounds(Main.maxProjectiles)) Main.projectile[proj].Calamity().stealthStrike = player.Calamity().StealthStrikeAvailable(); diff --git a/Projectiles/DraedonsArsenal/PlasmaGrenadeProjectile.cs b/Projectiles/DraedonsArsenal/PlasmaGrenadeProjectile.cs index cdff65ad8e..9f24c66d94 100644 --- a/Projectiles/DraedonsArsenal/PlasmaGrenadeProjectile.cs +++ b/Projectiles/DraedonsArsenal/PlasmaGrenadeProjectile.cs @@ -4,6 +4,7 @@ using Terraria; using Terraria.ModLoader; using Terraria.Audio; using CalamityMod.Items.Weapons.DraedonsArsenal; +using CalamityMod.Particles; namespace CalamityMod.Projectiles.DraedonsArsenal { @@ -13,6 +14,7 @@ namespace CalamityMod.Projectiles.DraedonsArsenal public override string Texture => "CalamityMod/Items/Weapons/DraedonsArsenal/PlasmaGrenade"; private static readonly float Gravity = 0.09f; + private float rotate = Main.rand.Next(360); public float Time { @@ -26,27 +28,28 @@ namespace CalamityMod.Projectiles.DraedonsArsenal Projectile.height = 28; Projectile.friendly = true; Projectile.penetrate = 1; - Projectile.timeLeft = 300; + Projectile.timeLeft = 450; Projectile.MaxUpdates = 2; Projectile.DamageType = RogueDamageClass.Instance; } public override void AI() { - Projectile.rotation = Projectile.velocity.ToRotation() + MathHelper.PiOver2; + Projectile.rotation = Projectile.velocity.ToRotation() + MathHelper.ToRadians(rotate); Vector2 projectileTop = Projectile.Center + new Vector2(0f, Projectile.height * -0.5f).RotatedBy(Projectile.rotation); if (Time > 10f) Projectile.velocity.Y += Gravity; - if (!Main.dedServ) + if (!Main.dedServ && Main.rand.NextBool()) // 50% chance to spawn smoke { - Dust dust = Dust.NewDustPerfect(projectileTop, 107); - dust.velocity = Projectile.rotation.ToRotationVector2().RotatedByRandom(0.35f) * Main.rand.NextFloat(2f, 4f); - dust.velocity += Projectile.velocity * 0.25f; - dust.scale = Main.rand.NextFloat(0.95f, 1.3f); + Color plasmaLime = Color.Lerp(Color.Lime, Color.LimeGreen, Main.rand.NextFloat(1f)); + Color fadeColor = Color.Lerp(Color.LightGreen, plasmaLime, Main.rand.NextFloat(0.5f,1f)); + Particle plasma = new SmallSmokeParticle(projectileTop, Projectile.oldVelocity*0.7f, Color.LightGreen, fadeColor, Main.rand.NextFloat(0.4f,0.9f), 100f); + GeneralParticleHandler.SpawnParticle(plasma); } Time++; + rotate += 10; } public override void Kill(int timeLeft) From bdde8f8b4fbb3231d54472cb4148636c4cb4c527 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Sun, 27 Aug 2023 22:57:36 -0600 Subject: [PATCH 062/138] Plasma Grenade fucking dies Buffed Nanotech's flare dmg a little to better compete with Venerated Locket's knives (even post-nerf they are batshit insane) Nerfed Ven Locket's knives AGAIN --- CalPlayer/CalamityPlayer.cs | 2 +- CalPlayer/CalamityPlayerOnHit.cs | 2 +- Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs | 6 +++++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index 4831150314..99a0003650 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -3979,7 +3979,7 @@ namespace CalamityMod.CalPlayer if (StealthStrikeAvailable()) { int knifeCount = 12; - int knifeDamage = (int)Player.GetTotalDamage().ApplyTo(75); + int knifeDamage = (int)Player.GetTotalDamage().ApplyTo(70); float angleStep = MathHelper.TwoPi / knifeCount; float speed = 15f; diff --git a/CalPlayer/CalamityPlayerOnHit.cs b/CalPlayer/CalamityPlayerOnHit.cs index c47b1dddc8..6a85e5abc7 100644 --- a/CalPlayer/CalamityPlayerOnHit.cs +++ b/CalPlayer/CalamityPlayerOnHit.cs @@ -840,7 +840,7 @@ namespace CalamityMod.CalPlayer { Vector2 source = new Vector2(position.X + Main.rand.Next(-201, 201), Main.screenPosition.Y - 600f - Main.rand.Next(50)); Vector2 velocity = (position - source) / 40f; - int damage = (int)Player.GetTotalDamage().ApplyTo(120); + int damage = (int)Player.GetTotalDamage().ApplyTo(125); Projectile.NewProjectile(spawnSource, source, velocity, ProjectileType(), damage, 3f, proj.owner); } } diff --git a/Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs b/Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs index 96a00c9a1d..f575b6ff3e 100644 --- a/Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs +++ b/Items/Weapons/DraedonsArsenal/PlasmaGrenade.cs @@ -40,7 +40,7 @@ namespace CalamityMod.Items.Weapons.DraedonsArsenal Item.rare = ModContent.RarityType(); Item.shoot = ModContent.ProjectileType(); - Item.shootSpeed = 10f; + Item.shootSpeed = 11f; Item.DamageType = RogueDamageClass.Instance; modItem.UsesCharge = true; @@ -48,6 +48,10 @@ namespace CalamityMod.Items.Weapons.DraedonsArsenal modItem.ChargePerUse = 0.25f; } + public override float StealthDamageMultiplier => 1.2f; + public override float StealthVelocityMultiplier => 1.2f; + public override float StealthKnockbackMultiplier => 1.5f; + public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) { int proj = Projectile.NewProjectile(source, position, velocity, type, damage, knockback, player.whoAmI); From 4e97e7a6b1db8c22b8268de0a48d3e7b749509cb Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Sun, 27 Aug 2023 23:06:25 -0600 Subject: [PATCH 063/138] Fixed Shattered Community's level up text being missing --- Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 1 + 1 file changed, 1 insertion(+) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 3684dd87d1..3e74abd574 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -1490,6 +1490,7 @@ ShatteredCommunity: { When Rage is maxed, press {0} for a temporary damage boost ''' RageModified: You generate rage over time and rage does not fade out of combat + LevelUpText: Level Up! } ShieldoftheHighRuler: { From 2e6e5d5213a4c45d32b87aba256a65ecbc4e15d9 Mon Sep 17 00:00:00 2001 From: Done2222 <125043478+Done2222@users.noreply.github.com> Date: Mon, 28 Aug 2023 15:43:00 +0300 Subject: [PATCH 064/138] Onyx Chain Blaster buff 40 - 51 damage --- Items/Weapons/Ranged/OnyxChainBlaster.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/OnyxChainBlaster.cs b/Items/Weapons/Ranged/OnyxChainBlaster.cs index 21f3abf073..e155ee4dd2 100644 --- a/Items/Weapons/Ranged/OnyxChainBlaster.cs +++ b/Items/Weapons/Ranged/OnyxChainBlaster.cs @@ -11,7 +11,7 @@ namespace CalamityMod.Items.Weapons.Ranged public new string LocalizationCategory => "Items.Weapons.Ranged"; public override void SetDefaults() { - Item.damage = 40; + Item.damage = 51; Item.DamageType = DamageClass.Ranged; Item.width = 64; Item.height = 32; From ce8f30068aba8eba0afebb136fac7e5f15d6ddfc Mon Sep 17 00:00:00 2001 From: Done2222 <125043478+Done2222@users.noreply.github.com> Date: Mon, 28 Aug 2023 15:44:17 +0300 Subject: [PATCH 065/138] Monsoon buff 121 -> 152 --- Items/Weapons/Ranged/Monsoon.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/Monsoon.cs b/Items/Weapons/Ranged/Monsoon.cs index 1c4d7c7388..66559fea56 100644 --- a/Items/Weapons/Ranged/Monsoon.cs +++ b/Items/Weapons/Ranged/Monsoon.cs @@ -15,7 +15,7 @@ namespace CalamityMod.Items.Weapons.Ranged public new string LocalizationCategory => "Items.Weapons.Ranged"; public override void SetDefaults() { - Item.damage = 121; + Item.damage = 152; Item.DamageType = DamageClass.Ranged; Item.width = 46; Item.height = 78; From fcbc6441a1730ae65182abf6ea2d1e9d4f137282 Mon Sep 17 00:00:00 2001 From: Done2222 <125043478+Done2222@users.noreply.github.com> Date: Mon, 28 Aug 2023 15:45:00 +0300 Subject: [PATCH 066/138] Elemental Blaster buff 55 -> 67 --- Items/Weapons/Ranged/ElementalBlaster.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/ElementalBlaster.cs b/Items/Weapons/Ranged/ElementalBlaster.cs index 8265d0d556..fab5898e68 100644 --- a/Items/Weapons/Ranged/ElementalBlaster.cs +++ b/Items/Weapons/Ranged/ElementalBlaster.cs @@ -12,7 +12,7 @@ namespace CalamityMod.Items.Weapons.Ranged public new string LocalizationCategory => "Items.Weapons.Ranged"; public override void SetDefaults() { - Item.damage = 55; + Item.damage = 67; Item.DamageType = DamageClass.Ranged; Item.width = 104; Item.height = 42; From 1e699eab07c9fe93b6d9aa97da3e8477151a2566 Mon Sep 17 00:00:00 2001 From: Done2222 <125043478+Done2222@users.noreply.github.com> Date: Mon, 28 Aug 2023 15:46:00 +0300 Subject: [PATCH 067/138] Dodu's Handcannon buff 857 -> 1020 --- Items/Weapons/Ranged/DodusHandcannon.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/DodusHandcannon.cs b/Items/Weapons/Ranged/DodusHandcannon.cs index 98aae42a20..103e91d86f 100644 --- a/Items/Weapons/Ranged/DodusHandcannon.cs +++ b/Items/Weapons/Ranged/DodusHandcannon.cs @@ -16,7 +16,7 @@ namespace CalamityMod.Items.Weapons.Ranged { Item.width = 62; Item.height = 34; - Item.damage = 857; + Item.damage = 1020; Item.DamageType = DamageClass.Ranged; Item.useTime = 30; Item.useAnimation = 30; From cd523eb74cc3e84662ef4d5cbbbe03702a601331 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 09:26:50 -0400 Subject: [PATCH 068/138] Nebulash and Void Vortex balance --- Items/Weapons/Magic/VoidVortex.cs | 4 ++-- Items/Weapons/Melee/Nebulash.cs | 2 +- Projectiles/Melee/NebulashFlail.cs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Items/Weapons/Magic/VoidVortex.cs b/Items/Weapons/Magic/VoidVortex.cs index fdc6183b87..db4a6bd179 100644 --- a/Items/Weapons/Magic/VoidVortex.cs +++ b/Items/Weapons/Magic/VoidVortex.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Magic public class VoidVortex : ModItem, ILocalizedModType { public new string LocalizationCategory => "Items.Weapons.Magic"; - public const int OrbFireRate = 16; + public const int OrbFireRate = 20; public override void SetStaticDefaults() { @@ -22,7 +22,7 @@ namespace CalamityMod.Items.Weapons.Magic public override void SetDefaults() { - Item.damage = 112; + Item.damage = 106; Item.DamageType = DamageClass.Magic; Item.mana = 60; Item.width = 130; diff --git a/Items/Weapons/Melee/Nebulash.cs b/Items/Weapons/Melee/Nebulash.cs index f677385279..af58c393d6 100644 --- a/Items/Weapons/Melee/Nebulash.cs +++ b/Items/Weapons/Melee/Nebulash.cs @@ -14,7 +14,7 @@ namespace CalamityMod.Items.Weapons.Melee { Item.width = 16; Item.height = 16; - Item.damage = 60; + Item.damage = 78; Item.rare = ItemRarityID.Lime; Item.noMelee = true; Item.noUseGraphic = true; diff --git a/Projectiles/Melee/NebulashFlail.cs b/Projectiles/Melee/NebulashFlail.cs index 0ad290be47..f8a50b26ca 100644 --- a/Projectiles/Melee/NebulashFlail.cs +++ b/Projectiles/Melee/NebulashFlail.cs @@ -21,7 +21,7 @@ namespace CalamityMod.Projectiles.Melee Projectile.DamageType = DamageClass.MeleeNoSpeed; Projectile.ignoreWater = true; Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = 3; + Projectile.localNPCHitCooldown = 2; } public override Color SpecialDrawColor => new(255, 200, 0); public override int ExudeDustType => ModContent.DustType(); From 04e3f30eaa68693313342d6a8d6805d0afe94002 Mon Sep 17 00:00:00 2001 From: Altixal <73398287+Altixal@users.noreply.github.com> Date: Mon, 28 Aug 2023 21:28:29 +0700 Subject: [PATCH 069/138] Shattered Community text as it should be --- Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 3e74abd574..b897a532f0 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -1490,7 +1490,7 @@ ShatteredCommunity: { When Rage is maxed, press {0} for a temporary damage boost ''' RageModified: You generate rage over time and rage does not fade out of combat - LevelUpText: Level Up! + LevelUpText: The Community cracks... } ShieldoftheHighRuler: { From 7adbb470f805774c93473354bbd58ec049c493e0 Mon Sep 17 00:00:00 2001 From: AquaSG Date: Mon, 28 Aug 2023 10:53:22 -0400 Subject: [PATCH 070/138] coral spout and titanium railgun visual fix --- Projectiles/Magic/CoralSpoutHoldout.cs | 2 +- Projectiles/Ranged/TitaniumRailgunScope.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Projectiles/Magic/CoralSpoutHoldout.cs b/Projectiles/Magic/CoralSpoutHoldout.cs index 2c22646cb4..7ad3a1471c 100644 --- a/Projectiles/Magic/CoralSpoutHoldout.cs +++ b/Projectiles/Magic/CoralSpoutHoldout.cs @@ -106,7 +106,7 @@ namespace CalamityMod.Projectiles.Magic Main.EntitySpriteDraw(texture, Owner.MountedCenter - Main.screenPosition, null, Color.White, angle, new Vector2(texture.Width / 2f, texture.Height/2f), 700f, 0, 0); Main.spriteBatch.End(); - Main.spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend, Main.DefaultSamplerState, DepthStencilState.None, Main.Rasterizer, null, Main.GameViewMatrix.TransformationMatrix); + Main.spriteBatch.Begin(SpriteSortMode.Immediate, BlendState.AlphaBlend, Main.DefaultSamplerState, DepthStencilState.None, Main.Rasterizer, null, Main.GameViewMatrix.TransformationMatrix); return false; } diff --git a/Projectiles/Ranged/TitaniumRailgunScope.cs b/Projectiles/Ranged/TitaniumRailgunScope.cs index b2bea7ff0a..ca386ce464 100644 --- a/Projectiles/Ranged/TitaniumRailgunScope.cs +++ b/Projectiles/Ranged/TitaniumRailgunScope.cs @@ -215,7 +215,7 @@ namespace CalamityMod.Projectiles.Ranged Main.spriteBatch.End(); - Main.spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend, Main.DefaultSamplerState, DepthStencilState.None, Main.Rasterizer, null, Main.GameViewMatrix.TransformationMatrix); + Main.spriteBatch.Begin(SpriteSortMode.Immediate, BlendState.AlphaBlend, Main.DefaultSamplerState, DepthStencilState.None, Main.Rasterizer, null, Main.GameViewMatrix.TransformationMatrix); return false; } From faa5a3e5b1e3ab7c705ceb7372faea8cc6735ce7 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 12:10:12 -0400 Subject: [PATCH 071/138] Stormjaw Staff damage buff (and increased their speed I think) --- Items/Weapons/Summon/StormjawStaff.cs | 2 +- Projectiles/Summon/StormjawBaby.cs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Summon/StormjawStaff.cs b/Items/Weapons/Summon/StormjawStaff.cs index 28e74b34be..f32049a30c 100644 --- a/Items/Weapons/Summon/StormjawStaff.cs +++ b/Items/Weapons/Summon/StormjawStaff.cs @@ -12,7 +12,7 @@ namespace CalamityMod.Items.Weapons.Summon public new string LocalizationCategory => "Items.Weapons.Summon"; public override void SetDefaults() { - Item.damage = 8; + Item.damage = 11; Item.mana = 10; Item.width = 32; Item.height = 32; diff --git a/Projectiles/Summon/StormjawBaby.cs b/Projectiles/Summon/StormjawBaby.cs index 2754293e9f..59de3bd778 100644 --- a/Projectiles/Summon/StormjawBaby.cs +++ b/Projectiles/Summon/StormjawBaby.cs @@ -414,8 +414,8 @@ namespace CalamityMod.Projectiles.Summon { Projectile.tileCollide = true; float accelFast = 0.5f; - float maxSpeed = 4f; - float xVel = 4f; + float maxSpeed = 7f; + float xVel = 7f; float accelSlow = 0.1f; if (xVel < Math.Abs(player.velocity.X) + Math.Abs(player.velocity.Y)) { From 85eee39f8c5533f546d77154c2bc2f63c68592a8 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 12:16:46 -0400 Subject: [PATCH 072/138] Slight Stormjaw speed changes --- Projectiles/Summon/StormjawBaby.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Projectiles/Summon/StormjawBaby.cs b/Projectiles/Summon/StormjawBaby.cs index 59de3bd778..efae266e98 100644 --- a/Projectiles/Summon/StormjawBaby.cs +++ b/Projectiles/Summon/StormjawBaby.cs @@ -413,14 +413,14 @@ namespace CalamityMod.Projectiles.Summon if (Projectile.ai[0] == 0f) { Projectile.tileCollide = true; - float accelFast = 0.5f; - float maxSpeed = 7f; - float xVel = 7f; - float accelSlow = 0.1f; + float accelFast = 1f; + float maxSpeed = 8f; + float xVel = 8f; + float accelSlow = 0.2f; if (xVel < Math.Abs(player.velocity.X) + Math.Abs(player.velocity.Y)) { xVel = Math.Abs(player.velocity.X) + Math.Abs(player.velocity.Y); - accelFast = 0.7f; + accelFast = 1.4f; } int direction = 0; bool flag3 = false; From 5dc47f4f1e86305d9782d8eb7f907fbb2a87b0e2 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 12:26:33 -0400 Subject: [PATCH 073/138] Why is the separation anxiety distance shorter than its attack distance??? --- Projectiles/Summon/StormjawBaby.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Projectiles/Summon/StormjawBaby.cs b/Projectiles/Summon/StormjawBaby.cs index efae266e98..13700aca1f 100644 --- a/Projectiles/Summon/StormjawBaby.cs +++ b/Projectiles/Summon/StormjawBaby.cs @@ -393,7 +393,7 @@ namespace CalamityMod.Projectiles.Summon if (sparkCounter < 0) sparkCounter = 0; - float sepAnxietyDist = 500f; + float sepAnxietyDist = 1000f; Vector2 playerDist = player.Center - Projectile.Center; // Teleport to the player if too far if (playerDist.Length() > 2000f) From 4c6a3e7d0269e486a6e5e28e16b67f1946530aa2 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 13:42:42 -0400 Subject: [PATCH 074/138] Watch this make the mod not compile lmao --- Items/Weapons/Ranged/ArterialAssault.cs | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index c7284e7030..72bc279c27 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -76,16 +76,10 @@ namespace CalamityMod.Items.Weapons.Ranged num79 *= num80; float speedX4 = num78; float speedY5 = num79; - if (CalamityUtils.CheckWoodenAmmo(type, player)) - { - int bloodfire = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, ModContent.ProjectileType(), damage, knockback, player.whoAmI, 0f, 80f); - Main.projectile[bloodfire].tileCollide = false; - } - else - { - int num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); - Main.projectile[num121].noDropItem = true; - } + int num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); + Main.projectile[num121].noDropItem = true; + Main.projectile[num121].tileCollide = false; + CalamityUtils.HomeInOnNPC(num121, !num121.tileCollide, 200f, 12f, 20f); return false; } From b57bc63c65917c9ec98179ab4febd05bc117c7b6 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 13:43:42 -0400 Subject: [PATCH 075/138] Damn. --- Items/Weapons/Ranged/ArterialAssault.cs | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index 72bc279c27..c7284e7030 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -76,10 +76,16 @@ namespace CalamityMod.Items.Weapons.Ranged num79 *= num80; float speedX4 = num78; float speedY5 = num79; - int num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); - Main.projectile[num121].noDropItem = true; - Main.projectile[num121].tileCollide = false; - CalamityUtils.HomeInOnNPC(num121, !num121.tileCollide, 200f, 12f, 20f); + if (CalamityUtils.CheckWoodenAmmo(type, player)) + { + int bloodfire = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, ModContent.ProjectileType(), damage, knockback, player.whoAmI, 0f, 80f); + Main.projectile[bloodfire].tileCollide = false; + } + else + { + int num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); + Main.projectile[num121].noDropItem = true; + } return false; } From 857bf0f82a62ba708fc9948557e5d3d4b84a465a Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 16:43:43 -0400 Subject: [PATCH 076/138] Attempt 2 at making Arterial Assault grant full homing? --- Items/Weapons/Ranged/ArterialAssault.cs | 15 +++++---------- Projectiles/CalamityGlobalProjectile.cs | 8 ++++++++ 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index c7284e7030..d23b0eff1f 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -76,16 +76,11 @@ namespace CalamityMod.Items.Weapons.Ranged num79 *= num80; float speedX4 = num78; float speedY5 = num79; - if (CalamityUtils.CheckWoodenAmmo(type, player)) - { - int bloodfire = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, ModContent.ProjectileType(), damage, knockback, player.whoAmI, 0f, 80f); - Main.projectile[bloodfire].tileCollide = false; - } - else - { - int num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); - Main.projectile[num121].noDropItem = true; - } + Projectile num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); + Main.projectile[num121].noDropItem = true; + Main.projectile[num121].tileCollide = false; + CalamityGlobalProjectile cgp = num121.Calamity(); + cgp.allProjectilesHome = true; return false; } diff --git a/Projectiles/CalamityGlobalProjectile.cs b/Projectiles/CalamityGlobalProjectile.cs index 2268b521e7..c4e325877c 100644 --- a/Projectiles/CalamityGlobalProjectile.cs +++ b/Projectiles/CalamityGlobalProjectile.cs @@ -74,6 +74,9 @@ namespace CalamityMod.Projectiles // If true, this projectile creates impact sparks upon hitting enemies public bool deepcoreBullet = false; + // If true, causes all projectiles fired by this weapon to have homing. Currently used for Arterial Assault. + public bool allProjectilesHome = false; + // Amount of extra updates that are set in SetDefaults. public int defExtraUpdates = -1; @@ -2488,6 +2491,11 @@ namespace CalamityMod.Projectiles confetti.velocity.Y += Main.rand.Next(-50, 51) * 0.05f; } } + + if (allProjectilesHome) + { + CalamityUtils.HomeInOnNPC(projectile, !projectile.tileCollide, 300f, 12f, 20f); + } } } #endregion From c07b1ddd65c27563d622396b5ff944119914df67 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 16:45:43 -0400 Subject: [PATCH 077/138] Comment --- Items/Weapons/Ranged/ArterialAssault.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index d23b0eff1f..e413216458 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -76,7 +76,7 @@ namespace CalamityMod.Items.Weapons.Ranged num79 *= num80; float speedX4 = num78; float speedY5 = num79; - Projectile num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); + int num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); Main.projectile[num121].noDropItem = true; Main.projectile[num121].tileCollide = false; CalamityGlobalProjectile cgp = num121.Calamity(); From 4dd8ec6c1f93dd6c4f63dbca7b420b3835fa1ba9 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 16:47:13 -0400 Subject: [PATCH 078/138] clueless --- Items/Weapons/Ranged/ArterialAssault.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index e413216458..3044393e3a 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -1,5 +1,5 @@ using CalamityMod.Items.Materials; -using CalamityMod.Projectiles.Ranged; +using CalamityMod.Projectiles; using CalamityMod.Rarities; using Microsoft.Xna.Framework; using System; From 27a8b50e85975af840c31394268c9b86d98ca1cf Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 16:49:22 -0400 Subject: [PATCH 079/138] Insanity --- Items/Weapons/Ranged/ArterialAssault.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index 3044393e3a..57bf8dc90e 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -30,7 +30,7 @@ namespace CalamityMod.Items.Weapons.Ranged Item.rare = ModContent.RarityType(); Item.UseSound = SoundID.Item102; Item.autoReuse = true; - Item.shoot = ModContent.ProjectileType(); + Item.shoot = ProjectileID.WoodenArrowFriendly; Item.shootSpeed = 30f; Item.useAmmo = AmmoID.Arrow; } From 8ff72a22faecb5ba612badfca8c70339a98c45eb Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 16:51:34 -0400 Subject: [PATCH 080/138] Trying again --- Items/Weapons/Ranged/ArterialAssault.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index 57bf8dc90e..ac2e188404 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -76,7 +76,7 @@ namespace CalamityMod.Items.Weapons.Ranged num79 *= num80; float speedX4 = num78; float speedY5 = num79; - int num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); + Projectile num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); Main.projectile[num121].noDropItem = true; Main.projectile[num121].tileCollide = false; CalamityGlobalProjectile cgp = num121.Calamity(); From ae1277abbf0c6660f2a49f663ef6e4f885ffa5b2 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 16:53:28 -0400 Subject: [PATCH 081/138] Man --- Items/Weapons/Ranged/ArterialAssault.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index ac2e188404..eced1dcf9c 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -76,7 +76,7 @@ namespace CalamityMod.Items.Weapons.Ranged num79 *= num80; float speedX4 = num78; float speedY5 = num79; - Projectile num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); + Projectile num121 = Projectile.NewProjectileDirect(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); Main.projectile[num121].noDropItem = true; Main.projectile[num121].tileCollide = false; CalamityGlobalProjectile cgp = num121.Calamity(); From 01902f2525add6aa4a22e2780378cfa50804ace6 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 16:57:32 -0400 Subject: [PATCH 082/138] Yeah okay I will step back from trying to do this :XD: --- Items/Weapons/Ranged/ArterialAssault.cs | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/Items/Weapons/Ranged/ArterialAssault.cs b/Items/Weapons/Ranged/ArterialAssault.cs index eced1dcf9c..9bd1950f75 100644 --- a/Items/Weapons/Ranged/ArterialAssault.cs +++ b/Items/Weapons/Ranged/ArterialAssault.cs @@ -1,5 +1,5 @@ -using CalamityMod.Items.Materials; -using CalamityMod.Projectiles; +using CalamityMod.Items.Materials; +using CalamityMod.Projectiles.Ranged; using CalamityMod.Rarities; using Microsoft.Xna.Framework; using System; @@ -30,7 +30,7 @@ namespace CalamityMod.Items.Weapons.Ranged Item.rare = ModContent.RarityType(); Item.UseSound = SoundID.Item102; Item.autoReuse = true; - Item.shoot = ProjectileID.WoodenArrowFriendly; + Item.shoot = ModContent.ProjectileType(); Item.shootSpeed = 30f; Item.useAmmo = AmmoID.Arrow; } @@ -76,11 +76,16 @@ namespace CalamityMod.Items.Weapons.Ranged num79 *= num80; float speedX4 = num78; float speedY5 = num79; - Projectile num121 = Projectile.NewProjectileDirect(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); - Main.projectile[num121].noDropItem = true; - Main.projectile[num121].tileCollide = false; - CalamityGlobalProjectile cgp = num121.Calamity(); - cgp.allProjectilesHome = true; + if (CalamityUtils.CheckWoodenAmmo(type, player)) + { + int bloodfire = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, ModContent.ProjectileType(), damage, knockback, player.whoAmI, 0f, 80f); + Main.projectile[bloodfire].tileCollide = false; + } + else + { + int num121 = Projectile.NewProjectile(source, vector2.X, vector2.Y, speedX4, speedY5, type, damage, knockback, player.whoAmI); + Main.projectile[num121].noDropItem = true; + } return false; } @@ -92,4 +97,4 @@ namespace CalamityMod.Items.Weapons.Ranged Register(); } } -} +} \ No newline at end of file From bf709c388b449969fcb443685f9ee4f7878dbad8 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 17:22:27 -0400 Subject: [PATCH 083/138] Not Arterial Assault (Vile Feeder and vanilla flamethrowers balance) --- Items/CalamityGlobalItemTweaks.cs | 2 +- Items/Weapons/Summon/VileFeeder.cs | 2 +- Projectiles/CalamityGlobalProjectileTweaks.cs | 2 +- Projectiles/Summon/VileFeederSummon.cs | 9 ++------- 4 files changed, 5 insertions(+), 10 deletions(-) diff --git a/Items/CalamityGlobalItemTweaks.cs b/Items/CalamityGlobalItemTweaks.cs index f9eedd1e22..60fdb47f6d 100644 --- a/Items/CalamityGlobalItemTweaks.cs +++ b/Items/CalamityGlobalItemTweaks.cs @@ -105,7 +105,7 @@ namespace CalamityMod.Items // { ItemID.FireworksLauncher, Do(DamageRatio(2f)) }, // Celebration { ItemID.Flamarang, Do(DamageExact(43)) }, { ItemID.Flamelash, Do(DamageRatio(1.25f)) }, - { ItemID.Flamethrower, Do(DamageExact(42), ShootSpeedDelta(+3f)) }, + { ItemID.Flamethrower, ShootSpeedDelta(+3f)) }, { ItemID.FlowerofFire, Do(AutoReuse, ManaExact(7), UseRatio(0.88f)) }, // Uses ratios due to remix seed { ItemID.FlowerofFrost, Do(AutoReuse, ManaExact(7), UseExact(30), DamageExact(70), ShootSpeedExact(14)) }, { ItemID.FlyingKnife, Do(DamageExact(70)) }, diff --git a/Items/Weapons/Summon/VileFeeder.cs b/Items/Weapons/Summon/VileFeeder.cs index 8bbeba057f..c42b8e20d1 100644 --- a/Items/Weapons/Summon/VileFeeder.cs +++ b/Items/Weapons/Summon/VileFeeder.cs @@ -11,7 +11,7 @@ namespace CalamityMod.Items.Weapons.Summon public class VileFeeder : ModItem, ILocalizedModType { public new string LocalizationCategory => "Items.Weapons.Summon"; - public static int BaseDamage = 9; + public static int BaseDamage = 14; public override void SetDefaults() { diff --git a/Projectiles/CalamityGlobalProjectileTweaks.cs b/Projectiles/CalamityGlobalProjectileTweaks.cs index bc232b8b76..5627cf21c6 100644 --- a/Projectiles/CalamityGlobalProjectileTweaks.cs +++ b/Projectiles/CalamityGlobalProjectileTweaks.cs @@ -129,7 +129,7 @@ namespace CalamityMod.Projectiles { ProjectileID.EnchantedBoomerang, Do(ExtraUpdatesExact(1)) }, { ProjectileID.ExplosiveBullet, standardBulletTweaks }, { ProjectileID.Flamarang, Do(ExtraUpdatesExact(2)) }, - { ProjectileID.Flames, Do(IDStaticIFrames(6), ExtraUpdatesDelta(+1)) }, // Flamethrower + Elf Melter + { ProjectileID.Flames, Do(IDStaticIFrames(6) }, // Flamethrower + Elf Melter { ProjectileID.FlamingJack, Do(ExtraUpdatesExact(1)) }, { ProjectileID.FlowerPetal, Do(MaxUpdatesExact(4), LocalIFrames(10)) }, // Orichalcum armor { ProjectileID.FlowerPow, Do(ExtraUpdatesExact(1)) }, diff --git a/Projectiles/Summon/VileFeederSummon.cs b/Projectiles/Summon/VileFeederSummon.cs index e9b2b88884..9e8a586f64 100644 --- a/Projectiles/Summon/VileFeederSummon.cs +++ b/Projectiles/Summon/VileFeederSummon.cs @@ -35,6 +35,8 @@ namespace CalamityMod.Projectiles.Summon Projectile.timeLeft *= 5; Projectile.minion = true; Projectile.DamageType = DamageClass.Summon; + Projectile.usesLocalNPCImmunity = true; + Projectile.localNPCHitCooldown = 60; } public override void SendExtraAI(BinaryWriter writer) @@ -267,13 +269,6 @@ namespace CalamityMod.Projectiles.Summon return false; } - public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) - { - target.immune[Projectile.owner] = 0; - } - - public override bool? CanDamage() => Projectile.ai[0] != 3f; - public override bool OnTileCollide(Vector2 oldVelocity) => false; } } From 7d31b4b4ef07b23b74b1fa5febe3fcf601c248b9 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 17:33:02 -0400 Subject: [PATCH 084/138] I love accidentally making the mod not compile for the 7th time today yippee --- Items/CalamityGlobalItemTweaks.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/CalamityGlobalItemTweaks.cs b/Items/CalamityGlobalItemTweaks.cs index 60fdb47f6d..ea4b9b8833 100644 --- a/Items/CalamityGlobalItemTweaks.cs +++ b/Items/CalamityGlobalItemTweaks.cs @@ -105,7 +105,7 @@ namespace CalamityMod.Items // { ItemID.FireworksLauncher, Do(DamageRatio(2f)) }, // Celebration { ItemID.Flamarang, Do(DamageExact(43)) }, { ItemID.Flamelash, Do(DamageRatio(1.25f)) }, - { ItemID.Flamethrower, ShootSpeedDelta(+3f)) }, + { ItemID.Flamethrower, Do(ShootSpeedDelta(+3f)) }, { ItemID.FlowerofFire, Do(AutoReuse, ManaExact(7), UseRatio(0.88f)) }, // Uses ratios due to remix seed { ItemID.FlowerofFrost, Do(AutoReuse, ManaExact(7), UseExact(30), DamageExact(70), ShootSpeedExact(14)) }, { ItemID.FlyingKnife, Do(DamageExact(70)) }, From 12016be083355e68803527467d29928b56cf3ea1 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 17:34:07 -0400 Subject: [PATCH 085/138] Oh my god why am I so stupid --- Projectiles/CalamityGlobalProjectileTweaks.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Projectiles/CalamityGlobalProjectileTweaks.cs b/Projectiles/CalamityGlobalProjectileTweaks.cs index 5627cf21c6..30062234d7 100644 --- a/Projectiles/CalamityGlobalProjectileTweaks.cs +++ b/Projectiles/CalamityGlobalProjectileTweaks.cs @@ -129,7 +129,7 @@ namespace CalamityMod.Projectiles { ProjectileID.EnchantedBoomerang, Do(ExtraUpdatesExact(1)) }, { ProjectileID.ExplosiveBullet, standardBulletTweaks }, { ProjectileID.Flamarang, Do(ExtraUpdatesExact(2)) }, - { ProjectileID.Flames, Do(IDStaticIFrames(6) }, // Flamethrower + Elf Melter + { ProjectileID.Flames, Do(IDStaticIFrames(6)) }, // Flamethrower + Elf Melter { ProjectileID.FlamingJack, Do(ExtraUpdatesExact(1)) }, { ProjectileID.FlowerPetal, Do(MaxUpdatesExact(4), LocalIFrames(10)) }, // Orichalcum armor { ProjectileID.FlowerPow, Do(ExtraUpdatesExact(1)) }, From 5cdf6e448321aae2a015cca77e97e63706540c67 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 17:58:43 -0400 Subject: [PATCH 086/138] Graaah Flamethrower is still way too good --- Projectiles/CalamityGlobalProjectileTweaks.cs | 1 - 1 file changed, 1 deletion(-) diff --git a/Projectiles/CalamityGlobalProjectileTweaks.cs b/Projectiles/CalamityGlobalProjectileTweaks.cs index 30062234d7..38a73f041f 100644 --- a/Projectiles/CalamityGlobalProjectileTweaks.cs +++ b/Projectiles/CalamityGlobalProjectileTweaks.cs @@ -129,7 +129,6 @@ namespace CalamityMod.Projectiles { ProjectileID.EnchantedBoomerang, Do(ExtraUpdatesExact(1)) }, { ProjectileID.ExplosiveBullet, standardBulletTweaks }, { ProjectileID.Flamarang, Do(ExtraUpdatesExact(2)) }, - { ProjectileID.Flames, Do(IDStaticIFrames(6)) }, // Flamethrower + Elf Melter { ProjectileID.FlamingJack, Do(ExtraUpdatesExact(1)) }, { ProjectileID.FlowerPetal, Do(MaxUpdatesExact(4), LocalIFrames(10)) }, // Orichalcum armor { ProjectileID.FlowerPow, Do(ExtraUpdatesExact(1)) }, From c6117349e46719ff904e9bdddf13652a0e9ec82d Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 18:03:30 -0400 Subject: [PATCH 087/138] Okay never mind I forgot Flamethrower was changed to local iframes --- Projectiles/CalamityGlobalProjectileTweaks.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/Projectiles/CalamityGlobalProjectileTweaks.cs b/Projectiles/CalamityGlobalProjectileTweaks.cs index 38a73f041f..183f2cdb7c 100644 --- a/Projectiles/CalamityGlobalProjectileTweaks.cs +++ b/Projectiles/CalamityGlobalProjectileTweaks.cs @@ -129,6 +129,7 @@ namespace CalamityMod.Projectiles { ProjectileID.EnchantedBoomerang, Do(ExtraUpdatesExact(1)) }, { ProjectileID.ExplosiveBullet, standardBulletTweaks }, { ProjectileID.Flamarang, Do(ExtraUpdatesExact(2)) }, + { ProjectileID.Flames, Do(IDStaticIFrames(10)) }, // Flamethrower + Elf Melter { ProjectileID.FlamingJack, Do(ExtraUpdatesExact(1)) }, { ProjectileID.FlowerPetal, Do(MaxUpdatesExact(4), LocalIFrames(10)) }, // Orichalcum armor { ProjectileID.FlowerPow, Do(ExtraUpdatesExact(1)) }, From e8002648c830569b21fbe01d5cb5a4aafa04538d Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 20:23:58 -0400 Subject: [PATCH 088/138] Flarewing Bow balance, including the bat functionality I swear to god if this breaks the mod for the 20th time today --- Items/Weapons/Ranged/FlarewingBow.cs | 8 ++--- Projectiles/Ranged/FlareBat.cs | 48 ++++++++++++++++++---------- 2 files changed, 35 insertions(+), 21 deletions(-) diff --git a/Items/Weapons/Ranged/FlarewingBow.cs b/Items/Weapons/Ranged/FlarewingBow.cs index 9e88e86d1b..98acdea737 100644 --- a/Items/Weapons/Ranged/FlarewingBow.cs +++ b/Items/Weapons/Ranged/FlarewingBow.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Ranged public new string LocalizationCategory => "Items.Weapons.Ranged"; public override void SetDefaults() { - Item.damage = 17; + Item.damage = 28; Item.DamageType = DamageClass.Ranged; Item.width = 40; Item.height = 72; @@ -27,7 +27,7 @@ namespace CalamityMod.Items.Weapons.Ranged Item.UseSound = SoundID.Item5; Item.autoReuse = true; Item.shoot = ProjectileID.WoodenArrowFriendly; - Item.shootSpeed = 16f; + Item.shootSpeed = 20f; Item.useAmmo = AmmoID.Arrow; Item.Calamity().canFirePointBlankShots = true; } @@ -36,7 +36,7 @@ namespace CalamityMod.Items.Weapons.Ranged { Vector2 vector2 = player.RotatedRelativePoint(player.MountedCenter, true); float num117 = 0.314159274f; - int num118 = 4; + int num118 = 3; Vector2 vector7 = velocity; vector7.Normalize(); vector7 *= 50f; @@ -70,7 +70,7 @@ namespace CalamityMod.Items.Weapons.Ranged AddIngredient(5). AddIngredient(ItemID.LivingFireBlock, 50). AddIngredient(ItemID.Obsidian, 10). - AddTile(TileID.MythrilAnvil). + AddTile(TileID.Anvils). Register(); } } diff --git a/Projectiles/Ranged/FlareBat.cs b/Projectiles/Ranged/FlareBat.cs index cb08fbbdb3..69a385bc9b 100644 --- a/Projectiles/Ranged/FlareBat.cs +++ b/Projectiles/Ranged/FlareBat.cs @@ -19,7 +19,7 @@ namespace CalamityMod.Projectiles.Ranged Projectile.height = 24; Projectile.friendly = true; Projectile.DamageType = DamageClass.Ranged; - Projectile.penetrate = 3; + Projectile.penetrate = 2; Projectile.timeLeft = 300; Projectile.light = 0.25f; Projectile.usesLocalNPCImmunity = true; @@ -64,34 +64,48 @@ namespace CalamityMod.Projectiles.Ranged } Projectile.spriteDirection = Projectile.direction = (Projectile.velocity.X > 0).ToDirectionInt(); Projectile.rotation = Projectile.velocity.ToRotation() + (Projectile.spriteDirection == 1 ? 0f : MathHelper.Pi) * Projectile.direction; - } - public override bool OnTileCollide(Vector2 oldVelocity) - { - Projectile.penetrate--; - if (Projectile.penetrate <= 0) + if (Projectile.localAI[0] > 0f) + Projectile.localAI[0]--; + + // Makes the bat home onto enemies after piercing once; this is just the HomeInOnNPC util without the extra update shenanigans + if (Projectile.penetrate == 1 && Projectile.localAI[0] <= 0f) { - Projectile.Kill(); - } - else - { - if (Projectile.velocity.X != oldVelocity.X) + if (!Projectile.friendly) + return; + + Vector2 destination = Projectile.Center; + float maxDistance = 300; + bool locatedTarget = false; + + // Find a target + for (int i = 0; i < Main.maxNPCs; i++) { - Projectile.velocity.X = -oldVelocity.X; + float extraDistance = (Main.npc[i].width / 2) + (Main.npc[i].height / 2); + if (!Main.npc[i].CanBeChasedBy(Projectile, false) || !Projectile.WithinRange(Main.npc[i].Center, maxDistance + extraDistance)) + continue; + + if (Collision.CanHit(Projectile.Center, 1, 1, Main.npc[i].Center, 1, 1)) + { + destination = Main.npc[i].Center; + locatedTarget = true; + break; + } } - if (Projectile.velocity.Y != oldVelocity.Y) + + if (locatedTarget) { - Projectile.velocity.Y = -oldVelocity.Y; + Vector2 homeDirection = (destination - Projectile.Center).SafeNormalize(Vector2.UnitY); + Projectile.velocity = (Projectile.velocity * 20f + homeDirection * 12f) / (20f + 1f); } } - return false; } public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) { target.AddBuff(BuffID.OnFire3, 480); - - Projectile.Kill(); + Projectile.localAI[0] = 10f; + Projectile.damage /= 2; } public override void OnHitPlayer(Player target, Player.HurtInfo info) From 86a68ba69295759c2e0fffbf90a3026a8ba18a80 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 20:35:03 -0400 Subject: [PATCH 089/138] Okay it needs the extra update nvm --- Projectiles/Ranged/FlareBat.cs | 32 ++------------------------------ 1 file changed, 2 insertions(+), 30 deletions(-) diff --git a/Projectiles/Ranged/FlareBat.cs b/Projectiles/Ranged/FlareBat.cs index 69a385bc9b..666a45c737 100644 --- a/Projectiles/Ranged/FlareBat.cs +++ b/Projectiles/Ranged/FlareBat.cs @@ -68,37 +68,9 @@ namespace CalamityMod.Projectiles.Ranged if (Projectile.localAI[0] > 0f) Projectile.localAI[0]--; - // Makes the bat home onto enemies after piercing once; this is just the HomeInOnNPC util without the extra update shenanigans + // Makes the bat home onto enemies after piercing once if (Projectile.penetrate == 1 && Projectile.localAI[0] <= 0f) - { - if (!Projectile.friendly) - return; - - Vector2 destination = Projectile.Center; - float maxDistance = 300; - bool locatedTarget = false; - - // Find a target - for (int i = 0; i < Main.maxNPCs; i++) - { - float extraDistance = (Main.npc[i].width / 2) + (Main.npc[i].height / 2); - if (!Main.npc[i].CanBeChasedBy(Projectile, false) || !Projectile.WithinRange(Main.npc[i].Center, maxDistance + extraDistance)) - continue; - - if (Collision.CanHit(Projectile.Center, 1, 1, Main.npc[i].Center, 1, 1)) - { - destination = Main.npc[i].Center; - locatedTarget = true; - break; - } - } - - if (locatedTarget) - { - Vector2 homeDirection = (destination - Projectile.Center).SafeNormalize(Vector2.UnitY); - Projectile.velocity = (Projectile.velocity * 20f + homeDirection * 12f) / (20f + 1f); - } - } + CalamityUtils.HomeInOnNPC(Projectile, false, 400f, 12f, 20f); } public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) From 45e06d383e7141db9d25068fe9fcd8b70401c621 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 20:47:36 -0400 Subject: [PATCH 090/138] Further Flarewing balance tweaks --- Items/Weapons/Ranged/FlarewingBow.cs | 8 ++++---- Projectiles/Ranged/FlareBat.cs | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Items/Weapons/Ranged/FlarewingBow.cs b/Items/Weapons/Ranged/FlarewingBow.cs index 98acdea737..dbcb5ab856 100644 --- a/Items/Weapons/Ranged/FlarewingBow.cs +++ b/Items/Weapons/Ranged/FlarewingBow.cs @@ -13,12 +13,12 @@ namespace CalamityMod.Items.Weapons.Ranged public new string LocalizationCategory => "Items.Weapons.Ranged"; public override void SetDefaults() { - Item.damage = 28; + Item.damage = 26; Item.DamageType = DamageClass.Ranged; Item.width = 40; Item.height = 72; - Item.useTime = 30; - Item.useAnimation = 30; + Item.useTime = 41; + Item.useAnimation = 41; Item.useStyle = ItemUseStyleID.Shoot; Item.noMelee = true; Item.knockBack = 1.5f; @@ -27,7 +27,7 @@ namespace CalamityMod.Items.Weapons.Ranged Item.UseSound = SoundID.Item5; Item.autoReuse = true; Item.shoot = ProjectileID.WoodenArrowFriendly; - Item.shootSpeed = 20f; + Item.shootSpeed = 18f; Item.useAmmo = AmmoID.Arrow; Item.Calamity().canFirePointBlankShots = true; } diff --git a/Projectiles/Ranged/FlareBat.cs b/Projectiles/Ranged/FlareBat.cs index 666a45c737..85ca86d3fa 100644 --- a/Projectiles/Ranged/FlareBat.cs +++ b/Projectiles/Ranged/FlareBat.cs @@ -70,7 +70,7 @@ namespace CalamityMod.Projectiles.Ranged // Makes the bat home onto enemies after piercing once if (Projectile.penetrate == 1 && Projectile.localAI[0] <= 0f) - CalamityUtils.HomeInOnNPC(Projectile, false, 400f, 12f, 20f); + CalamityUtils.HomeInOnNPC(Projectile, false, 500f, 12f, 20f); } public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) From 15339d01c14cd938fcb500ac86791bb797d3d283 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 21:04:46 -0400 Subject: [PATCH 091/138] One last damage tweak, it was a bit weak --- Items/Weapons/Ranged/FlarewingBow.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/FlarewingBow.cs b/Items/Weapons/Ranged/FlarewingBow.cs index dbcb5ab856..5cde932d3d 100644 --- a/Items/Weapons/Ranged/FlarewingBow.cs +++ b/Items/Weapons/Ranged/FlarewingBow.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Ranged public new string LocalizationCategory => "Items.Weapons.Ranged"; public override void SetDefaults() { - Item.damage = 26; + Item.damage = 31; Item.DamageType = DamageClass.Ranged; Item.width = 40; Item.height = 72; From ea047b3861f6e5cedc7013c06c29b222fa562001 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Mon, 28 Aug 2023 21:32:11 -0400 Subject: [PATCH 092/138] Updated Flarewing Bow's tooltip --- .../en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson index adedb1f7e7..65e8c606eb 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson @@ -475,8 +475,8 @@ FlarewingBow: { DisplayName: Flarewing Bow Tooltip: ''' - Shoots a spread of 4 arrows - Wooden arrows are converted into bouncing obsidian bats + Shoots a spread of 3 arrows + Wooden arrows are converted into obsidian bats which home in after piercing once ''' } @@ -1285,4 +1285,4 @@ WulfrumBlunderbuss: { [c/83B87E:'The good thing about Wulfrum is that while it breaks fast, it can be reused even faster.] [c/83B87E:In fact, it is quite common for a robot to be turned into ammo right after it stops functioning.'] ''' -} \ No newline at end of file +} From 0da04c32b113c25576ca493b645d2aceb425a97d Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Mon, 28 Aug 2023 21:32:15 -0600 Subject: [PATCH 093/138] You cannot have Flesh Totem's DR trigger while a shield is up --- CalPlayer/CalamityPlayerHitHurt.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CalPlayer/CalamityPlayerHitHurt.cs b/CalPlayer/CalamityPlayerHitHurt.cs index e1cc1677dd..3d3b692452 100644 --- a/CalPlayer/CalamityPlayerHitHurt.cs +++ b/CalPlayer/CalamityPlayerHitHurt.cs @@ -746,7 +746,7 @@ namespace CalamityMod.CalPlayer } // Can't have any cooldowns here because dodges grrrrr.... - if (fleshTotem && !Player.HasCooldown(Cooldowns.FleshTotem.ID)) + if (fleshTotem && !Player.HasCooldown(Cooldowns.FleshTotem.ID) && TotalEnergyShielding <= 0) contactDamageReduction += 0.5; if (tarragonCloak && tarraMelee && !Player.HasCooldown(Cooldowns.TarragonCloak.ID)) From 5ed552ae7da0096a1ab7a8d4cb4f07ea47cbec75 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Mon, 28 Aug 2023 22:23:56 -0600 Subject: [PATCH 094/138] Absorber nerfs Also ran Ctrl + K + Ctrl + D on CalamityPlayerHitHurt.cs --- CalPlayer/CalamityPlayerHitHurt.cs | 12 ++++++------ CalPlayer/CalamityPlayerMiscEffects.cs | 4 ++-- Items/Accessories/TheAbsorber.cs | 2 +- NPCs/CalamityGlobalNPC.cs | 4 ++-- Projectiles/Healing/AbsorberAura.cs | 2 +- 5 files changed, 12 insertions(+), 12 deletions(-) diff --git a/CalPlayer/CalamityPlayerHitHurt.cs b/CalPlayer/CalamityPlayerHitHurt.cs index 3d3b692452..3fc7d17598 100644 --- a/CalPlayer/CalamityPlayerHitHurt.cs +++ b/CalPlayer/CalamityPlayerHitHurt.cs @@ -1157,20 +1157,20 @@ namespace CalamityMod.CalPlayer // As such, to avoid cooldowns proccing from dodge hits, do it here if (fleshTotem && !Player.HasCooldown(Cooldowns.FleshTotem.ID) && hurtInfo.Damage > 0) Player.AddCooldown(Cooldowns.FleshTotem.ID, CalamityUtils.SecondsToFrames(20), true, coreOfTheBloodGod ? "bloodgod" : "default"); + if (NPC.AnyNPCs(ModContent.NPCType())) - { Player.AddBuff(ModContent.BuffType(), 15, true); - } + if (crawCarapace) { - npc.AddBuff(ModContent.BuffType(), 720); + npc.AddBuff(ModContent.BuffType(), 900); SoundEngine.PlaySound(SoundID.NPCHit33 with { Volume = 0.5f }, Player.Center); } if (baroclaw) { - npc.AddBuff(ModContent.BuffType(), 1800); - npc.AddBuff(ModContent.BuffType(), 1800); + npc.AddBuff(ModContent.BuffType(), 900); + npc.AddBuff(ModContent.BuffType(), 900); SoundEngine.PlaySound(BaroclawHit, Player.Center); Vector2 bloodSpawnPosition = Player.Center + Main.rand.NextVector2Circular(Player.width, Player.height) * 0.04f; Vector2 splatterDirection = (Player.Center - bloodSpawnPosition).SafeNormalize(Vector2.UnitY); @@ -1189,7 +1189,7 @@ namespace CalamityMod.CalPlayer if (absorber) { - npc.AddBuff(ModContent.BuffType(), 1800); + npc.AddBuff(ModContent.BuffType(), 900); SoundEngine.PlaySound(AbsorberHit, Player.Center); Vector2 bloodSpawnPosition = Player.Center + Main.rand.NextVector2Circular(Player.width, Player.height) * 0.04f; Vector2 splatterDirection = (Player.Center - bloodSpawnPosition).SafeNormalize(Vector2.UnitY); diff --git a/CalPlayer/CalamityPlayerMiscEffects.cs b/CalPlayer/CalamityPlayerMiscEffects.cs index 47dbbaa803..9c195f13ba 100644 --- a/CalPlayer/CalamityPlayerMiscEffects.cs +++ b/CalPlayer/CalamityPlayerMiscEffects.cs @@ -2366,8 +2366,8 @@ namespace CalamityMod.CalPlayer if (AbsorberRegen) { - Player.GetDamage() += 0.1f; - Player.endurance += 0.07f; + Player.GetDamage() += 0.08f; + Player.endurance += 0.05f; } if (crawCarapace) diff --git a/Items/Accessories/TheAbsorber.cs b/Items/Accessories/TheAbsorber.cs index dc8af18d29..87c9f5fe19 100644 --- a/Items/Accessories/TheAbsorber.cs +++ b/Items/Accessories/TheAbsorber.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Accessories public new string LocalizationCategory => "Items.Accessories"; public override void SetDefaults() { - Item.defense = 16; + Item.defense = 15; Item.width = 20; Item.height = 24; Item.value = CalamityGlobalItem.Rarity9BuyPrice; diff --git a/NPCs/CalamityGlobalNPC.cs b/NPCs/CalamityGlobalNPC.cs index 9899b205ec..1c395f9ad6 100644 --- a/NPCs/CalamityGlobalNPC.cs +++ b/NPCs/CalamityGlobalNPC.cs @@ -1014,7 +1014,7 @@ namespace CalamityMod.NPCs //Absorber Affliction if (absorberAffliction > 0) { - int baseAbsorberDoTValue = (int)(260 * sicknessDamageMult); + int baseAbsorberDoTValue = (int)(400 * sicknessDamageMult); ApplyDPSDebuff(baseAbsorberDoTValue, baseAbsorberDoTValue / 65, ref npc.lifeRegen, ref damage); } @@ -2690,7 +2690,7 @@ namespace CalamityMod.NPCs if (marked > 0) calcDR *= 0.5f; if (absorberAffliction > 0) - calcDR *= 0.7f; + calcDR *= 0.8f; if (npc.betsysCurse) calcDR *= 0.66f; if (npc.Calamity().kamiFlu > 0) diff --git a/Projectiles/Healing/AbsorberAura.cs b/Projectiles/Healing/AbsorberAura.cs index 252941164e..03c29a479c 100644 --- a/Projectiles/Healing/AbsorberAura.cs +++ b/Projectiles/Healing/AbsorberAura.cs @@ -52,7 +52,7 @@ namespace CalamityMod.Projectiles.Typless //Remove the players debuffs and defense damage, but only once per aura if (targetDist < 232f) { - player.AddBuff(ModContent.BuffType(), 900); + player.AddBuff(ModContent.BuffType(), 600); if (cleanseList[playerIndex] == false) { cleanseList[playerIndex] = true; From 433c99e228ea16155f7d7d124434201d1d30c895 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Mon, 28 Aug 2023 22:26:22 -0600 Subject: [PATCH 095/138] I hate localization files --- Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index b897a532f0..5dcdc865e5 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -1730,7 +1730,7 @@ TheAbsorber: { Enemies take immense damage when they touch you and are afflicted with a debuff that reduces damage reduction significantly Using a healing potion will spawn a cleansing aura Walking into the aura removes all debuffs and defense damage one time - The aura grants +3 HP/s life regen, +10% damage, and +7% damage reduction for all players inside for 15 seconds + The aura grants +3 HP/s life regen, +8% damage, and +5% damage reduction for all players inside for 10 seconds 5% of the damage from enemy attacks is absorbed and converted into healing ''' } From 0ea0db4b81400e5c400cc5f79d1a05dc1cf81982 Mon Sep 17 00:00:00 2001 From: Xyk Date: Mon, 28 Aug 2023 21:40:54 -0700 Subject: [PATCH 096/138] Absorber and Baroclaw tooltip fixes Shade didn't change them all --- Localization/en-US/Mods.CalamityMod.Buffs.hjson | 2 +- Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Buffs.hjson b/Localization/en-US/Mods.CalamityMod.Buffs.hjson index 772c052271..d352342248 100644 --- a/Localization/en-US/Mods.CalamityMod.Buffs.hjson +++ b/Localization/en-US/Mods.CalamityMod.Buffs.hjson @@ -1492,7 +1492,7 @@ AbsorberRegen: { Description: ''' You are blessed by the culmimation of nature's powers - Life regen increased by 6, damage increased by 10%, damage reduction increased by 7% + Life regen increased by 6, damage increased by 8%, damage reduction increased by 5% ''' } diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 5dcdc865e5..74aacfd921 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -447,7 +447,7 @@ Baroclaw: { Tooltip: ''' 10% increased damage - Enemies that hit you take high damage and are inflicted with Armor Crunch and Crush Depth for a long time + Enemies that hit you take high damage and are inflicted with Armor Crunch and Crush Depth ''' } @@ -1727,7 +1727,7 @@ TheAbsorber: { Tooltip: ''' 10% increased movement and jump speed - Enemies take immense damage when they touch you and are afflicted with a debuff that reduces damage reduction significantly + Enemies take immense damage when they touch you and are afflicted with a damaging sickeness debuff that reduces damage reduction significantly Using a healing potion will spawn a cleansing aura Walking into the aura removes all debuffs and defense damage one time The aura grants +3 HP/s life regen, +8% damage, and +5% damage reduction for all players inside for 10 seconds From 1a1ac19c92a531ef48d7d44de1f4876a846864b7 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Tue, 29 Aug 2023 16:39:09 +0300 Subject: [PATCH 097/138] Elemental Shiv pierce nerf --- Projectiles/Melee/Shortswords/ElementalShivProj.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Projectiles/Melee/Shortswords/ElementalShivProj.cs b/Projectiles/Melee/Shortswords/ElementalShivProj.cs index 653d59d278..5cb34e88a5 100644 --- a/Projectiles/Melee/Shortswords/ElementalShivProj.cs +++ b/Projectiles/Melee/Shortswords/ElementalShivProj.cs @@ -1,4 +1,4 @@ -using Terraria; +using Terraria; using Terraria.ID; using Terraria.ModLoader; using Microsoft.Xna.Framework; @@ -16,7 +16,7 @@ namespace CalamityMod.Projectiles.Melee.Shortswords { Projectile.Size = new Vector2(22); Projectile.friendly = true; - Projectile.penetrate = -1; + Projectile.penetrate = 2; Projectile.tileCollide = false; Projectile.scale = 1f; Projectile.DamageType = TrueMeleeDamageClass.Instance; From 88902ae6142b5439dc9456d1f6bc55a1cf403835 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Tue, 29 Aug 2023 16:56:42 +0300 Subject: [PATCH 098/138] Disregard the previous one terraria is confusing --- Projectiles/Melee/Shortswords/ElementalShivProj.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Projectiles/Melee/Shortswords/ElementalShivProj.cs b/Projectiles/Melee/Shortswords/ElementalShivProj.cs index 5cb34e88a5..6c9cb5ee50 100644 --- a/Projectiles/Melee/Shortswords/ElementalShivProj.cs +++ b/Projectiles/Melee/Shortswords/ElementalShivProj.cs @@ -16,7 +16,7 @@ namespace CalamityMod.Projectiles.Melee.Shortswords { Projectile.Size = new Vector2(22); Projectile.friendly = true; - Projectile.penetrate = 2; + Projectile.penetrate = -1; Projectile.tileCollide = false; Projectile.scale = 1f; Projectile.DamageType = TrueMeleeDamageClass.Instance; From 30e564978911f8022f4d9adcdc595c2695362c4d Mon Sep 17 00:00:00 2001 From: Done2222 Date: Tue, 29 Aug 2023 17:31:23 +0300 Subject: [PATCH 099/138] Elemental Shiv nerfs (hopefully good enough?) --- Items/Weapons/Melee/ElementalShiv.cs | 4 ++-- Projectiles/Melee/Shortswords/ElementalShivProj.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Melee/ElementalShiv.cs b/Items/Weapons/Melee/ElementalShiv.cs index ca8df0a385..8906d0e799 100644 --- a/Items/Weapons/Melee/ElementalShiv.cs +++ b/Items/Weapons/Melee/ElementalShiv.cs @@ -18,8 +18,8 @@ namespace CalamityMod.Items.Weapons.Melee { Item.useStyle = ItemUseStyleID.Rapier; Item.DamageType = DamageClass.Melee; - Item.useAnimation = 10; - Item.useTime = 10; + Item.useAnimation = 14; + Item.useTime = 14; Item.width = 44; Item.height = 44; Item.damage = 190; diff --git a/Projectiles/Melee/Shortswords/ElementalShivProj.cs b/Projectiles/Melee/Shortswords/ElementalShivProj.cs index 6c9cb5ee50..c06b9ca693 100644 --- a/Projectiles/Melee/Shortswords/ElementalShivProj.cs +++ b/Projectiles/Melee/Shortswords/ElementalShivProj.cs @@ -29,7 +29,7 @@ namespace CalamityMod.Projectiles.Melee.Shortswords public override Action EffectBeforePullback => (proj) => { - Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, Projectile.velocity * 14f, ModContent.ProjectileType(), (int)(Projectile.damage * 0.5), Projectile.knockBack, Projectile.owner, 0f, 0f); + Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, Projectile.velocity * 14f, ModContent.ProjectileType(), (int)(Projectile.damage * 0.35), Projectile.knockBack, Projectile.owner, 0f, 0f); }; public override void SetVisualOffsets() From 49b269f0e5754dd8bce35eff0a50e12b769fad43 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Tue, 29 Aug 2023 17:51:49 +0300 Subject: [PATCH 100/138] More elemental shiv changes :pray: --- Items/Weapons/Melee/ElementalShiv.cs | 6 +++--- Projectiles/Melee/ElementBallShiv.cs | 2 +- Projectiles/Melee/Shortswords/ElementalShivProj.cs | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Items/Weapons/Melee/ElementalShiv.cs b/Items/Weapons/Melee/ElementalShiv.cs index 8906d0e799..48bc8943b2 100644 --- a/Items/Weapons/Melee/ElementalShiv.cs +++ b/Items/Weapons/Melee/ElementalShiv.cs @@ -18,11 +18,11 @@ namespace CalamityMod.Items.Weapons.Melee { Item.useStyle = ItemUseStyleID.Rapier; Item.DamageType = DamageClass.Melee; - Item.useAnimation = 14; - Item.useTime = 14; + Item.useAnimation = 10; + Item.useTime = 10; Item.width = 44; Item.height = 44; - Item.damage = 190; + Item.damage = 210; Item.knockBack = 8.5f; Item.UseSound = SoundID.Item1; Item.autoReuse = true; diff --git a/Projectiles/Melee/ElementBallShiv.cs b/Projectiles/Melee/ElementBallShiv.cs index 0cb96a955c..09b82dafee 100644 --- a/Projectiles/Melee/ElementBallShiv.cs +++ b/Projectiles/Melee/ElementBallShiv.cs @@ -59,7 +59,7 @@ namespace CalamityMod.Projectiles.Melee private void OnHitEffects(Vector2 targetPos) { var source = Projectile.GetSource_FromThis(); - for (int x = 0; x < 4; x++) + for (int x = 0; x < 3; x++) { if (Projectile.owner == Main.myPlayer) { diff --git a/Projectiles/Melee/Shortswords/ElementalShivProj.cs b/Projectiles/Melee/Shortswords/ElementalShivProj.cs index c06b9ca693..6c9cb5ee50 100644 --- a/Projectiles/Melee/Shortswords/ElementalShivProj.cs +++ b/Projectiles/Melee/Shortswords/ElementalShivProj.cs @@ -29,7 +29,7 @@ namespace CalamityMod.Projectiles.Melee.Shortswords public override Action EffectBeforePullback => (proj) => { - Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, Projectile.velocity * 14f, ModContent.ProjectileType(), (int)(Projectile.damage * 0.35), Projectile.knockBack, Projectile.owner, 0f, 0f); + Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, Projectile.velocity * 14f, ModContent.ProjectileType(), (int)(Projectile.damage * 0.5), Projectile.knockBack, Projectile.owner, 0f, 0f); }; public override void SetVisualOffsets() From b4a59e24e06dc23b591e06ce9d796663de880df1 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Tue, 29 Aug 2023 18:39:23 +0300 Subject: [PATCH 101/138] more elemental shiv changes + homing (debugging doesnt work i apologize) --- Items/Weapons/Melee/ElementalShiv.cs | 6 +++--- Projectiles/Melee/SHIV.cs | 7 +++---- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/Items/Weapons/Melee/ElementalShiv.cs b/Items/Weapons/Melee/ElementalShiv.cs index 48bc8943b2..8a306bcab6 100644 --- a/Items/Weapons/Melee/ElementalShiv.cs +++ b/Items/Weapons/Melee/ElementalShiv.cs @@ -18,11 +18,11 @@ namespace CalamityMod.Items.Weapons.Melee { Item.useStyle = ItemUseStyleID.Rapier; Item.DamageType = DamageClass.Melee; - Item.useAnimation = 10; - Item.useTime = 10; + Item.useAnimation = 13; + Item.useTime = 13; Item.width = 44; Item.height = 44; - Item.damage = 210; + Item.damage = 180; Item.knockBack = 8.5f; Item.UseSound = SoundID.Item1; Item.autoReuse = true; diff --git a/Projectiles/Melee/SHIV.cs b/Projectiles/Melee/SHIV.cs index 1e5432ee31..731146ebe4 100644 --- a/Projectiles/Melee/SHIV.cs +++ b/Projectiles/Melee/SHIV.cs @@ -27,10 +27,9 @@ namespace CalamityMod.Projectiles.Melee } public override void AI() - { - if (Projectile.velocity.Length() < 25f && Projectile.timeLeft % 2 == 0) - Projectile.velocity *= 2.08f; - + { + CalamityUtils.HomeInOnNPC(Projectile, true, 300f, 12f, 20f); + int rainbow = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, 66, (float)(Projectile.direction * 2), 0f, 150, new Color(Main.DiscoR, Main.DiscoG, Main.DiscoB), 1.3f); Main.dust[rainbow].noGravity = true; Main.dust[rainbow].velocity = Vector2.Zero; From 8f245cacb896c6166ac9eef7cf537233dd72c907 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Tue, 29 Aug 2023 18:57:37 +0300 Subject: [PATCH 102/138] elemental shiv velocity fix --- Projectiles/Melee/SHIV.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Projectiles/Melee/SHIV.cs b/Projectiles/Melee/SHIV.cs index 731146ebe4..a19c19fc3c 100644 --- a/Projectiles/Melee/SHIV.cs +++ b/Projectiles/Melee/SHIV.cs @@ -27,7 +27,10 @@ namespace CalamityMod.Projectiles.Melee } public override void AI() - { + { + if (Projectile.velocity.Length() < 25f && Projectile.timeLeft % 2 == 0) + Projectile.velocity *= 2.08f; + CalamityUtils.HomeInOnNPC(Projectile, true, 300f, 12f, 20f); int rainbow = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, 66, (float)(Projectile.direction * 2), 0f, 150, new Color(Main.DiscoR, Main.DiscoG, Main.DiscoB), 1.3f); From 273c5ad4c4e2b467613f497638cb9a5178653de5 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Tue, 29 Aug 2023 19:03:11 +0300 Subject: [PATCH 103/138] :hollow: --- Projectiles/Melee/ElementBallShiv.cs | 2 +- Projectiles/Melee/SHIV.cs | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/Projectiles/Melee/ElementBallShiv.cs b/Projectiles/Melee/ElementBallShiv.cs index 09b82dafee..19f4c7ac75 100644 --- a/Projectiles/Melee/ElementBallShiv.cs +++ b/Projectiles/Melee/ElementBallShiv.cs @@ -63,7 +63,7 @@ namespace CalamityMod.Projectiles.Melee { if (Projectile.owner == Main.myPlayer) { - CalamityUtils.ProjectileBarrage(source, Projectile.Center, targetPos, x > 2, 800f, 800f, 0f, 800f, 1f, ModContent.ProjectileType(), Projectile.damage, Projectile.knockBack, Projectile.owner, false, 50f); + CalamityUtils.ProjectileBarrage(source, Projectile.Center, targetPos, x > 2, 800f, 800f, 0f, 800f, 20f, ModContent.ProjectileType(), Projectile.damage, Projectile.knockBack, Projectile.owner, false, 50f); } } } diff --git a/Projectiles/Melee/SHIV.cs b/Projectiles/Melee/SHIV.cs index a19c19fc3c..d940fd634a 100644 --- a/Projectiles/Melee/SHIV.cs +++ b/Projectiles/Melee/SHIV.cs @@ -28,9 +28,6 @@ namespace CalamityMod.Projectiles.Melee public override void AI() { - if (Projectile.velocity.Length() < 25f && Projectile.timeLeft % 2 == 0) - Projectile.velocity *= 2.08f; - CalamityUtils.HomeInOnNPC(Projectile, true, 300f, 12f, 20f); int rainbow = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, 66, (float)(Projectile.direction * 2), 0f, 150, new Color(Main.DiscoR, Main.DiscoG, Main.DiscoB), 1.3f); From eb10263dc1c0706273732c3fe0715fa51d1ec859 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Tue, 29 Aug 2023 12:04:39 -0400 Subject: [PATCH 104/138] Removed Star Wrath damage nerf, because 1.4.4 nerfed it --- Items/CalamityGlobalItemTweaks.cs | 1 - 1 file changed, 1 deletion(-) diff --git a/Items/CalamityGlobalItemTweaks.cs b/Items/CalamityGlobalItemTweaks.cs index ea4b9b8833..99081780c9 100644 --- a/Items/CalamityGlobalItemTweaks.cs +++ b/Items/CalamityGlobalItemTweaks.cs @@ -212,7 +212,6 @@ namespace CalamityMod.Items { ItemID.StakeLauncher, Do(PointBlank, DamageRatio(2f), UseRatio(1.5f)) }, { ItemID.StarCannon, Do(DamageExact(25)) }, { ItemID.StardustDragonStaff, Do(AutoReuse, DamageExact(20), UseExact(19)) }, - { ItemID.StarWrath, Do(DamageRatio(0.9f)) }, { ItemID.StormTigerStaff, Do(AutoReuse, DamageExact(49), UseExact(20)) }, // Desert Tiger Staff { ItemID.StylistKilLaKillScissorsIWish, Do(AutoReuse, UseTurn, DamageExact(18)) }, // Stylish Scissors { ItemID.Swordfish, Do(AutoReuse, TrueMelee, DamageExact(24)) }, From 3087f4c70ce01bc9ab231d695954f9ad8a909c0a Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Tue, 29 Aug 2023 12:33:20 -0400 Subject: [PATCH 105/138] Finishing Elemental Shiv balance --- Items/Weapons/Melee/ElementalShiv.cs | 2 +- Projectiles/Melee/ElementBallShiv.cs | 4 +++- Projectiles/Melee/SHIV.cs | 4 +++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Melee/ElementalShiv.cs b/Items/Weapons/Melee/ElementalShiv.cs index 8a306bcab6..6ed09153d6 100644 --- a/Items/Weapons/Melee/ElementalShiv.cs +++ b/Items/Weapons/Melee/ElementalShiv.cs @@ -22,7 +22,7 @@ namespace CalamityMod.Items.Weapons.Melee Item.useTime = 13; Item.width = 44; Item.height = 44; - Item.damage = 180; + Item.damage = 190; Item.knockBack = 8.5f; Item.UseSound = SoundID.Item1; Item.autoReuse = true; diff --git a/Projectiles/Melee/ElementBallShiv.cs b/Projectiles/Melee/ElementBallShiv.cs index 19f4c7ac75..44d993767d 100644 --- a/Projectiles/Melee/ElementBallShiv.cs +++ b/Projectiles/Melee/ElementBallShiv.cs @@ -14,10 +14,12 @@ namespace CalamityMod.Projectiles.Melee Projectile.height = 20; Projectile.friendly = true; Projectile.DamageType = DamageClass.Melee; - Projectile.penetrate = 1; + Projectile.penetrate = 2; Projectile.tileCollide = false; Projectile.timeLeft = 60; Projectile.aiStyle = ProjAIStyleID.Beam; + Projectile.usesLocalNPCImmunity = true; + Projectile.localNPCHitCooldown = -1; } public override void AI() diff --git a/Projectiles/Melee/SHIV.cs b/Projectiles/Melee/SHIV.cs index d940fd634a..2283f9cf48 100644 --- a/Projectiles/Melee/SHIV.cs +++ b/Projectiles/Melee/SHIV.cs @@ -19,11 +19,13 @@ namespace CalamityMod.Projectiles.Melee Projectile.height = 20; Projectile.friendly = true; Projectile.DamageType = DamageClass.Melee; - Projectile.penetrate = 1; + Projectile.penetrate = 2; Projectile.tileCollide = false; Projectile.timeLeft = 90; Projectile.aiStyle = ProjAIStyleID.Beam; Projectile.extraUpdates = 1; + Projectile.usesLocalNPCImmunity = true; + Projectile.localNPCHitCooldown = -1; } public override void AI() From bbcf5ed36d42ce3343b00b7e285bd42f3a6043d8 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Tue, 29 Aug 2023 14:59:41 -0400 Subject: [PATCH 106/138] Starlight is now exempt from the pierce resist system --- CalamityLists.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/CalamityLists.cs b/CalamityLists.cs index 5439ad99a8..e48f6b1630 100644 --- a/CalamityLists.cs +++ b/CalamityLists.cs @@ -1989,6 +1989,7 @@ namespace CalamityMod ProjectileID.MonkStaffT3, ProjectileID.LastPrismLaser, ProjectileID.ChargedBlasterLaser, + ProjectileID.PiercingStarlight, ProjectileID.FinalFractal, ProjectileType(), ProjectileType(), From c7a340f5a3e6a1f6c9533233a2c2f231cc3013ae Mon Sep 17 00:00:00 2001 From: GinYuH Date: Mon, 28 Aug 2023 22:51:31 -0700 Subject: [PATCH 107/138] made it easier for other mods to add difficulties --- ModSupport/ModCalls.cs | 18 +++++++++ Systems/DifficultyModeSystem.cs | 60 ++++++++++++++++------------- UI/ModeIndicator/ModeIndicatorUI.cs | 4 +- 3 files changed, 53 insertions(+), 29 deletions(-) diff --git a/ModSupport/ModCalls.cs b/ModSupport/ModCalls.cs index 90e028304a..19302dcd1e 100644 --- a/ModSupport/ModCalls.cs +++ b/ModSupport/ModCalls.cs @@ -7,6 +7,7 @@ using CalamityMod.Events; using CalamityMod.Items; using CalamityMod.Particles; using CalamityMod.Particles.Metaballs; +using CalamityMod.Systems; using CalamityMod.UI; using CalamityMod.UI.CalamitasEnchants; using CalamityMod.UI.DraedonSummoning; @@ -521,6 +522,13 @@ namespace CalamityMod return CalamityWorld.armageddon = enabled; } } + + public static void AddCustomDifficulty(DifficultyMode newMode) + { + //Add the new difficulty and recalculate + DifficultyModeSystem.Difficulties.Add(newMode); + DifficultyModeSystem.CalculateDifficultyData(); + } #endregion #region Rogue Class @@ -1865,6 +1873,16 @@ namespace CalamityMod return new ArgumentException("ERROR: The first argument to \"SetDifficulty\" must be a string."); return SetDifficultyActive(args[1].ToString(), enabled); + + case "AddDifficultyToUI": + if (args.Length < 2) + return new ArgumentException("ERROR: Not enough arguements provided"); + + if (args[1] is not DifficultyMode mode) + return new ArgumentException("ERROR: A class inheriting from 'DifficultyMode' must be provided."); + AddCustomDifficulty(mode); + return null; + case "GetLight": case "GetLightLevel": case "GetLightStrength": diff --git a/Systems/DifficultyModeSystem.cs b/Systems/DifficultyModeSystem.cs index fa1cdd14f6..b91788d864 100644 --- a/Systems/DifficultyModeSystem.cs +++ b/Systems/DifficultyModeSystem.cs @@ -22,23 +22,51 @@ namespace CalamityMod.Systems { internal static bool _hasCheckedItOutYet = false; //Simple variable to add a cool effect to the mode selector - public static DifficultyMode[] Difficulties; //Difficulty modes ordered by ascending difficulty + public static List Difficulties = new List(); //Difficulty modes ordered by ascending difficulty public static List DifficultyTiers; //Difficulty modes grouped together by difficulty public static int MostAlternateDifficulties; //The most alternate difficulties at any tier that exists. Used to know the widest space to take in the ui public override void Load() { MostAlternateDifficulties = 1; - Difficulties = new DifficultyMode[] { new NoDifficulty(), new RevengeanceDifficulty(), new DeathDifficulty()}; + //Initialize base mod difficulties + Difficulties = new List() { new NoDifficulty(), new RevengeanceDifficulty(), new DeathDifficulty()}; - //All of this should happen after a hook happens which lets other mods add their own difficulties - Difficulties = Difficulties.OrderBy(d => d.DifficultyScale).ToArray(); + CalculateDifficultyData(); + } + public override void Unload() + { + Difficulties = null; + } + + public static DifficultyMode GetCurrentDifficulty + { + get + { + DifficultyMode mode = Difficulties[0]; + + for (int i = 1; i < Difficulties.Count; i++) + { + if (Difficulties[i].Enabled) + mode = Difficulties[i]; + } + + return mode; + } + } + + public static void CalculateDifficultyData() + { + MostAlternateDifficulties = 1; + Difficulties.OrderBy(d => d.DifficultyScale); + + //Difficulties are arranged in "tiers". This is done so that multiple mods can add their own alternate difficulties sharing a tier with the base ones DifficultyTiers = new List(); float currentTier = -1; int tierIndex = -1; - for (int i = 0; i < Difficulties.Length; i++) + for (int i = 0; i < Difficulties.Count; i++) { //if we are at a new tier, create a new list of difficulties at that tier. if (currentTier != Difficulties[i].DifficultyScale) @@ -53,7 +81,6 @@ namespace CalamityMod.Systems { //ugly DifficultyTiers[tierIndex] = DifficultyTiers[tierIndex].Append(Difficulties[i]).ToArray(); - MostAlternateDifficulties = Math.Max(DifficultyTiers[tierIndex].Length, MostAlternateDifficulties); } @@ -61,27 +88,6 @@ namespace CalamityMod.Systems } } - public override void Unload() - { - Difficulties = null; - } - - public static DifficultyMode GetCurrentDifficulty - { - get - { - DifficultyMode mode = Difficulties[0]; - - for (int i = 1; i < Difficulties.Length; i++) - { - if (Difficulties[i].Enabled) - mode = Difficulties[i]; - } - - return mode; - } - } - public override void SaveWorldData(TagCompound tag) { //Apparently this is ran after worldgen so it cant always be set to true diff --git a/UI/ModeIndicator/ModeIndicatorUI.cs b/UI/ModeIndicator/ModeIndicatorUI.cs index 90c6b4b05d..723f75b573 100644 --- a/UI/ModeIndicator/ModeIndicatorUI.cs +++ b/UI/ModeIndicator/ModeIndicatorUI.cs @@ -210,7 +210,7 @@ namespace CalamityMod.UI.ModeIndicator string modeToDisplay = Difficulties[1].Name.ToString(); bool anyActiveMode = false; - for (int i = 1; i < Difficulties.Length; i++) + for (int i = 1; i < Difficulties.Count; i++) { if (GetCurrentDifficulty == Difficulties[i]) { @@ -406,7 +406,7 @@ namespace CalamityMod.UI.ModeIndicator // But would be super useful so other mods can let their own difficulties go there. // Disable difficulties. - for (int i = 0; i < Difficulties.Length; i++) + for (int i = 0; i < Difficulties.Count; i++) { // Disable all difficulties at the same tier / at a tier above itself. if (Difficulties[i]._difficultyTier >= mode._difficultyTier && Difficulties[i] != mode) From 2f6af2261fb2389229334836a90b09bd353eb091 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Tue, 29 Aug 2023 15:07:08 -0400 Subject: [PATCH 108/138] Added Ballistic Poison Bomb clouds and Duststorm in a Bottle to the pierce resist exception list --- CalamityLists.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CalamityLists.cs b/CalamityLists.cs index e48f6b1630..77d91932d9 100644 --- a/CalamityLists.cs +++ b/CalamityLists.cs @@ -2038,6 +2038,8 @@ namespace CalamityMod ProjectileType(), ProjectileType(), ProjectileType(), + ProjectileType(), + ProjectileType(), }; // Lists of enemies that resist piercing to some extent (mostly worms). From 2401b30db93e85d1937a7eda3d63180f7d193bf0 Mon Sep 17 00:00:00 2001 From: Memes <114233643+Mr-Memes@users.noreply.github.com> Date: Sat, 26 Aug 2023 00:40:32 +0200 Subject: [PATCH 109/138] Reworked Snake Eyes (Missing tooltip). --- Items/Weapons/DraedonsArsenal/SnakeEyes.cs | 19 +- .../Mods.CalamityMod.Projectiles.Misc.hjson | 3 +- .../DraedonsArsenal/SnakeEyesProjectile.cs | 198 +++++++++ .../DraedonsArsenal/SnakeEyesSummon.cs | 382 +++++++++--------- 4 files changed, 399 insertions(+), 203 deletions(-) create mode 100644 Projectiles/DraedonsArsenal/SnakeEyesProjectile.cs diff --git a/Items/Weapons/DraedonsArsenal/SnakeEyes.cs b/Items/Weapons/DraedonsArsenal/SnakeEyes.cs index 4085c57b49..13d1938b35 100644 --- a/Items/Weapons/DraedonsArsenal/SnakeEyes.cs +++ b/Items/Weapons/DraedonsArsenal/SnakeEyes.cs @@ -15,12 +15,16 @@ namespace CalamityMod.Items.Weapons.DraedonsArsenal public class SnakeEyes : ModItem, ILocalizedModType { public new string LocalizationCategory => "Items.Weapons.DraedonsArsenal"; + + public static float EnemyDistanceDetection = 2000f; + public static float TimeToShoot = 30f; + public static float ProjectileSpeed = 40f; + public static float TimeToRedirect = 15f; + public static float TimeToRestart = 45f; + public override void SetDefaults() { - CalamityGlobalItem modItem = Item.Calamity(); - - Item.shootSpeed = 10f; - Item.damage = 65; + Item.damage = 200; Item.mana = 12; Item.width = 38; Item.height = 24; @@ -35,9 +39,9 @@ namespace CalamityMod.Items.Weapons.DraedonsArsenal Item.UseSound = SoundID.Item15; Item.autoReuse = true; Item.shoot = ModContent.ProjectileType(); - Item.shootSpeed = 10f; Item.DamageType = DamageClass.Summon; + CalamityGlobalItem modItem = Item.Calamity(); modItem.UsesCharge = true; modItem.MaxCharge = 190f; modItem.ChargePerUse = 1f; @@ -46,10 +50,7 @@ namespace CalamityMod.Items.Weapons.DraedonsArsenal public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) { - int watcher = Projectile.NewProjectile(source, Main.MouseWorld, Vector2.Zero, type, damage, knockback, player.whoAmI); - if (Main.projectile.IndexInRange(watcher)) - Main.projectile[watcher].originalDamage = Item.damage; - + Projectile.NewProjectile(source, Main.MouseWorld, Vector2.Zero, type, damage, knockback, player.whoAmI); return false; } diff --git a/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson b/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson index 0ba4bae953..304236fe2f 100644 --- a/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson +++ b/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson @@ -70,4 +70,5 @@ PlagueExplosionGas.DisplayName: Plague Gas PlagueShot.DisplayName: Plague Shot PlagueShotBuffer.DisplayName: Plague Shot WaterShot.DisplayName: Water Shot -WaterShotBuffer.DisplayName: Water Shot \ No newline at end of file +WaterShotBuffer.DisplayName: Water Shot +SnakeEyesProjectile.DisplayName: Snake Eyes Projectile \ No newline at end of file diff --git a/Projectiles/DraedonsArsenal/SnakeEyesProjectile.cs b/Projectiles/DraedonsArsenal/SnakeEyesProjectile.cs new file mode 100644 index 0000000000..f4f3166b21 --- /dev/null +++ b/Projectiles/DraedonsArsenal/SnakeEyesProjectile.cs @@ -0,0 +1,198 @@ +using System; +using System.IO; +using CalamityMod.Items.Weapons.DraedonsArsenal; +using CalamityMod.Particles; +using Microsoft.Xna.Framework; +using Microsoft.Xna.Framework.Graphics; +using Terraria; +using Terraria.Audio; +using Terraria.Graphics.Shaders; +using Terraria.ID; +using Terraria.ModLoader; + +namespace CalamityMod.Projectiles.DraedonsArsenal +{ + public class SnakeEyesProjectile : ModProjectile, ILocalizedModType + { + public new string LocalizationCategory => "Projectiles.Misc"; + public override string Texture => "CalamityMod/Projectiles/InvisibleProj"; + + public Player Owner => Main.player[Projectile.owner]; + public NPC TargetShot => Main.npc[(int)TargetID]; + public NPC Target => Projectile.Center.MinionHoming(SnakeEyes.EnemyDistanceDetection, Owner); + + public ref float MinionID => ref Projectile.ai[0]; + public ref float TargetID => ref Projectile.ai[1]; + public ref float TimerToRedirect => ref Projectile.ai[2]; + + public bool HasHitEnemy = false; + public bool HasRedirected = false; + + public override void SetStaticDefaults() + { + ProjectileID.Sets.MinionShot[Type] = true; + + // While this projectile doesn't have afterimages, it keeps track of old positions for its primitive drawcode. + ProjectileID.Sets.TrailingMode[Type] = 2; + ProjectileID.Sets.TrailCacheLength[Type] = 6; + } + + public override void SetDefaults() + { + Projectile.DamageType = DamageClass.Summon; + Projectile.localNPCHitCooldown = 10; + Projectile.width = Projectile.height = 16; + Projectile.timeLeft = 120; + Projectile.penetrate = -1; + + Projectile.friendly = true; + Projectile.tileCollide = false; + Projectile.ignoreWater = true; + Projectile.usesLocalNPCImmunity = true; + Projectile.netImportant = true; + } + + #region Variable Syncing + + public override void SendExtraAI(BinaryWriter writer) + { + writer.Write(HasHitEnemy); + writer.Write(HasRedirected); + } + + public override void ReceiveExtraAI(BinaryReader reader) + { + HasHitEnemy = reader.ReadBoolean(); + HasRedirected = reader.ReadBoolean(); + } + + #endregion + + public override void AI() + { + if (HasHitEnemy && TimerToRedirect < SnakeEyes.TimeToRedirect) + TimerToRedirect++; + + if (TimerToRedirect >= SnakeEyes.TimeToRedirect && !HasRedirected) + { + if (TargetShot is not null) + TargetEnemy(TargetShot); + else if (Target is not null) + TargetEnemy(Target); + } + + if (HasRedirected) + { + if (TargetShot is not null) + FollowEnemy(TargetShot); + else if (Target is not null) + FollowEnemy(Target); + else + Projectile.Kill(); + + Projectile.timeLeft = 2; + } + + for (int i = 0; i < 2; i++) + { + Dust trailDust = Dust.NewDustDirect(Projectile.position, Projectile.width, Projectile.height, HasRedirected ? 261 : 226, Scale : HasRedirected ? 2f : .5f); + trailDust.velocity = Vector2.Zero; + trailDust.noGravity = true; + } + } + + #region AI Methods + + private void TargetEnemy(NPC target) + { + Projectile.velocity = Projectile.SafeDirectionTo(target.Center) * SnakeEyes.ProjectileSpeed; + HasRedirected = true; + + SoundEngine.PlaySound(SoundID.Item92 with { Volume = .8f, Pitch = .5f, PitchVariance = .1f }, Projectile.Center); + + Projectile.netUpdate = true; + } + + private void FollowEnemy(NPC target) + { + Projectile.velocity = Vector2.Lerp(Projectile.velocity, Projectile.SafeDirectionTo(target.Center) * SnakeEyes.ProjectileSpeed, .2f); + } + + #endregion + + public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone) + { + HasHitEnemy = true; + + if (HasRedirected && TargetShot == target) + Projectile.Kill(); + } + + public override void Kill(int timeLeft) + { + if (!HasRedirected) + return; + + Projectile.ExpandHitboxBy(300); + Projectile.Damage(); + + for (int i = 0; i < 20; i++) + { + Dust boomDust = Dust.NewDustDirect(Projectile.position, Projectile.width, Projectile.height, 261, Scale: 2f); + boomDust.noGravity = true; + } + + Particle boom = new DirectionalPulseRing(Projectile.Center, Vector2.Zero, Color.White, Vector2.One, 0f, 0.05f, 1f + Main.rand.NextFloat(0.2f), 20); + GeneralParticleHandler.SpawnParticle(boom); + + SoundEngine.PlaySound(SoundID.Item14, Projectile.Center); + } + + #region Shader Trail Methods + + private float PrimitiveWidthFunction(float completionRatio) + { + float arrowheadCutoff = 0.36f; + float width = 39f; + float minHeadWidth = 0.02f; + float maxHeadWidth = width; + if (completionRatio <= arrowheadCutoff) + width = MathHelper.Lerp(minHeadWidth, maxHeadWidth, Utils.GetLerpValue(0f, arrowheadCutoff, completionRatio, true)); + return width; + } + + private Color PrimitiveColorFunction(float completionRatio) + { + float endFadeRatio = 0.41f; + + float completionRatioFactor = 2.7f; + float globalTimeFactor = 5.3f; + float endFadeFactor = 3.2f; + float endFadeTerm = Utils.GetLerpValue(0f, endFadeRatio * 0.5f, completionRatio, true) * endFadeFactor; + float cosArgument = completionRatio * completionRatioFactor - Main.GlobalTimeWrappedHourly * globalTimeFactor + endFadeTerm; + float startingInterpolant = (float)Math.Cos(cosArgument) * 0.5f + 0.5f; + + float colorLerpFactor = 0.6f; + Color startingColor = Color.Lerp(HasRedirected ? Color.White with { A = 50 } : new Color(0, 0, 0, 0), HasRedirected ? Color.White with { A = 100 } : Color.Cyan with { A = 25 }, startingInterpolant * colorLerpFactor); + + return Color.Lerp(startingColor, HasRedirected ? Color.White : Color.DarkCyan with { A = 50 }, MathHelper.SmoothStep(0f, 1f, Utils.GetLerpValue(0f, endFadeRatio, completionRatio, true))); + } + + #endregion + + public override bool PreDraw(ref Color lightColor) + { + Texture2D texture = ModContent.Request(Texture).Value; + Vector2 drawPosition = Projectile.Center - Main.screenPosition; + Rectangle frame = texture.Frame(1, Main.projFrames[Type], 0, Projectile.frame); + Vector2 origin = frame.Size() * 0.5f; + Main.EntitySpriteDraw(texture, drawPosition, frame, Projectile.GetAlpha(lightColor), Projectile.rotation, origin, Projectile.scale, SpriteEffects.None, 0); + + PrimitiveTrail trail = new PrimitiveTrail(PrimitiveWidthFunction, PrimitiveColorFunction, specialShader: GameShaders.Misc["CalamityMod:TrailStreak"]); + GameShaders.Misc["CalamityMod:TrailStreak"].SetShaderTexture(ModContent.Request("CalamityMod/ExtraTextures/Trails/FabstaffStreak")); + trail.Draw(Projectile.oldPos, Projectile.Size * 0.5f - Main.screenPosition, 92); + + return false; + } + } +} diff --git a/Projectiles/DraedonsArsenal/SnakeEyesSummon.cs b/Projectiles/DraedonsArsenal/SnakeEyesSummon.cs index d210a36699..9d9d6bd098 100644 --- a/Projectiles/DraedonsArsenal/SnakeEyesSummon.cs +++ b/Projectiles/DraedonsArsenal/SnakeEyesSummon.cs @@ -1,260 +1,256 @@ -using CalamityMod.Buffs.Summon; +using System; +using CalamityMod.Buffs.Summon; +using CalamityMod.CalPlayer; +using CalamityMod.Items.Weapons.DraedonsArsenal; +using CalamityMod.Particles; using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Graphics; -using System; -using System.IO; using Terraria; +using Terraria.Audio; +using Terraria.DataStructures; using Terraria.ID; using Terraria.ModLoader; + namespace CalamityMod.Projectiles.DraedonsArsenal { public class SnakeEyesSummon : ModProjectile, ILocalizedModType { public new string LocalizationCategory => "Projectiles.Misc"; - public bool SufferingFromSeparationAnxiety = false; - public Vector2 OldCenter; - public Vector2 Destination; - public float Time + public Player Owner => Main.player[Projectile.owner]; + public CalamityPlayer ModdedOwner => Owner.Calamity(); + public NPC Target => Owner.Center.MinionHoming(2000f, Owner); + + public enum AIState { - get => Projectile.ai[0]; - set => Projectile.ai[0] = value; + Idle, + Targetting, + Redirecting } + public AIState State + { + get => (AIState)Projectile.ai[0]; + set => Projectile.ai[0] = (int)value; + } + public ref float AITimer => ref Projectile.ai[1]; + public ref float EyeAngle => ref Projectile.localAI[0]; + public ref float EyeOutwardness => ref Projectile.localAI[1]; - public float EyeOutwardness = 1f; - public float EyeRotation = 0f; + public bool HasShot = false; + public bool HasTeleported = false; + public Vector2 RandomPosition; public override void SetStaticDefaults() { - ProjectileID.Sets.MinionSacrificable[Projectile.type] = true; - ProjectileID.Sets.MinionTargettingFeature[Projectile.type] = true; - ProjectileID.Sets.TrailingMode[Projectile.type] = 0; - ProjectileID.Sets.TrailCacheLength[Projectile.type] = 4; + ProjectileID.Sets.MinionSacrificable[Type] = true; + ProjectileID.Sets.MinionTargettingFeature[Type] = true; } public override void SetDefaults() { + Projectile.DamageType = DamageClass.Summon; + Projectile.minionSlots = 1f; Projectile.width = Projectile.height = 22; - Projectile.netImportant = true; - Projectile.friendly = true; - Projectile.minionSlots = 1; - Projectile.timeLeft = 18000; Projectile.penetrate = -1; - Projectile.timeLeft *= 5; + + Projectile.friendly = true; Projectile.minion = true; Projectile.tileCollide = false; - Projectile.DamageType = DamageClass.Summon; - } - - public override void SendExtraAI(BinaryWriter writer) - { - writer.Write(SufferingFromSeparationAnxiety); - writer.Write(EyeOutwardness); - writer.Write(EyeRotation); - writer.WriteVector2(OldCenter); - writer.WriteVector2(Destination); - } - public override void ReceiveExtraAI(BinaryReader reader) - { - SufferingFromSeparationAnxiety = reader.ReadBoolean(); - EyeOutwardness = reader.ReadSingle(); - EyeRotation = reader.ReadSingle(); - OldCenter = reader.ReadVector2(); - Destination = reader.ReadVector2(); + Projectile.netImportant = true; } public override void AI() { - Player player = Main.player[Projectile.owner]; - if (Projectile.localAI[0] == 0f) + // Checks if the minion can still exist given the player's circumstance. + CheckMinionExistence(); + + // The minion does not use velocity at all, so to prevent AI breaks, velocity will always be 0. + Projectile.velocity = Vector2.Zero; + + // The properties of the minion's pupil, it looks around the target if there's one and to the mouse if there isn't any. + EyeAngle = Projectile.SafeDirectionTo((Target is not null) ? Target.Center : Main.MouseWorld).ToRotation(); + EyeOutwardness = Utils.Remap(Projectile.Distance((Target is not null) ? Target.Center : Main.MouseWorld), 0f, 300f, 0f, 5f); + + // Random flavor pulse. + if (Main.rand.NextBool(100)) { - Initialize(player); - Projectile.localAI[0] = 1f; + Particle pulse = new DirectionalPulseRing(Projectile.Center, Vector2.Zero, Color.DarkCyan, Vector2.One, 0f, 0.05f, 0.4f + Main.rand.NextFloat(0.2f), 30); + GeneralParticleHandler.SpawnParticle(pulse); } - GrantBuffs(player); - NPC potentialTarget = Projectile.Center.MinionHoming(820f, player); - if (potentialTarget == null || SufferingFromSeparationAnxiety) + + switch (State) { - Projectile.ai[1] = 0f; - if (Projectile.localAI[1] == 1f) + case AIState.Idle: + IdleState(); + break; + case AIState.Targetting: + TargettingState(); + break; + case AIState.Redirecting: + RedirectingState(); + break; + } + } + + #region AI Methods + + private void IdleState() + { + // The projectile oscillates in place. + Projectile.Center += Vector2.UnitY * MathF.Sin(Main.GlobalTimeWrappedHourly) / 3f; + + // If the player's far enough from the minion, he'll teleport somewhere around the player. + if (!Projectile.WithinRange(Owner.Center, 400f)) + { + Projectile.Center = Owner.Center + Main.rand.NextVector2Circular(300f, 300f); + DoVFXPulse(); + } + + if (Target is not null) + SwitchAIState(AIState.Targetting); + } + + private void TargettingState() + { + if (Target is not null) + { + // The minion decides a random position around the target. + if (!HasTeleported) { - Time = 0f; - Projectile.localAI[1] = 0f; + RandomPosition = Target.Center + Main.rand.NextVector2CircularEdge(400f, 400f); + Projectile.Center = RandomPosition; + + DoVFXPulse(); + + HasTeleported = true; + Projectile.netUpdate = true; + } + + else + { + // The projectile will stay on that position. + Projectile.Center = RandomPosition; + + // When the delay is over, shoot at the target. + if (!HasShot && AITimer >= SnakeEyes.TimeToShoot) + ShootProjectile(); + + // When the minion has shot, when the projectile redirects towards the target, + // the minion will teleport on that moment on top of the projectile, + // so it looks like the minion deflected his own projectile. + if (HasShot) + { + for (int i = 0; i < Main.maxProjectiles; i++) + { + Projectile proj = Main.projectile[i]; + if (proj is not null && proj.active && proj.type == ModContent.ProjectileType() && proj.owner == Owner.whoAmI && proj.ModProjectile().MinionID == Projectile.whoAmI && proj.ModProjectile().HasRedirected) + { + Projectile.Center = proj.Center; + SwitchAIState(AIState.Redirecting); + } + } + } + + // If the projectile failed to hit it's enemy and therefore couldn't deflect, + // repeat this process. + if (AITimer >= SnakeEyes.TimeToShoot + 120f) + SwitchAIState(AIState.Targetting); + + AITimer++; } - PlayerMovement(player); } else + SwitchAIState(AIState.Idle); + } + + private void ShootProjectile() + { + if (Main.myPlayer == Projectile.owner) { - if (Projectile.localAI[1] == 0f) - { - Time = 0f; - Projectile.localAI[1] = 1f; - } - NPCMovement(potentialTarget); - } - if (!SufferingFromSeparationAnxiety && Projectile.Distance(player.Center) > (potentialTarget is null ? 360f : 1800f)) - { - SufferingFromSeparationAnxiety = true; + Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, CalamityUtils.CalculatePredictiveAimToTarget(Projectile.Center, Target, SnakeEyes.ProjectileSpeed), ModContent.ProjectileType(), Projectile.damage, Projectile.knockBack, Owner.whoAmI, Projectile.whoAmI, Target.whoAmI); + + DoVFXPulse(); + + SoundEngine.PlaySound(SoundID.Item91 with { Volume = .8f, Pitch = .5f, PitchVariance = .1f }, Projectile.Center); + + HasShot = true; Projectile.netUpdate = true; } - else if (SufferingFromSeparationAnxiety && Projectile.Distance(player.Center) < (potentialTarget is null ? 10f : 120f)) - { - SufferingFromSeparationAnxiety = false; - Projectile.netUpdate = true; - } - if (!Main.dedServ) - { - GenerateAfterimageDust(); - } - Time++; } - public void Initialize(Player player) + private void RedirectingState() { - Destination = Projectile.Center - Vector2.UnitY * 180f; - for (int i = 0; i < 45; i++) + if (Target is not null) { - float angle = MathHelper.TwoPi / 45f * i; - Vector2 velocity = angle.ToRotationVector2() * 4f; - Dust dust = Dust.NewDustPerfect(Projectile.Center + velocity * 2.75f, 39, velocity); - dust.noGravity = true; + // The projectile will idle on the spot where he "deflected" the projectile to restart the process. + if (AITimer < SnakeEyes.TimeToRestart) + AITimer++; + else + SwitchAIState(AIState.Targetting); } + else + SwitchAIState(AIState.Idle); } - public void GrantBuffs(Player player) + private void SwitchAIState(AIState state) { - bool isCorrectProjectile = Projectile.type == ModContent.ProjectileType(); - player.AddBuff(ModContent.BuffType(), 3600); - if (isCorrectProjectile) - { - if (player.dead) - { - player.Calamity().snakeEyes = false; - } - if (player.Calamity().snakeEyes) - { - Projectile.timeLeft = 2; - } - } + State = state; + + AITimer = 0f; + HasTeleported = false; + HasShot = false; + RandomPosition = Vector2.Zero; + + DoVFXPulse(state == AIState.Redirecting); + + Projectile.netUpdate = true; } - public void PlayerMovement(Player player) + private void CheckMinionExistence() { - Projectile.velocity = Vector2.Zero; - if (!SufferingFromSeparationAnxiety) - { - Projectile.Center = player.Center - Vector2.UnitY * (80f + (float)Math.Sin(Time / 120f * MathHelper.TwoPi) * 30f); - EyeOutwardness = MathHelper.Lerp(EyeOutwardness, 0f, 0.15f); + Owner.AddBuff(ModContent.BuffType(), 2); + if (Type != ModContent.ProjectileType()) return; - } - if (Time % 150f == 0f) - { - OldCenter = Projectile.Center; - } - else if (Time % 150f <= 35f) - { - EyeRotation = Projectile.AngleTo(player.Center); - EyeOutwardness = MathHelper.Lerp(EyeOutwardness, 1f, 0.15f); - Projectile.Center = Vector2.SmoothStep(OldCenter, player.Center - Vector2.UnitY * 80f, Utils.GetLerpValue(0f, 35f, Time % 150f)); - } - else - { - Projectile.Center = player.Center - Vector2.UnitY * (80f + (float)Math.Sin((Time % 150f - 35f) / 115f * MathHelper.TwoPi) * 30f); - } - EyeOutwardness = MathHelper.Lerp(EyeOutwardness, 0f, 0.15f); + + if (Owner.dead) + ModdedOwner.snakeEyes = false; + if (ModdedOwner.snakeEyes) + Projectile.timeLeft = 2; } - public void NPCMovement(NPC npc) + private void DoVFXPulse(bool empowered = false) { - Projectile.velocity = Vector2.Zero; - Vector2 offsetMultiplier = Vector2.UnitX; - switch ((int)Projectile.ai[1] % 4) + int dustAmount = 40; + for (int dustIndex = 0; dustIndex < dustAmount; dustIndex++) { - case 0: - offsetMultiplier = new Vector2(-1f, -1f); - break; - case 1: - offsetMultiplier = new Vector2(-1f, 1f); - break; - case 2: - offsetMultiplier = new Vector2(1f, 1f); - break; - case 3: - offsetMultiplier = new Vector2(1f, -1f); - break; - } - if (Time % 20f == 0f) - { - if (Projectile.ai[1] > 0 && Main.myPlayer == Projectile.owner) - { - Vector2 shootPosition = Projectile.Center + Utils.Vector2FromElipse(EyeRotation.ToRotationVector2(), Projectile.Size * 0.5f * EyeOutwardness); - Vector2 shootVelocity = Projectile.SafeDirectionTo(npc.Center, Main.rand.NextVector2Unit()) * 4f; - int laser = Projectile.NewProjectile(Projectile.GetSource_FromThis(), shootPosition, shootVelocity, ProjectileID.UFOLaser, Projectile.damage, Projectile.knockBack, Projectile.owner); - if (laser.WithinBounds(Main.maxProjectiles)) - { - Main.projectile[laser].timeLeft *= 2; - Main.projectile[laser].originalDamage = Projectile.originalDamage; - Main.projectile[laser].tileCollide = false; - Main.projectile[laser].netUpdate = true; - Main.projectile[laser].DamageType = DamageClass.Summon; - } - } - Projectile.ai[1]++; - OldCenter = Projectile.Center; - } - else - { - EyeOutwardness = MathHelper.Lerp(EyeOutwardness, 1f, 0.15f); - EyeRotation = EyeRotation.AngleTowards(Projectile.AngleTo(npc.Center), MathHelper.TwoPi / 20f); - Projectile.Center = Vector2.SmoothStep(OldCenter, npc.Center + (new Vector2(300f) + Projectile.Size * 0.5f) * offsetMultiplier, Time % 20f / 20f); + float angle = MathHelper.TwoPi / dustAmount * dustIndex; + Vector2 velocity = angle.ToRotationVector2() * 9f; + Dust pulseDust = Dust.NewDustPerfect(Projectile.Center, empowered ? 261 : 226, velocity, Scale: empowered ? 2f : .5f); + pulseDust.noGravity = true; } + + Particle pulse = new DirectionalPulseRing(Projectile.Center, Vector2.Zero, empowered ? Color.White : Color.DarkCyan * 1.2f, Vector2.One, 0f, 0.05f, 0.5f + Main.rand.NextFloat(0.2f), 20); + GeneralParticleHandler.SpawnParticle(pulse); } - public void GenerateAfterimageDust() - { - for (int i = 1; i < Projectile.oldPos.Length; i++) - { - if (i == 1) - { - for (int j = 0; j < 14; j++) - { - Dust dust = Dust.NewDustPerfect(Projectile.Center, 261); - dust.position += (j / 14f * MathHelper.TwoPi).ToRotationVector2() * Projectile.Size * 0.5f * 1.3f; - dust.velocity = Vector2.Zero; - dust.scale = 0.6f; - dust.noGravity = true; - } - } - if (Vector2.Distance(Projectile.oldPos[i - 1], Projectile.oldPos[i]) > 3f) - { - for (int j = 0; j < 7; j++) - { - Dust dust = Dust.NewDustPerfect(Projectile.oldPos[i] + Projectile.Size * 0.5f, 261); - dust.position += (j / 7f * MathHelper.TwoPi).ToRotationVector2() * ((Projectile.oldPos.Length - i) * 1.2f + 3f); - dust.velocity = Vector2.Zero; - dust.scale = 0.6f; - dust.noGravity = true; - } - } - } - } + #endregion + + public override void OnSpawn(IEntitySource source) => DoVFXPulse(); public override bool? CanDamage() => false; public override bool PreDraw(ref Color lightColor) { - CalamityUtils.DrawAfterimagesCentered(Projectile, 0, Color.White, ProjectileID.Sets.TrailCacheLength[Projectile.type]); + Texture2D texture = ModContent.Request(Texture).Value; + Vector2 drawPosition = Projectile.Center - Main.screenPosition; + Rectangle frame = texture.Frame(1, Main.projFrames[Type], 0, Projectile.frame); + Vector2 origin = frame.Size() * 0.5f; + Main.EntitySpriteDraw(texture, drawPosition, frame, Projectile.GetAlpha(lightColor), Projectile.rotation, origin, Projectile.scale, SpriteEffects.None, 0); + Texture2D eyeTexture = ModContent.Request("CalamityMod/Projectiles/DraedonsArsenal/SnakeEye").Value; - Vector2 offsetVector = Utils.Vector2FromElipse(EyeRotation.ToRotationVector2(), Projectile.Size * 0.5f * EyeOutwardness); - Main.EntitySpriteDraw(eyeTexture, - Projectile.Center + offsetVector - Main.screenPosition, - null, - Color.White, - 0f, - eyeTexture.Size() * 0.5f, - 1f, - SpriteEffects.None, - 0); + Vector2 eyeDrawPosition = Projectile.Center - Main.screenPosition + EyeAngle.ToRotationVector2() * EyeOutwardness; + Main.EntitySpriteDraw(eyeTexture, eyeDrawPosition, null, Color.White, 0f, eyeTexture.Size() * 0.5f, 1f, SpriteEffects.None, 0); + return false; } } From 3457afbdac80cd495b30a23de265fa7853eeae1c Mon Sep 17 00:00:00 2001 From: Memes <114233643+Mr-Memes@users.noreply.github.com> Date: Tue, 29 Aug 2023 20:00:35 +0200 Subject: [PATCH 110/138] Final touch-ups to Snake Eyes. --- Items/Weapons/DraedonsArsenal/SnakeEyes.cs | 6 +++--- ...ityMod.Items.Weapons.DraedonsArsenal.hjson | 5 ++++- .../Mods.CalamityMod.Projectiles.Misc.hjson | 4 ++-- .../DraedonsArsenal/SnakeEyesProjectile.cs | 8 ++++---- .../DraedonsArsenal/SnakeEyesSummon.cs | 20 +++++++++---------- 5 files changed, 23 insertions(+), 20 deletions(-) diff --git a/Items/Weapons/DraedonsArsenal/SnakeEyes.cs b/Items/Weapons/DraedonsArsenal/SnakeEyes.cs index 13d1938b35..7d171cf708 100644 --- a/Items/Weapons/DraedonsArsenal/SnakeEyes.cs +++ b/Items/Weapons/DraedonsArsenal/SnakeEyes.cs @@ -1,10 +1,10 @@ -using CalamityMod.CustomRecipes; +using System; +using System.Collections.Generic; +using CalamityMod.CustomRecipes; using CalamityMod.Items.Materials; using CalamityMod.Projectiles.DraedonsArsenal; using CalamityMod.Rarities; using Microsoft.Xna.Framework; -using System; -using System.Collections.Generic; using Terraria; using Terraria.DataStructures; using Terraria.ID; diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson index 879b58bb79..e536965bed 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson @@ -164,7 +164,10 @@ SnakeEyes: { DisplayName: Snake Eyes Tooltip: ''' - Summons a mechanical surveillance drone that flies around enemies and mercilessly zaps them with electricity + Summons magnetic orbs to shred your foes with intense polarized energy + The orb will fire a single piercing beam that travels towards enemies + If the beam hits, the orb will teleport and deflect the projectile back + The deflected beam homes into enemies rapidly and explodes on impact [c/1FFBFF:'Equipped with high-end sensors, little can evade them. Even less are able to escape their ever watchful eyes.] [c/1FFBFF:An excellent bridge between my experiments with the sight-based soul powered machines and my latest project.'] ''' diff --git a/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson b/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson index 304236fe2f..0c5b855b66 100644 --- a/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson +++ b/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson @@ -45,6 +45,7 @@ UnstableMatter.DisplayName: Unstable Matter VoltageStream.DisplayName: Voltage Stream WavePounderBoom.DisplayName: Explosion WavePounderProjectile.DisplayName: Wave Pounder +SnakeEyesProjectile.DisplayName: Snake Eyes' Beam // Environmental AcidDrop.DisplayName: Acid BrimstoneGeyser.DisplayName: Smoke @@ -70,5 +71,4 @@ PlagueExplosionGas.DisplayName: Plague Gas PlagueShot.DisplayName: Plague Shot PlagueShotBuffer.DisplayName: Plague Shot WaterShot.DisplayName: Water Shot -WaterShotBuffer.DisplayName: Water Shot -SnakeEyesProjectile.DisplayName: Snake Eyes Projectile \ No newline at end of file +WaterShotBuffer.DisplayName: Water Shot \ No newline at end of file diff --git a/Projectiles/DraedonsArsenal/SnakeEyesProjectile.cs b/Projectiles/DraedonsArsenal/SnakeEyesProjectile.cs index f4f3166b21..2675611ef2 100644 --- a/Projectiles/DraedonsArsenal/SnakeEyesProjectile.cs +++ b/Projectiles/DraedonsArsenal/SnakeEyesProjectile.cs @@ -31,7 +31,7 @@ namespace CalamityMod.Projectiles.DraedonsArsenal public override void SetStaticDefaults() { ProjectileID.Sets.MinionShot[Type] = true; - + // While this projectile doesn't have afterimages, it keeps track of old positions for its primitive drawcode. ProjectileID.Sets.TrailingMode[Type] = 2; ProjectileID.Sets.TrailCacheLength[Type] = 6; @@ -92,10 +92,10 @@ namespace CalamityMod.Projectiles.DraedonsArsenal Projectile.timeLeft = 2; } - + for (int i = 0; i < 2; i++) { - Dust trailDust = Dust.NewDustDirect(Projectile.position, Projectile.width, Projectile.height, HasRedirected ? 261 : 226, Scale : HasRedirected ? 2f : .5f); + Dust trailDust = Dust.NewDustDirect(Projectile.position, Projectile.width, Projectile.height, HasRedirected ? 261 : 226, Scale: HasRedirected ? 2f : .5f); trailDust.velocity = Vector2.Zero; trailDust.noGravity = true; } @@ -132,7 +132,7 @@ namespace CalamityMod.Projectiles.DraedonsArsenal { if (!HasRedirected) return; - + Projectile.ExpandHitboxBy(300); Projectile.Damage(); diff --git a/Projectiles/DraedonsArsenal/SnakeEyesSummon.cs b/Projectiles/DraedonsArsenal/SnakeEyesSummon.cs index 9d9d6bd098..a789a53b17 100644 --- a/Projectiles/DraedonsArsenal/SnakeEyesSummon.cs +++ b/Projectiles/DraedonsArsenal/SnakeEyesSummon.cs @@ -19,7 +19,7 @@ namespace CalamityMod.Projectiles.DraedonsArsenal public Player Owner => Main.player[Projectile.owner]; public CalamityPlayer ModdedOwner => Owner.Calamity(); - public NPC Target => Owner.Center.MinionHoming(2000f, Owner); + public NPC Target => Owner.Center.MinionHoming(SnakeEyes.EnemyDistanceDetection, Owner); public enum AIState { @@ -52,7 +52,7 @@ namespace CalamityMod.Projectiles.DraedonsArsenal Projectile.minionSlots = 1f; Projectile.width = Projectile.height = 22; Projectile.penetrate = -1; - + Projectile.friendly = true; Projectile.minion = true; Projectile.tileCollide = false; @@ -64,9 +64,6 @@ namespace CalamityMod.Projectiles.DraedonsArsenal // Checks if the minion can still exist given the player's circumstance. CheckMinionExistence(); - // The minion does not use velocity at all, so to prevent AI breaks, velocity will always be 0. - Projectile.velocity = Vector2.Zero; - // The properties of the minion's pupil, it looks around the target if there's one and to the mouse if there isn't any. EyeAngle = Projectile.SafeDirectionTo((Target is not null) ? Target.Center : Main.MouseWorld).ToRotation(); EyeOutwardness = Utils.Remap(Projectile.Distance((Target is not null) ? Target.Center : Main.MouseWorld), 0f, 300f, 0f, 5f); @@ -96,16 +93,18 @@ namespace CalamityMod.Projectiles.DraedonsArsenal private void IdleState() { + AITimer += .01f; + // The projectile oscillates in place. - Projectile.Center += Vector2.UnitY * MathF.Sin(Main.GlobalTimeWrappedHourly) / 3f; - + Projectile.velocity.Y -= MathF.Cos(AITimer) / 350f; + // If the player's far enough from the minion, he'll teleport somewhere around the player. if (!Projectile.WithinRange(Owner.Center, 400f)) { Projectile.Center = Owner.Center + Main.rand.NextVector2Circular(300f, 300f); DoVFXPulse(); } - + if (Target is not null) SwitchAIState(AIState.Targetting); } @@ -172,7 +171,7 @@ namespace CalamityMod.Projectiles.DraedonsArsenal DoVFXPulse(); SoundEngine.PlaySound(SoundID.Item91 with { Volume = .8f, Pitch = .5f, PitchVariance = .1f }, Projectile.Center); - + HasShot = true; Projectile.netUpdate = true; } @@ -195,12 +194,13 @@ namespace CalamityMod.Projectiles.DraedonsArsenal private void SwitchAIState(AIState state) { State = state; - AITimer = 0f; HasTeleported = false; HasShot = false; RandomPosition = Vector2.Zero; + Projectile.velocity = Vector2.Zero; + DoVFXPulse(state == AIState.Redirecting); Projectile.netUpdate = true; From 759e273e9e6dfb641e1af0996a7d7106cf3c9765 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Tue, 29 Aug 2023 15:11:20 -0400 Subject: [PATCH 111/138] improved snake eyes tooltip --- .../Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson | 7 +++---- Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson index e536965bed..2330fb0490 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.DraedonsArsenal.hjson @@ -164,10 +164,9 @@ SnakeEyes: { DisplayName: Snake Eyes Tooltip: ''' - Summons magnetic orbs to shred your foes with intense polarized energy - The orb will fire a single piercing beam that travels towards enemies - If the beam hits, the orb will teleport and deflect the projectile back - The deflected beam homes into enemies rapidly and explodes on impact + Summons a levitating drone which fires piercing, highly calibrated energy bolts + If a bolt hits, the drone will teleport into its path and reflect the bolt + Reflected bolts home in and explode on impact [c/1FFBFF:'Equipped with high-end sensors, little can evade them. Even less are able to escape their ever watchful eyes.] [c/1FFBFF:An excellent bridge between my experiments with the sight-based soul powered machines and my latest project.'] ''' diff --git a/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson b/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson index 0c5b855b66..ca3c5b88d4 100644 --- a/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson +++ b/Localization/en-US/Mods.CalamityMod.Projectiles.Misc.hjson @@ -45,7 +45,7 @@ UnstableMatter.DisplayName: Unstable Matter VoltageStream.DisplayName: Voltage Stream WavePounderBoom.DisplayName: Explosion WavePounderProjectile.DisplayName: Wave Pounder -SnakeEyesProjectile.DisplayName: Snake Eyes' Beam +SnakeEyesProjectile.DisplayName: Inescapable Bolt // Environmental AcidDrop.DisplayName: Acid BrimstoneGeyser.DisplayName: Smoke From 8ec10b66f64730913cde8e7e84ab479e26cd0607 Mon Sep 17 00:00:00 2001 From: GinYuH Date: Tue, 29 Aug 2023 21:59:32 -0700 Subject: [PATCH 112/138] fixed levi using deadly sphere sounds --- NPCs/Leviathan/Leviathan.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NPCs/Leviathan/Leviathan.cs b/NPCs/Leviathan/Leviathan.cs index 926898b098..b0f2f01e1a 100644 --- a/NPCs/Leviathan/Leviathan.cs +++ b/NPCs/Leviathan/Leviathan.cs @@ -179,7 +179,7 @@ namespace CalamityMod.NPCs.Leviathan { SoundID.Zombie38, SoundID.Zombie39, - SoundID.Zombie49 + SoundID.Zombie40 }); if (soundDelay > 0) From 85b4719835ca816ee3a5a1a59dbd09b4a59a33f5 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Wed, 30 Aug 2023 12:10:49 -0400 Subject: [PATCH 113/138] removed materially false config comment --- Localization/en-US/Mods.CalamityMod.Configs.hjson | 1 - 1 file changed, 1 deletion(-) diff --git a/Localization/en-US/Mods.CalamityMod.Configs.hjson b/Localization/en-US/Mods.CalamityMod.Configs.hjson index f2f8a3ade9..e15c05bcc1 100644 --- a/Localization/en-US/Mods.CalamityMod.Configs.hjson +++ b/Localization/en-US/Mods.CalamityMod.Configs.hjson @@ -71,7 +71,6 @@ CalamityConfig: { ''' Gives the player a very weak dash by default that requires no equipment or items to use. This dash will be replaced by any other available dash, including those from other mods. - Calamity is balanced around this setting being enabled. ''' } From 845a2f8f4d0aa70183fd649a99cdfed659040e54 Mon Sep 17 00:00:00 2001 From: HaguriHat <141063931+HaguriHat@users.noreply.github.com> Date: Wed, 30 Aug 2023 13:44:49 -0300 Subject: [PATCH 114/138] Fixed some wording on Viruling's entry --- Localization/en-US/Mods.CalamityMod.Bestiary.hjson | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Bestiary.hjson b/Localization/en-US/Mods.CalamityMod.Bestiary.hjson index dfc3a10260..a59846bfb1 100644 --- a/Localization/en-US/Mods.CalamityMod.Bestiary.hjson +++ b/Localization/en-US/Mods.CalamityMod.Bestiary.hjson @@ -105,7 +105,7 @@ PestilentSlime: The virus hunts for any openings within one’s body to reprogra PlaguebringerMiniboss: Nothing can escape the Plague; everything is either assimilated or culled. Such is the case of queen bees. While strong enough to stave off plagued creatures, they are often forced to abandon their hives due to their subjects becoming infected. This leaves their larvae to be overtaken by nanites, and soon after, a plaguebringer is born. PlagueCharger: Spawn of the plaguebringers, these were born already taken by Draedon’s nanomachines. Nanites ensure they reach adulthood in a matter of hours by supercharging their aging process, even if this means their lifespan can be counted in days. Yet, this is exactly what makes them the perfect dispensable soldiers. Plagueshell: A turtle’s shell and nervous system are intertwined, making giant tortoises ideal targets for the Plague. Whatever pain is caused by the process of drilling into their shells is rapidly anesthetized, putting the tortoises under control without a single protest. -Viruling: Unlike derplings, who use their proboscis to drain the blood of other creatures, virulings use theirs by using it to inject the plague directly into their victims. Aside from the plaguebringers themselves, no creature is nearly as efficient at contaminating the local wildlife. +Viruling: Unlike derplings, who use their proboscis to drain the blood of other creatures, virulings use theirs to inject the plague directly into their victims. Aside from the plaguebringers themselves, no creature is nearly as efficient at contaminating the local wildlife. //Sulphur Sea Enemies AnthozoanCrab: Though disguised as simple rocks, they are capable of hurling entire boulders at creatures with ease, and will retreat swiftly if approached. Elsewhere, a creature such as this would thrive due to its might; yet in such a hostile environment as this, this much is required merely to survive. AquaticUrchin: Closely related to sea urchins, aquatic urchins have been forced to adapt to the acidic water and radioactive waste. Normally their venomous spikes would normally deter predators, but in the environment it lives in, a painful meal is still a meal. Nothing in this sea can afford to be a picky eater. @@ -189,4 +189,4 @@ StormWeaver: An invasive pest from another dimension crowned by many as king of SupremeCalamitas: After inheriting nigh limitless magical power as a mere teenager, she was recruited into Yharim’s army, where she served for nearly a decade. She reveled in the violence of it all, the endless dance of madness and death, allowing the Godseeker to wield her as a weapon in his endless war against the gods. But now that the fire inside her has died, all that remains are the smoldering embers of regret. SupremeCataclysm: The eldest of the three siblings, this brother was a brawler of great renown in Azafure, with few in the city being capable of matching his raw strength. He was protective of his sister, vowing to always be there for her in her times of need. The brother continues to fulfill this promise, even in death. SupremeCatastrophe: The middle child of the three siblings was a skilled swordsman in life, taking up mercenary work to put food on the table. Despite his rather bloody career choice, he did his best to be kind to his sister and keep her out of any danger his occupation could have put his remaining family in. He continues to defend her, even in death. -Yharon: Each dragon once wielded nigh limitless power over their domain, a fundamental power drawn directly from the world's fragmented soul. The dragons were masters of all; life, death, even the great Primordial Light that banishes the eternal night beyond. And yet, one of these majestic beings reached a height of power possibly second only to their king. He who made his kind eternal through his powers of Rebirth... and yet, even eternity did not last. \ No newline at end of file +Yharon: Each dragon once wielded nigh limitless power over their domain, a fundamental power drawn directly from the world's fragmented soul. The dragons were masters of all; life, death, even the great Primordial Light that banishes the eternal night beyond. And yet, one of these majestic beings reached a height of power possibly second only to their king. He who made his kind eternal through his powers of Rebirth... and yet, even eternity did not last. From b04f3f923f853d2d1f31b2c90e3eebc568fb72fe Mon Sep 17 00:00:00 2001 From: Xyk Date: Wed, 30 Aug 2023 13:06:55 -0700 Subject: [PATCH 115/138] Purity line bugfixes and changes Fixed lights on Ambrosial and Purity Fixed life regen based on lower health not working Changed jewel line to specify the extra defense is only while you have that extra debuff and buffed its defense Nerfed Purity defense bonus, but made it tick down slower Fixed standing still in honey not providing extra regen on honey dew and living dew Fixed purity regen on standing still not working and added visuals Made ambrosial regen on standing still not require honey and gave it a visual to match purity's --- CalPlayer/CalamityPlayerLifeRegen.cs | 41 ++++++++++++------- Items/Accessories/AmbrosialAmpoule.cs | 15 ++----- Items/Accessories/Purity.cs | 13 +----- Items/Accessories/RadiantOoze.cs | 10 +---- .../en-US/Mods.CalamityMod.Bestiary.hjson | 2 +- .../Mods.CalamityMod.Items.Accessories.hjson | 8 ++-- ...ods.CalamityMod.Items.Weapons.Ranged.hjson | 2 +- 7 files changed, 38 insertions(+), 53 deletions(-) diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index 831e0fafa7..afd8b5b602 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -411,6 +411,15 @@ namespace CalamityMod.CalPlayer Player.lifeRegen += 6; } + // Grant life regen based on missing health for Radiant Ooze, Ambrosial Ampule, and purity + if (rOoze || aAmpoule || purity) + { + float missingLifeRatio = (Player.statLifeMax2 - Player.statLife) / Player.statLifeMax2; + //Ambrosial Ampule and ooze give between 2 and 6 hp/s, Purity gives between 3 and 7 hp/s + float lifeRegenToGive = MathHelper.Lerp( purity ? 6f : 4f, purity ? 14f : 12f, missingLifeRatio); + Player.lifeRegen += (int)lifeRegenToGive; + } + if (purity) { int currentDebuffs = Player.buffType.Count(CalamityLists.debuffList.Contains); @@ -423,7 +432,9 @@ namespace CalamityMod.CalPlayer // Healing slows down after 5 seconds (300 frames) debuffed. For every 15 frames thereafter the cadence slows // There is no upper limit to how slow it can get and it can take a very long time to reset to normal int punishmentFrames = PurityHealSlowdownFrames - 300; - healFrameCadence += (punishmentFrames < 0) ? 0 : punishmentFrames / 15; + //lowest punishment is three full seconds between the one health heal + if (healFrameCadence < 180) + healFrameCadence += (punishmentFrames < 0) ? 0 : punishmentFrames / 15; if (Player.miscCounter % healFrameCadence == healFrameCadence - 1) Player.Heal(1); @@ -431,12 +442,12 @@ namespace CalamityMod.CalPlayer if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; - jewelBonusDefense = 40 + (currentDebuffs - 1) * 10; + jewelBonusDefense = 20 + (currentDebuffs - 1) * 12; // Count up total frames spent healing for slowdown. ++PurityHealSlowdownFrames; } - else if (Player.miscCounter % 20 == 0 && jewelBonusDefense > 0) //TODO reduce defense and put cooldown at 60 like infected jewel + else if (Player.miscCounter % 60 == 0 && jewelBonusDefense > 0) --jewelBonusDefense; // If the player is clear of all debuffs then gradually reduce the slowdown frames @@ -464,11 +475,11 @@ namespace CalamityMod.CalPlayer if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; - jewelBonusDefense = 16 + (currentDebuffs - 1) * 4; + jewelBonusDefense = 16 + (currentDebuffs - 1) * 8; } // Otherwise tick down the defense, one point per second - else if (Player.miscCounter % 60 == 0 && jewelBonusDefense > 0) + else if (Player.miscCounter % 20 == 0 && jewelBonusDefense > 0) --jewelBonusDefense; Player.statDefense += jewelBonusDefense; @@ -749,39 +760,39 @@ namespace CalamityMod.CalPlayer #region Standing Still Life Regen // Standing still healing bonuses (all are exclusive with vanilla Shiny Stone, but all function similarly) - if (!Player.shinyStone && Player.StandingStill() && Player.itemAnimation == 0) + if (!Player.shinyStone && Player.StandingStill() && Player.velocity.Y == 0 && Player.itemAnimation == 0) { - bool honeyDewWorking = honeyTurboRegen && Player.honey; - bool anyStandingStillLifeRegen = shadeRegen || cFreeze || honeyDewWorking || photosynthesis; + bool honeyDewWorking = honeyTurboRegen && Player.honeyWet; + bool anyStandingStillLifeRegen = shadeRegen || cFreeze || honeyDewWorking || photosynthesis || aAmpoule || purity; bool onlyPhotosynthesisAtNight = !shadeRegen && !cFreeze && !honeyDewWorking && photosynthesis && !Main.dayTime; // Divides all negative life regen by two before applying any other effects. if (anyStandingStillLifeRegen && Player.lifeRegen < 0) Player.lifeRegen /= 2; - // Spawn dust of some flavor while actually regenerating + // Spawn dust of some flavor while actually regenerating, aAmpule and purity have a slightly different looking style if (Player.lifeRegen > 0 && Player.statLife < actualMaxLife) { - int dustType = shadeRegen ? 173 : cFreeze ? 67 : honeyDewWorking ? DustID.Honey2 : photosynthesis ? 244 : -1; - bool dustSpawnRolled = Main.rand.Next(30000) < Player.lifeRegenTime || Main.rand.NextBool(30); + int dustType = shadeRegen ? 173 : cFreeze ? 67 : honeyDewWorking ? DustID.Honey2 : photosynthesis ? 244 : aAmpoule ? 228 : purity ? 187 : -1; + bool dustSpawnRolled = Main.rand.Next(30000) < Player.lifeRegenTime || purity ? Main.rand.NextBool(2) : aAmpoule ? Main.rand.NextBool(4) : Main.rand.NextBool(30); if (dustType != -1 && dustSpawnRolled) { - int regen = Dust.NewDust(Player.position, Player.width, Player.height, dustType, 0f, 0f, 200, default, 1f); + int regen = Dust.NewDust(Player.position, Player.width, Player.height, dustType, 0f, 0f, purity || aAmpoule ? 80 : 200, default, purity || aAmpoule ? 0.5f : 1f); Main.dust[regen].noGravity = true; Main.dust[regen].fadeIn = 1.3f; Vector2 velocity = CalamityUtils.RandomVelocity(100f, 50f, 100f, 0.04f); Main.dust[regen].velocity = velocity; velocity.Normalize(); - velocity *= 34f; + velocity *= purity || aAmpoule ? 55f : 34f; Main.dust[regen].position = Player.Center - velocity; } } // Actually apply "standing still" regeneration (the stats are granted even at full health) - float regenTimeNeededForTurboRegen = shadeRegen ? 40f : cFreeze ? 60f : honeyDewWorking ? 90f : photosynthesis ? 90f : -1f; + float regenTimeNeededForTurboRegen = shadeRegen ? 40f : cFreeze ? 60f : honeyDewWorking ? 90f : photosynthesis ? 90f : aAmpoule ? 90f : purity ? 60f : -1f; // 4 = vanilla Shiny Stone - int turboRegenPower = shadeRegen || cFreeze ? 4 : honeyDewWorking ? 3 : photosynthesis ? 1 : -1; + int turboRegenPower = shadeRegen || cFreeze || purity ? 4 : honeyDewWorking || aAmpoule ? 3 : photosynthesis ? 1 : -1; if (turboRegenPower > 0) { diff --git a/Items/Accessories/AmbrosialAmpoule.cs b/Items/Accessories/AmbrosialAmpoule.cs index 486893b49c..0836aa2a59 100644 --- a/Items/Accessories/AmbrosialAmpoule.cs +++ b/Items/Accessories/AmbrosialAmpoule.cs @@ -24,26 +24,17 @@ namespace CalamityMod.Items.Accessories CalamityPlayer modPlayer = player.Calamity(); player.statLifeMax2 += 70; - // Grant life regen based on missing health - if (!(modPlayer.rOoze || modPlayer.purity)) - { - float missingLifeRatio = (player.statLifeMax2 - player.statLife) / player.statLifeMax2; - float lifeRegenToGive = MathHelper.Lerp(4f, 12f, missingLifeRatio); - player.lifeRegen += (int)lifeRegenToGive; - } - - // bool left in for abyss light purposes + // bool left in for abyss light purposes and life regen effects modPlayer.aAmpoule = true; - // Inherits all effects of Honey Dew and Living Dew + // Inherits all effects of Honey Dew and Living Dew (except standing regen is not honey exclusive anymore) modPlayer.alwaysHoneyRegen = true; - modPlayer.honeyTurboRegen = true; modPlayer.honeyDewHalveDebuffs = true; modPlayer.livingDewHalveDebuffs = true; // Add light if the other accessories aren't equipped and visibility is turned on if (!(modPlayer.rOoze || modPlayer.purity) && !hideVisual) - Lighting.AddLight(player.Center, new Vector3(1.2f, 1.7f, 2.7f)); + Lighting.AddLight(player.Center, new Vector3(1.2f, 1.2f, 0.72f)); } public override void AddRecipes() diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index 01b3cae591..a0d2242d05 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -27,26 +27,17 @@ namespace CalamityMod.Items.Accessories CalamityPlayer modPlayer = player.Calamity(); player.statLifeMax2 += 100; - // Grant life regen based on missing health - if (!(modPlayer.rOoze || modPlayer.aAmpoule)) - { - float missingLifeRatio = (player.statLifeMax2 - player.statLife) / player.statLifeMax2; - float lifeRegenToGive = MathHelper.Lerp(6f, 14f, missingLifeRatio); - player.lifeRegen += (int)lifeRegenToGive; - } - - // Abyss light, debuff near-immunity, and massively enhances debuff halving + // Abyss light, debuff near-immunity, life regen effects, and massively enhances debuff halving modPlayer.purity = true; // Inherits effects from Honey Dew and Living Dew modPlayer.alwaysHoneyRegen = true; - modPlayer.honeyTurboRegen = true; modPlayer.honeyDewHalveDebuffs = true; modPlayer.livingDewHalveDebuffs = true; // Add light if the other accessories aren't equipped and visibility is turned on if (!(modPlayer.rOoze || modPlayer.aAmpoule) && !hideVisual) - Lighting.AddLight(player.Center, new Vector3(1.376f, 1.658f, 2.103f)); + Lighting.AddLight(player.Center, new Vector3(1.32f, 1.32f, 1.82f)); } public override void AddRecipes() diff --git a/Items/Accessories/RadiantOoze.cs b/Items/Accessories/RadiantOoze.cs index 6e71d23589..58f33eec38 100644 --- a/Items/Accessories/RadiantOoze.cs +++ b/Items/Accessories/RadiantOoze.cs @@ -23,15 +23,7 @@ namespace CalamityMod.Items.Accessories { CalamityPlayer modPlayer = player.Calamity(); - // Grant life regen based on missing health - if (!(modPlayer.aAmpoule || modPlayer.purity)) - { - float missingLifeRatio = (player.statLifeMax2 - player.statLife) / player.statLifeMax2; - float lifeRegenToGive = MathHelper.Lerp(4f, 12f, missingLifeRatio); - player.lifeRegen += (int)lifeRegenToGive; - } - - // bool left in for abyss light purposes + // bool left in for abyss light purposes and life regen effects modPlayer.rOoze = true; // Add light if the other accessories aren't equipped and visibility is turned on diff --git a/Localization/en-US/Mods.CalamityMod.Bestiary.hjson b/Localization/en-US/Mods.CalamityMod.Bestiary.hjson index a59846bfb1..77baa3201a 100644 --- a/Localization/en-US/Mods.CalamityMod.Bestiary.hjson +++ b/Localization/en-US/Mods.CalamityMod.Bestiary.hjson @@ -189,4 +189,4 @@ StormWeaver: An invasive pest from another dimension crowned by many as king of SupremeCalamitas: After inheriting nigh limitless magical power as a mere teenager, she was recruited into Yharim’s army, where she served for nearly a decade. She reveled in the violence of it all, the endless dance of madness and death, allowing the Godseeker to wield her as a weapon in his endless war against the gods. But now that the fire inside her has died, all that remains are the smoldering embers of regret. SupremeCataclysm: The eldest of the three siblings, this brother was a brawler of great renown in Azafure, with few in the city being capable of matching his raw strength. He was protective of his sister, vowing to always be there for her in her times of need. The brother continues to fulfill this promise, even in death. SupremeCatastrophe: The middle child of the three siblings was a skilled swordsman in life, taking up mercenary work to put food on the table. Despite his rather bloody career choice, he did his best to be kind to his sister and keep her out of any danger his occupation could have put his remaining family in. He continues to defend her, even in death. -Yharon: Each dragon once wielded nigh limitless power over their domain, a fundamental power drawn directly from the world's fragmented soul. The dragons were masters of all; life, death, even the great Primordial Light that banishes the eternal night beyond. And yet, one of these majestic beings reached a height of power possibly second only to their king. He who made his kind eternal through his powers of Rebirth... and yet, even eternity did not last. +Yharon: Each dragon once wielded nigh limitless power over their domain, a fundamental power drawn directly from the world's fragmented soul. The dragons were masters of all; life, death, even the great Primordial Light that banishes the eternal night beyond. And yet, one of these majestic beings reached a height of power possibly second only to their king. He who made his kind eternal through his powers of Rebirth... and yet, even eternity did not last. \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 74aacfd921..e81b68f4f0 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -118,7 +118,7 @@ AmbrosialAmpoule: { +70 max life Grants +2 to +6 HP/s life regen based on missing health Provides life regeneration equivalent to standing in Honey - Standing still in Honey grants extremely powerful regen + Standing still grants extremely powerful regen Halves how long you are afflicted with fire and sickness debuffs You emit yellow light if visibility is enabled ''' @@ -248,11 +248,11 @@ Purity: { Grants +3 to +7 HP/s life regen based on missing health Provides life regeneration equivalent to standing in Honey Standing still grants extremely powerful regen - Grants 40 defense and continuous healing while afflicted with any debuff + Grants 20 defense and continuous healing while afflicted with any debuff The healing eventually slows down if debuffed for an extended period of time Massively boosts natural life regen while afflicted with any debuff - Each debuff beyond the first grants 10 additional defense Granted defense fades away slowly when not afflicted with any debuffs + Each debuff beyond the first temporarily grants 12 additional defense while debuffed Makes weak damage over time debuffs harmless and halves the duration of all but the strongest debuffs You emit shining blue light if visibility is enabled 'A once putrid crystal, now glimmering with immaculate purity' @@ -366,8 +366,8 @@ InfectedJewel: { +1 HP/s life regen Grants 16 defense and +2 HP/s life regen while afflicted with any debuff Massively boosts natural life regen while afflicted with any debuff - Each debuff beyond the first grants 4 additional defense Granted defense fades away slowly when not afflicted with any debuffs + Each debuff beyond the first temporarily grants 8 additional defense while debuffed Makes the Astral Infection debuff harmless 'A beautiful gemstone tarnished by spaceborne rot' ''' diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson index 65e8c606eb..b40cc452aa 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson @@ -1285,4 +1285,4 @@ WulfrumBlunderbuss: { [c/83B87E:'The good thing about Wulfrum is that while it breaks fast, it can be reused even faster.] [c/83B87E:In fact, it is quite common for a robot to be turned into ammo right after it stops functioning.'] ''' -} +} \ No newline at end of file From ed00a6bb01da2b547975bdc7e0e3cec9e663062c Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Wed, 30 Aug 2023 16:40:08 -0400 Subject: [PATCH 116/138] Infected Jewel and Purity defense from multiple debuffs fades away properly --- CalPlayer/CalamityPlayerLifeRegen.cs | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index afd8b5b602..e6e8371b46 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -11,6 +11,7 @@ using CalamityMod.World; using Microsoft.Xna.Framework; using Terraria; using Terraria.DataStructures; +using Terraria.GameContent.ItemDropRules; using Terraria.ID; using Terraria.ModLoader; @@ -422,6 +423,7 @@ namespace CalamityMod.CalPlayer if (purity) { + int intendedPurityDefense = 0; int currentDebuffs = Player.buffType.Count(CalamityLists.debuffList.Contains); if (currentDebuffs > 0) { @@ -442,12 +444,17 @@ namespace CalamityMod.CalPlayer if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; - jewelBonusDefense = 20 + (currentDebuffs - 1) * 12; + intendedPurityDefense = 20 + (currentDebuffs - 1) * 12; + if (jewelBonusDefense < intendedPurityDefense) + jewelBonusDefense = intendedPurityDefense; // Count up total frames spent healing for slowdown. ++PurityHealSlowdownFrames; } - else if (Player.miscCounter % 60 == 0 && jewelBonusDefense > 0) + + // If the defense should be ticking down to some lower value, do that. + // Purity loses 1 point of defense every second. + if (Player.miscCounter % 60 == 0 && jewelBonusDefense > intendedPurityDefense) --jewelBonusDefense; // If the player is clear of all debuffs then gradually reduce the slowdown frames @@ -458,6 +465,7 @@ namespace CalamityMod.CalPlayer PurityHealSlowdownFrames = 0; } + // Actually apply defense bonus Player.statDefense += jewelBonusDefense; } @@ -468,6 +476,7 @@ namespace CalamityMod.CalPlayer // If the player has any debuffs, give the extra life regen and defense // More defense is given for each additional debuff + int intendedJewelDefense = 0; int currentDebuffs = Player.buffType.Count(CalamityLists.debuffList.Contains); if (currentDebuffs > 0) { @@ -475,13 +484,17 @@ namespace CalamityMod.CalPlayer if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; - jewelBonusDefense = 16 + (currentDebuffs - 1) * 8; + intendedJewelDefense = 16 + (currentDebuffs - 1) * 8; + if (jewelBonusDefense < intendedJewelDefense) + jewelBonusDefense = intendedJewelDefense; } - // Otherwise tick down the defense, one point per second - else if (Player.miscCounter % 20 == 0 && jewelBonusDefense > 0) + // If the defense should be ticking down to some lower value, do that. + // Infected Jewel loses 1 point of defense every 20 frames. + if (Player.miscCounter % 20 == 0 && jewelBonusDefense > intendedJewelDefense) --jewelBonusDefense; + // Actually apply defense bonus Player.statDefense += jewelBonusDefense; } From 7bee71d3fccde5f4045eb121209ee7653554dd35 Mon Sep 17 00:00:00 2001 From: Ozzatron Date: Wed, 30 Aug 2023 16:43:06 -0400 Subject: [PATCH 117/138] fix infected jewel and purity localization issues --- Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index e81b68f4f0..413bf28da2 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -251,8 +251,8 @@ Purity: { Grants 20 defense and continuous healing while afflicted with any debuff The healing eventually slows down if debuffed for an extended period of time Massively boosts natural life regen while afflicted with any debuff + Each debuff beyond the first grants 12 additional defense Granted defense fades away slowly when not afflicted with any debuffs - Each debuff beyond the first temporarily grants 12 additional defense while debuffed Makes weak damage over time debuffs harmless and halves the duration of all but the strongest debuffs You emit shining blue light if visibility is enabled 'A once putrid crystal, now glimmering with immaculate purity' @@ -366,8 +366,8 @@ InfectedJewel: { +1 HP/s life regen Grants 16 defense and +2 HP/s life regen while afflicted with any debuff Massively boosts natural life regen while afflicted with any debuff - Granted defense fades away slowly when not afflicted with any debuffs - Each debuff beyond the first temporarily grants 8 additional defense while debuffed + Granted defense fades away quickly when not afflicted with any debuffs + Each debuff beyond the first grants 8 additional defense Makes the Astral Infection debuff harmless 'A beautiful gemstone tarnished by spaceborne rot' ''' From 9989e5154e88acb3d6ac3a2bc9efcc18ef2431bc Mon Sep 17 00:00:00 2001 From: Xyk Date: Wed, 30 Aug 2023 14:46:49 -0700 Subject: [PATCH 118/138] Jewel and purity defense adjustment fixed a mistake from earlier 12 bonus to 8 on purity 8 bonus to 5 on infected jewel both tick down once a second --- CalPlayer/CalamityPlayerLifeRegen.cs | 6 +++--- Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/CalPlayer/CalamityPlayerLifeRegen.cs b/CalPlayer/CalamityPlayerLifeRegen.cs index e6e8371b46..b904ffeb75 100644 --- a/CalPlayer/CalamityPlayerLifeRegen.cs +++ b/CalPlayer/CalamityPlayerLifeRegen.cs @@ -444,7 +444,7 @@ namespace CalamityMod.CalPlayer if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; - intendedPurityDefense = 20 + (currentDebuffs - 1) * 12; + intendedPurityDefense = 20 + (currentDebuffs - 1) * 8; if (jewelBonusDefense < intendedPurityDefense) jewelBonusDefense = intendedPurityDefense; @@ -484,14 +484,14 @@ namespace CalamityMod.CalPlayer if (Player.lifeRegenTime < 1800) Player.lifeRegenTime = 1800; - intendedJewelDefense = 16 + (currentDebuffs - 1) * 8; + intendedJewelDefense = 16 + (currentDebuffs - 1) * 5; if (jewelBonusDefense < intendedJewelDefense) jewelBonusDefense = intendedJewelDefense; } // If the defense should be ticking down to some lower value, do that. // Infected Jewel loses 1 point of defense every 20 frames. - if (Player.miscCounter % 20 == 0 && jewelBonusDefense > intendedJewelDefense) + if (Player.miscCounter % 60 == 0 && jewelBonusDefense > intendedJewelDefense) --jewelBonusDefense; // Actually apply defense bonus diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 413bf28da2..0b7b5e55d1 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -251,7 +251,7 @@ Purity: { Grants 20 defense and continuous healing while afflicted with any debuff The healing eventually slows down if debuffed for an extended period of time Massively boosts natural life regen while afflicted with any debuff - Each debuff beyond the first grants 12 additional defense + Each debuff beyond the first grants 8 additional defense Granted defense fades away slowly when not afflicted with any debuffs Makes weak damage over time debuffs harmless and halves the duration of all but the strongest debuffs You emit shining blue light if visibility is enabled @@ -367,7 +367,7 @@ InfectedJewel: { Grants 16 defense and +2 HP/s life regen while afflicted with any debuff Massively boosts natural life regen while afflicted with any debuff Granted defense fades away quickly when not afflicted with any debuffs - Each debuff beyond the first grants 8 additional defense + Each debuff beyond the first grants 5 additional defense Makes the Astral Infection debuff harmless 'A beautiful gemstone tarnished by spaceborne rot' ''' From 110fa8ca05495ba7b5acd1be37255827a7721610 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Wed, 30 Aug 2023 18:21:15 -0400 Subject: [PATCH 119/138] Nerfed Pulse Rifle's damage more, as after testing it out of curiosity it's still way too good --- Items/Weapons/DraedonsArsenal/PulseRifle.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/DraedonsArsenal/PulseRifle.cs b/Items/Weapons/DraedonsArsenal/PulseRifle.cs index e4afc89dbc..d2684920b4 100644 --- a/Items/Weapons/DraedonsArsenal/PulseRifle.cs +++ b/Items/Weapons/DraedonsArsenal/PulseRifle.cs @@ -19,7 +19,7 @@ namespace CalamityMod.Items.Weapons.DraedonsArsenal public new string LocalizationCategory => "Items.Weapons.DraedonsArsenal"; public static readonly SoundStyle FireSound = new("CalamityMod/Sounds/Item/PulseRifleFire"); - private int BaseDamage = 1280; + private int BaseDamage = 1200; public override void SetDefaults() { From af31478d4b02ea3b2b7b0c48daad88196930125e Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Wed, 30 Aug 2023 19:28:34 -0400 Subject: [PATCH 120/138] Simplified Starmageddon's recipe (forgot to do this earlier whoops) --- Items/Weapons/Ranged/Starmageddon.cs | 3 --- 1 file changed, 3 deletions(-) diff --git a/Items/Weapons/Ranged/Starmageddon.cs b/Items/Weapons/Ranged/Starmageddon.cs index 07cf6bbe9a..078ca87605 100644 --- a/Items/Weapons/Ranged/Starmageddon.cs +++ b/Items/Weapons/Ranged/Starmageddon.cs @@ -55,11 +55,8 @@ namespace CalamityMod.Items.Weapons.Ranged { CreateRecipe(). AddIngredient(). - AddIngredient(). AddIngredient(). - AddIngredient(). AddIngredient(5). - AddIngredient(10). AddIngredient(10). AddIngredient(15). AddTile(ModContent.TileType()). From a3b100fa21c083484a4198b5c707168d739d68b0 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Wed, 30 Aug 2023 19:53:42 -0400 Subject: [PATCH 121/138] Buffed Starmageddon's damage, and main projectile is now exempt from pierce resist --- CalamityLists.cs | 1 + Items/Weapons/Ranged/Starmageddon.cs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CalamityLists.cs b/CalamityLists.cs index 77d91932d9..f9d71c9bb7 100644 --- a/CalamityLists.cs +++ b/CalamityLists.cs @@ -2040,6 +2040,7 @@ namespace CalamityMod ProjectileType(), ProjectileType(), ProjectileType(), + ProjectileType(), }; // Lists of enemies that resist piercing to some extent (mostly worms). diff --git a/Items/Weapons/Ranged/Starmageddon.cs b/Items/Weapons/Ranged/Starmageddon.cs index 078ca87605..d27be3cc48 100644 --- a/Items/Weapons/Ranged/Starmageddon.cs +++ b/Items/Weapons/Ranged/Starmageddon.cs @@ -18,7 +18,7 @@ namespace CalamityMod.Items.Weapons.Ranged public override void SetDefaults() { - Item.damage = 90; + Item.damage = 100; Item.knockBack = 4f; Item.shootSpeed = 16f; Item.useStyle = ItemUseStyleID.Shoot; From 12361d0240f02f62cda803039819f4398f33b9c5 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Wed, 30 Aug 2023 21:11:44 -0400 Subject: [PATCH 122/138] I have concluded that allowing Elemental Shiv's extra projectiles to pierce was a mistake --- Projectiles/Melee/SHIV.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Projectiles/Melee/SHIV.cs b/Projectiles/Melee/SHIV.cs index 2283f9cf48..d940fd634a 100644 --- a/Projectiles/Melee/SHIV.cs +++ b/Projectiles/Melee/SHIV.cs @@ -19,13 +19,11 @@ namespace CalamityMod.Projectiles.Melee Projectile.height = 20; Projectile.friendly = true; Projectile.DamageType = DamageClass.Melee; - Projectile.penetrate = 2; + Projectile.penetrate = 1; Projectile.tileCollide = false; Projectile.timeLeft = 90; Projectile.aiStyle = ProjAIStyleID.Beam; Projectile.extraUpdates = 1; - Projectile.usesLocalNPCImmunity = true; - Projectile.localNPCHitCooldown = -1; } public override void AI() From 96f9795b18b60de4c98ba35e51d6aa403442274e Mon Sep 17 00:00:00 2001 From: Done2222 Date: Thu, 31 Aug 2023 09:47:35 +0300 Subject: [PATCH 123/138] Heavenly Gale nerf --- Items/Weapons/Ranged/HeavenlyGale.cs | 4 ++-- .../en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Ranged/HeavenlyGale.cs b/Items/Weapons/Ranged/HeavenlyGale.cs index c1675b64ba..0cafcf0831 100644 --- a/Items/Weapons/Ranged/HeavenlyGale.cs +++ b/Items/Weapons/Ranged/HeavenlyGale.cs @@ -38,7 +38,7 @@ namespace CalamityMod.Items.Weapons.Ranged public override void SetDefaults() { - Item.damage = 300; + Item.damage = 221; Item.DamageType = DamageClass.Ranged; Item.width = 138; Item.height = 176; @@ -76,4 +76,4 @@ namespace CalamityMod.Items.Weapons.Ranged Register(); } } -} \ No newline at end of file +} diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson index 65e8c606eb..b40cc452aa 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson @@ -1285,4 +1285,4 @@ WulfrumBlunderbuss: { [c/83B87E:'The good thing about Wulfrum is that while it breaks fast, it can be reused even faster.] [c/83B87E:In fact, it is quite common for a robot to be turned into ammo right after it stops functioning.'] ''' -} +} \ No newline at end of file From b3b59328bc34ce0d100bfc0a9aa709656a0d51d1 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Thu, 31 Aug 2023 09:50:36 +0300 Subject: [PATCH 124/138] Revert "Heavenly Gale nerf" This reverts commit 96f9795b18b60de4c98ba35e51d6aa403442274e. --- Items/Weapons/Ranged/HeavenlyGale.cs | 4 ++-- .../en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Ranged/HeavenlyGale.cs b/Items/Weapons/Ranged/HeavenlyGale.cs index 0cafcf0831..c1675b64ba 100644 --- a/Items/Weapons/Ranged/HeavenlyGale.cs +++ b/Items/Weapons/Ranged/HeavenlyGale.cs @@ -38,7 +38,7 @@ namespace CalamityMod.Items.Weapons.Ranged public override void SetDefaults() { - Item.damage = 221; + Item.damage = 300; Item.DamageType = DamageClass.Ranged; Item.width = 138; Item.height = 176; @@ -76,4 +76,4 @@ namespace CalamityMod.Items.Weapons.Ranged Register(); } } -} +} \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson index b40cc452aa..65e8c606eb 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson @@ -1285,4 +1285,4 @@ WulfrumBlunderbuss: { [c/83B87E:'The good thing about Wulfrum is that while it breaks fast, it can be reused even faster.] [c/83B87E:In fact, it is quite common for a robot to be turned into ammo right after it stops functioning.'] ''' -} \ No newline at end of file +} From 8e0559facee931751097c56fce3e247f2e0dd7eb Mon Sep 17 00:00:00 2001 From: Done2222 Date: Thu, 31 Aug 2023 09:50:57 +0300 Subject: [PATCH 125/138] Heavenly Gale nerf --- Items/Weapons/Ranged/HeavenlyGale.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Items/Weapons/Ranged/HeavenlyGale.cs b/Items/Weapons/Ranged/HeavenlyGale.cs index c1675b64ba..0cafcf0831 100644 --- a/Items/Weapons/Ranged/HeavenlyGale.cs +++ b/Items/Weapons/Ranged/HeavenlyGale.cs @@ -38,7 +38,7 @@ namespace CalamityMod.Items.Weapons.Ranged public override void SetDefaults() { - Item.damage = 300; + Item.damage = 221; Item.DamageType = DamageClass.Ranged; Item.width = 138; Item.height = 176; @@ -76,4 +76,4 @@ namespace CalamityMod.Items.Weapons.Ranged Register(); } } -} \ No newline at end of file +} From 1ad426a735c21cd1d7242dcd6b08df75e0147586 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Thu, 31 Aug 2023 10:39:17 +0300 Subject: [PATCH 126/138] for some reason i suggested putting this at 130 even though i wrote 162 on my notes --- Items/Weapons/Ranged/DragonsBreath.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/DragonsBreath.cs b/Items/Weapons/Ranged/DragonsBreath.cs index d412ddaefb..7faa5af5dc 100644 --- a/Items/Weapons/Ranged/DragonsBreath.cs +++ b/Items/Weapons/Ranged/DragonsBreath.cs @@ -26,7 +26,7 @@ namespace CalamityMod.Items.Weapons.Ranged public override void SetDefaults() { - Item.damage = 130; + Item.damage = 162; Item.DamageType = DamageClass.Ranged; Item.width = 124; Item.height = 78; From 0e0c893162e6abd868d1ddfa739fdce51187359e Mon Sep 17 00:00:00 2001 From: Done2222 Date: Thu, 31 Aug 2023 13:25:59 +0300 Subject: [PATCH 127/138] The Sponge tooltip fix --- Items/Weapons/Ranged/DragonsBreath.cs | 1 - Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/Items/Weapons/Ranged/DragonsBreath.cs b/Items/Weapons/Ranged/DragonsBreath.cs index 7faa5af5dc..7998f6fe0d 100644 --- a/Items/Weapons/Ranged/DragonsBreath.cs +++ b/Items/Weapons/Ranged/DragonsBreath.cs @@ -30,7 +30,6 @@ namespace CalamityMod.Items.Weapons.Ranged Item.DamageType = DamageClass.Ranged; Item.width = 124; Item.height = 78; - Item.useTime = 9; Item.useAnimation = 18; Item.reuseDelay = BetweenShotsPause; diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 0b7b5e55d1..c678c3afb6 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -1818,7 +1818,7 @@ TheSponge: { ''' Projects a quantum foam barrier that absorbs up to 180 damage The barrier grants 30 defense and reduces damage taken by 30% while active - The barrier starts recharging 6 seconds after being hit + The barrier starts recharging 9 seconds after being hit Recharging from zero to full charge takes 6 seconds Being hit again while recharging restarts the charge timer The barrier's color will change to match your team selection as needed From 8120bc52c53eb39b3d9921e6d1e02341f62db027 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <142704082+CongratsIsTrash@users.noreply.github.com> Date: Thu, 31 Aug 2023 09:33:26 -0400 Subject: [PATCH 128/138] Buffed Sand Sharknado Staff because it got completely butchered in 2.0.3 for whatever reason --- Items/Weapons/Summon/SandSharknadoStaff.cs | 6 +++--- Projectiles/Summon/MiniSandShark.cs | 11 +++++++++++ 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/Items/Weapons/Summon/SandSharknadoStaff.cs b/Items/Weapons/Summon/SandSharknadoStaff.cs index 568f0131ee..61b24397f4 100644 --- a/Items/Weapons/Summon/SandSharknadoStaff.cs +++ b/Items/Weapons/Summon/SandSharknadoStaff.cs @@ -11,17 +11,17 @@ namespace CalamityMod.Items.Weapons.Summon public class SandSharknadoStaff : ModItem, ILocalizedModType { public new string LocalizationCategory => "Items.Weapons.Summon"; - #region Other stats for easy modifcation + #region Other stats for easy modification public const float ProjVel = 30f; - public const float FireSpeed = 120f; // In frames. 60 frames = 2 seconds. + public const float FireSpeed = 50f; // In frames. 60 frames = 1 second. #endregion public override void SetDefaults() { - Item.damage = 47; + Item.damage = 55; Item.knockBack = 2f; Item.mana = 10; diff --git a/Projectiles/Summon/MiniSandShark.cs b/Projectiles/Summon/MiniSandShark.cs index a71818b08e..ad08daaaf9 100644 --- a/Projectiles/Summon/MiniSandShark.cs +++ b/Projectiles/Summon/MiniSandShark.cs @@ -22,6 +22,7 @@ namespace CalamityMod.Projectiles.Summon Projectile.minion = true; Projectile.friendly = true; Projectile.ignoreWater = true; + Projectile.extraUpdates = 1; Projectile.DamageType = DamageClass.Summon; } @@ -34,6 +35,16 @@ namespace CalamityMod.Projectiles.Summon public override void Kill(int timeLeft) // When the projectile hits an enemy, it'll make a dust impact effect. { + Projectile.position = Projectile.Center; + Projectile.width = Projectile.height = 64; + Projectile.position.X = Projectile.position.X - (float)(Projectile.width / 2); + Projectile.position.Y = Projectile.position.Y - (float)(Projectile.height / 2); + Projectile.maxPenetrate = -1; + Projectile.penetrate = -1; + Projectile.usesLocalNPCImmunity = true; + Projectile.localNPCHitCooldown = 10; + Projectile.damage = (int)(Projectile.damage * 0.75f); + Projectile.Damage(); SoundEngine.PlaySound(SoundID.Item14, Projectile.position); for (int dustIndex = 0; dustIndex < 36; dustIndex++) { From bf69a301dec14d4f3f222478cd8431d0987422d9 Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <1q2w3e4dasd@gmail.com> Date: Thu, 31 Aug 2023 12:25:34 -0400 Subject: [PATCH 129/138] Further Sand Sharknado changes --- Items/Weapons/Summon/SandSharknadoStaff.cs | 4 ++-- Projectiles/Summon/MiniSandShark.cs | 3 ++- Projectiles/Summon/SandnadoMinion.cs | 9 +++++++-- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/Items/Weapons/Summon/SandSharknadoStaff.cs b/Items/Weapons/Summon/SandSharknadoStaff.cs index 61b24397f4..95807064b4 100644 --- a/Items/Weapons/Summon/SandSharknadoStaff.cs +++ b/Items/Weapons/Summon/SandSharknadoStaff.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Summon public new string LocalizationCategory => "Items.Weapons.Summon"; #region Other stats for easy modification - public const float ProjVel = 30f; + public const float ProjSpeed = 30f; public const float FireSpeed = 50f; // In frames. 60 frames = 1 second. @@ -21,7 +21,7 @@ namespace CalamityMod.Items.Weapons.Summon public override void SetDefaults() { - Item.damage = 55; + Item.damage = 47; Item.knockBack = 2f; Item.mana = 10; diff --git a/Projectiles/Summon/MiniSandShark.cs b/Projectiles/Summon/MiniSandShark.cs index ad08daaaf9..939e5d60a1 100644 --- a/Projectiles/Summon/MiniSandShark.cs +++ b/Projectiles/Summon/MiniSandShark.cs @@ -23,6 +23,7 @@ namespace CalamityMod.Projectiles.Summon Projectile.friendly = true; Projectile.ignoreWater = true; Projectile.extraUpdates = 1; + Projectile.tileCollide = false; Projectile.DamageType = DamageClass.Summon; } @@ -43,7 +44,7 @@ namespace CalamityMod.Projectiles.Summon Projectile.penetrate = -1; Projectile.usesLocalNPCImmunity = true; Projectile.localNPCHitCooldown = 10; - Projectile.damage = (int)(Projectile.damage * 0.75f); + Projectile.damage = (int)(Projectile.damage * 0.6f); Projectile.Damage(); SoundEngine.PlaySound(SoundID.Item14, Projectile.position); for (int dustIndex = 0; dustIndex < 36; dustIndex++) diff --git a/Projectiles/Summon/SandnadoMinion.cs b/Projectiles/Summon/SandnadoMinion.cs index 364096e900..d2356c97a6 100644 --- a/Projectiles/Summon/SandnadoMinion.cs +++ b/Projectiles/Summon/SandnadoMinion.cs @@ -143,11 +143,16 @@ namespace CalamityMod.Projectiles.Summon public void ShootTarget(NPC target) { - if (TimerForShooting == SandSharknadoStaff.FireSpeed && Main.myPlayer == Projectile.owner) + int randomDelay = Main.rand.Next(-5, 6); + Vector2 targetPos = target.Center; + Vector2 ProjVel = targetPos - Projectile.Center; + ProjVel.Normalize(); + ProjVel *= SandSharknadoStaff.ProjSpeed; + if (TimerForShooting == SandSharknadoStaff.FireSpeed + randomDelay && Main.myPlayer == Projectile.owner) { int sandSharkProj = Projectile.NewProjectile(Projectile.GetSource_FromThis(), Projectile.Center, - CalamityUtils.CalculatePredictiveAimToTarget(Projectile.Center, target, SandSharknadoStaff.ProjVel), + ProjVel, ModContent.ProjectileType(), Projectile.damage, Projectile.knockBack, From 953463d32ba5bc11c4c6b759055668cc27793882 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Thu, 31 Aug 2023 19:26:12 +0300 Subject: [PATCH 130/138] Blossom Flux nerf (20 -> 14) --- Items/Weapons/Ranged/BlossomFlux.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/BlossomFlux.cs b/Items/Weapons/Ranged/BlossomFlux.cs index 5ce6e69dcb..08bf441c83 100644 --- a/Items/Weapons/Ranged/BlossomFlux.cs +++ b/Items/Weapons/Ranged/BlossomFlux.cs @@ -17,7 +17,7 @@ namespace CalamityMod.Items.Weapons.Ranged public override void SetDefaults() { - Item.damage = 20; + Item.damage = 14; Item.DamageType = DamageClass.Ranged; Item.width = 38; Item.height = 68; From 5a32cff13594c1e07edd4a7be1b0bd123c750181 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Thu, 31 Aug 2023 22:04:52 +0300 Subject: [PATCH 131/138] Hoarfrost Bow and Herring Staff nerfs --- Items/Weapons/Ranged/HoarfrostBow.cs | 2 +- Items/Weapons/Summon/HerringStaff.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Items/Weapons/Ranged/HoarfrostBow.cs b/Items/Weapons/Ranged/HoarfrostBow.cs index 80a9e04a96..9f290e1709 100644 --- a/Items/Weapons/Ranged/HoarfrostBow.cs +++ b/Items/Weapons/Ranged/HoarfrostBow.cs @@ -13,7 +13,7 @@ namespace CalamityMod.Items.Weapons.Ranged public new string LocalizationCategory => "Items.Weapons.Ranged"; public override void SetDefaults() { - Item.damage = 56; + Item.damage = 37; Item.DamageType = DamageClass.Ranged; Item.width = 26; Item.height = 70; diff --git a/Items/Weapons/Summon/HerringStaff.cs b/Items/Weapons/Summon/HerringStaff.cs index 4f18837d2d..28fdad0288 100644 --- a/Items/Weapons/Summon/HerringStaff.cs +++ b/Items/Weapons/Summon/HerringStaff.cs @@ -12,7 +12,7 @@ namespace CalamityMod.Items.Weapons.Summon public new string LocalizationCategory => "Items.Weapons.Summon"; public override void SetDefaults() { - Item.damage = 17; + Item.damage = 15; Item.knockBack = 1.25f; Item.mana = 10; From f68e7b17c930b3544f7154131e6ea8e88ab6fee8 Mon Sep 17 00:00:00 2001 From: Xyk Date: Thu, 31 Aug 2023 13:25:51 -0700 Subject: [PATCH 132/138] Life regen phrasing changes made almost everything cal changes about regen in vanilla say HP/s instead and made all calamity items and buffs use HP/s as well (the stuff Ozz missed) Only exception is OOA armors, but they don't originally specify regen given so I'm not gonna change it --- Items/CalamityGlobalItemTooltip.cs | 14 ++++---- .../en-US/Mods.CalamityMod.Buffs.hjson | 8 ++--- .../Mods.CalamityMod.Items.Accessories.hjson | 2 +- .../Mods.CalamityMod.Items.Potions.hjson | 32 +++++++++---------- ...Mods.CalamityMod.Items.Weapons.Rogue.hjson | 2 +- 5 files changed, 29 insertions(+), 29 deletions(-) diff --git a/Items/CalamityGlobalItemTooltip.cs b/Items/CalamityGlobalItemTooltip.cs index c7ebc3d180..7ce3b741ee 100644 --- a/Items/CalamityGlobalItemTooltip.cs +++ b/Items/CalamityGlobalItemTooltip.cs @@ -442,7 +442,7 @@ namespace CalamityMod.Items // Palladium if (item.type == ItemID.PalladiumSword || item.type == ItemID.PalladiumPike) - EditTooltipByName("Knockback", (line) => line.Text += "\nIncreases life regen on hit"); + EditTooltipByName("Knockback", (line) => line.Text += "\nIncreases natural life regen on hit"); // Mythril if (item.type == ItemID.MythrilSword || item.type == ItemID.MythrilHalberd) @@ -588,7 +588,7 @@ namespace CalamityMod.Items // Fairy Boots buff. if (item.type == ItemID.FairyBoots) EditTooltipByNum(2, (line) => line.Text += "\nFairies can spawn at any time on the surface and spawn far more frequently\n" + - "Nearby fairies grant increased life regen, defense and movement speed\n" + + "Nearby fairies grant +2 HP/s life regen, 10 defense and 10% movement speed\n" + "Fairies are immune to damage and will no longer flee"); // Armor Crunch immunity pre-Golem. @@ -729,7 +729,7 @@ namespace CalamityMod.Items if (item.type == ItemID.TinHelmet) AddTooltip("3% increased critical strike chance"); if (item.type == ItemID.TinChainmail) - AddTooltip("+1 life regen"); + AddTooltip("+0.5 HP/s life regen"); if (item.type == ItemID.TinGreaves) AddTooltip("5% increased movement speed"); @@ -745,7 +745,7 @@ namespace CalamityMod.Items if (item.type == ItemID.SilverHelmet) AddTooltip("5% increased critical strike chance"); if (item.type == ItemID.SilverChainmail) - AddTooltip("+2 life regen"); + AddTooltip("+1 HP/s life regen"); if (item.type == ItemID.SilverGreaves) AddTooltip("8% increased movement speed"); @@ -753,7 +753,7 @@ namespace CalamityMod.Items if (item.type == ItemID.TungstenHelmet) AddTooltip("7% increased damage"); if (item.type == ItemID.TungstenChainmail) - AddTooltip("+1 life regen"); + AddTooltip("+0.5 HP/s life regen"); if (item.type == ItemID.TungstenGreaves) AddTooltip("8% increased movement speed"); @@ -782,7 +782,7 @@ namespace CalamityMod.Items { EditTooltipByNum(0, (line) => { string newTooltip = line.Text.Replace("2%", "5%"); - newTooltip += "\n+1 life regen"; + newTooltip += "\n+0.5 HP/s life regen"; line.Text = newTooltip; }); } @@ -945,7 +945,7 @@ namespace CalamityMod.Items AddWingStats(3f, 1f, 0, 25); if (item.type == ItemID.AngelWings) - AddWingStats(6.25f, 1f, 1, 100, "+20 max life, +10 defense and +2 life regen"); + AddWingStats(6.25f, 1f, 1, 100, "+20 max life, +10 defense and +1 HP/s life regen"); if (item.type == ItemID.DemonWings) AddWingStats(6.25f, 1f, 1, 100, "5% increased damage and critical strike chance"); diff --git a/Localization/en-US/Mods.CalamityMod.Buffs.hjson b/Localization/en-US/Mods.CalamityMod.Buffs.hjson index d352342248..83f5f3c1ea 100644 --- a/Localization/en-US/Mods.CalamityMod.Buffs.hjson +++ b/Localization/en-US/Mods.CalamityMod.Buffs.hjson @@ -754,7 +754,7 @@ KamiBuff: { Mushy: { DisplayName: Mushy - Description: Increased defense by 6 and life regen by 2 + Description: Increased defense by 6 and life regen by 1HP/s } PhantomicEmpowerment: { @@ -1479,12 +1479,12 @@ WulfrumDroidBuff: { PinkJellyRegen: { DisplayName: Pink Jelly Regen - Description: The power of goo refreshes you, life regen increased by 4 + Description: The power of goo refreshes you, life regen increased by 2HP/s } GreenJellyRegen: { DisplayName: Green Jelly Regen - Description: The regenerative goo empowers you, life regen increased by 5 + Description: The regenerative goo empowers you, life regen increased by 2.5HP/s } AbsorberRegen: { @@ -1492,7 +1492,7 @@ AbsorberRegen: { Description: ''' You are blessed by the culmimation of nature's powers - Life regen increased by 6, damage increased by 8%, damage reduction increased by 5% + Life regen increased by 3HP/s, damage increased by 8%, damage reduction increased by 5% ''' } diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index c678c3afb6..2153fdf732 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -799,7 +799,7 @@ FungalSymbiote: { Tooltip: ''' You grow mushrooms on the grass beneath you - Consuming mushrooms provides the Mushy buff, increasing defense by 6 and granting 0.5 HP/s life regen + Consuming mushrooms provides the Mushy buff, increasing defense by 6 and granting 1 HP/s life regen All mushroom-based weapons deal 10% more damage and emit non-damaging mushrooms ''' } diff --git a/Localization/en-US/Mods.CalamityMod.Items.Potions.hjson b/Localization/en-US/Mods.CalamityMod.Items.Potions.hjson index b694abfb31..b1e804aab3 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Potions.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Potions.hjson @@ -180,7 +180,7 @@ BloodyMary: { Tooltip: ''' 10% increased damage and movement speed during a Blood Moon - Reduces life regen by 4 and defense by 4% + Reduces life regen by 2 HP/s and defense by 4% [c/B00BA5:'Extra spicy... and bloody!'] ''' } @@ -189,7 +189,7 @@ CaribbeanRum: { DisplayName: Caribbean Rum Tooltip: ''' - Increases life regen by 2, movement speed by 10% and wing flight time by 20% + Increases life regen by 1 HP/s, movement speed by 10% and wing flight time by 20% Makes you floaty and reduces defense by 10% [c/B00BA5:'Why is the rum gone?'] ''' @@ -210,7 +210,7 @@ Everclear: { Tooltip: ''' 25% increased damage - Reduces life regen by 10 and defense by 30% + Reduces life regen by 5 HP/s and defense by 30% [c/B00BA5:'This is the most potent booze I have, be careful with it.'] ''' } @@ -220,7 +220,7 @@ EvergreenGin: { Tooltip: ''' Multiplies all sickness and water-related debuff damage by 1.25x - Reduces life regen by 1 + Reduces life regen by 0.5 HP/s [c/B00BA5:'It tastes like a Christmas tree, if you can imagine that.'] ''' } @@ -240,7 +240,7 @@ Fireball: { Tooltip: ''' Multiplies all fire-based debuff damage by 1.25x - Reduces life regen by 1 + Reduces life regen by 0.5 HP/s [c/B00BA5:'A great-tasting cinnamon whiskey.'] ''' } @@ -259,7 +259,7 @@ Margarita: { Tooltip: ''' Halves the duration of most harmful debuffs - Reduces defense by 6% and life regen by 1 + Reduces defense by 6% and life regen by 0.5 HP/s 3 minute duration [c/B00BA5:'One of the best drinks ever created, enjoy it while it lasts.'] ''' @@ -270,7 +270,7 @@ Moonshine: { Tooltip: ''' Increases defense by 10 and damage reduction by 3% - Reduces life regen by 1 + Reduces life regen by 0.5 HP/s [c/B00BA5:'This stuff is pretty strong, but I'm sure you can handle it.'] ''' } @@ -280,7 +280,7 @@ MoscowMule: { Tooltip: ''' Increases damage by 9%, knockback by 50% and critical strike chance by 3% - Reduces life regen by 4 + Reduces life regen by 2 HP/s [c/B00BA5:'I once heard the copper mug can be toxic and I told 'em, 'listen dummy, I'm already poisoning myself!''] ''' } @@ -299,7 +299,7 @@ RedWine: { DisplayName: Red Wine Tooltip: ''' - Reduces life regen by 1 for 15 seconds + Reduces life regen by 0.5 HP/s for 15 seconds [c/B00BA5:'Too dry for my taste.'] ''' } @@ -308,7 +308,7 @@ Rum: { DisplayName: Rum Tooltip: ''' - Increases life regen by 2 and movement speed by 10% + Increases life regen by 1 HP/s and movement speed by 10% Reduces defense by 5% [c/B00BA5:'Sweet and potent, just how I like it.'] ''' @@ -319,7 +319,7 @@ Screwdriver: { Tooltip: ''' Multiplies piercing projectile damage by 1.05x - Reduces life regen by 1 + Reduces life regen by 0.5 HP/s [c/B00BA5:'Do you have a screw loose?'] ''' } @@ -330,7 +330,7 @@ StarBeamRye: { ''' Increases max mana by 50, magic damage by 8%, and reduces mana usage by 10% - Reduces defense by 6% and life regen by 2 + Reduces defense by 6% and life regen by 1 HP/s [c/B00BA5:'Made from some stuff I found near the Astral Meteor crash site. Don't worry, it's safe, trust me...'] ''' } @@ -340,7 +340,7 @@ Tequila: { Tooltip: ''' Increases knockback by 10%, crit chance by 4% and defense by 5 during daytime - Reduces life regen by 1 + Reduces life regen by 0.5 HP/s [c/B00BA5:'Great for mixing up daytime drinks.'] ''' } @@ -350,7 +350,7 @@ TequilaSunrise: { Tooltip: ''' Increases knockback by 20%, crit chance by 8% and defense by 10 during daytime - Reduces life regen by 2 + Reduces life regen by 1 HP/s [c/B00BA5:'The greatest daytime drink I've ever had.'] ''' } @@ -360,7 +360,7 @@ Vodka: { Tooltip: ''' Increases damage by 6% and critical strike chance by 2% - Reduces life regen by 1 and defense by 5% + Reduces life regen by 0.5 HP/s and defense by 5% [c/B00BA5:'The number one alcohol for creating great mixed drinks.'] ''' } @@ -380,7 +380,7 @@ WhiteWine: { Tooltip: ''' Increases magic damage by 8% - Reduces defense by 6% and life regen by 1 + Reduces defense by 6% and life regen by 0.5 HP/s [c/B00BA5:'I drank a full barrel of this stuff once in one night, I couldn't remember who I was the next day.'] ''' } \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson index 69377fae41..d672b623a1 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson @@ -843,7 +843,7 @@ OrichalcumSpikedGemstone: { PalladiumJavelin: { DisplayName: Palladium Javelin - Tooltip: Stealth strikes split into more javelins and boost life regeneration on hits + Tooltip: Stealth strikes split into more javelins and boost natural life regeneration on hits } Penumbra: { From 97cbab115e8993a5ebc8b068071aaa0bea4f1d4d Mon Sep 17 00:00:00 2001 From: Xyk Date: Thu, 31 Aug 2023 14:09:57 -0700 Subject: [PATCH 133/138] Tier shifted Fairy Boots and Rampart of Deities Fairy boots is Spectre Boots, Flower Boots, and 5 souls of light Rampart is Frozen Shield, Deific amulet, 5 auric bars and 5 ASE --- Items/Accessories/RampartofDeities.cs | 9 ++++----- Utilities/CalamityRecipes.cs | 1 + 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Items/Accessories/RampartofDeities.cs b/Items/Accessories/RampartofDeities.cs index c994cc1856..6ac921ae46 100644 --- a/Items/Accessories/RampartofDeities.cs +++ b/Items/Accessories/RampartofDeities.cs @@ -17,10 +17,10 @@ namespace CalamityMod.Items.Accessories { Item.width = 64; Item.height = 62; - Item.value = CalamityGlobalItem.Rarity14BuyPrice; + Item.value = CalamityGlobalItem.Rarity15BuyPrice; Item.defense = 18; Item.accessory = true; - Item.rare = ModContent.RarityType(); + Item.rare = ModContent.RarityType(); } public override void UpdateAccessory(Player player, bool hideVisual) @@ -57,9 +57,8 @@ namespace CalamityMod.Items.Accessories CreateRecipe(). AddIngredient(ItemID.FrozenShield). AddIngredient(). - AddIngredient(10). - AddIngredient(10). - AddIngredient(4). + AddIngredient(5). + AddIngredient(5). AddTile(). Register(); } diff --git a/Utilities/CalamityRecipes.cs b/Utilities/CalamityRecipes.cs index 75a77e5ee8..8590dabaed 100644 --- a/Utilities/CalamityRecipes.cs +++ b/Utilities/CalamityRecipes.cs @@ -827,6 +827,7 @@ namespace CalamityMod { Vanilla(ItemID.BundleofBalloons), AddIngredient(ModContent.ItemType(), 3) }, { r => r.HasResult(ItemID.HorseshoeBundle) && !r.HasIngredient(ItemID.BundleofBalloons), AddIngredient(ModContent.ItemType(), 3) }, { Vanilla(ItemID.NightsEdge), AddIngredient(ModContent.ItemType(), 5) }, + { Vanilla(ItemID.FairyBoots), AddIngredient(ItemID.SoulofLight, 5) }, { Vanilla(ItemID.SpiritFlame), AddGroup(AnyAdamantiteBar, 2) }, { Vanilla(ItemID.TerraBlade), AddIngredient(ModContent.ItemType(), 12) }, { Vanilla(ItemID.FireGauntlet), AddIngredient(ModContent.ItemType(), 5) }, From c79830b69b71e8d509fe0a886ce1ae185fea59c1 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Thu, 31 Aug 2023 18:58:50 -0600 Subject: [PATCH 134/138] Fixed Utensil Poker only firing forks and made the order of utensils static --- Items/Weapons/Rogue/UtensilPoker.cs | 15 ++++++++------- .../Mods.CalamityMod.Items.Weapons.Rogue.hjson | 2 +- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/Items/Weapons/Rogue/UtensilPoker.cs b/Items/Weapons/Rogue/UtensilPoker.cs index 1ace51a26d..ba75465275 100644 --- a/Items/Weapons/Rogue/UtensilPoker.cs +++ b/Items/Weapons/Rogue/UtensilPoker.cs @@ -5,6 +5,7 @@ using Microsoft.Xna.Framework; using Terraria; using Terraria.ID; using Terraria.ModLoader; +using CalamityMod.Particles; namespace CalamityMod.Items.Weapons.Rogue { @@ -45,23 +46,23 @@ namespace CalamityMod.Items.Weapons.Rogue } else { - int utensil = ModContent.ProjectileType(); + type = ModContent.ProjectileType(); double dmgMult = 1D; float kbMult = 1f; - switch (Main.rand.Next(3)) + switch (counter) { case 0: - utensil = ModContent.ProjectileType(); + type = ModContent.ProjectileType(); dmgMult = 1.1; kbMult = 2f; break; case 1: - utensil = ModContent.ProjectileType(); + type = ModContent.ProjectileType(); dmgMult = 1.2; kbMult = 1f; break; case 2: - utensil = ModContent.ProjectileType(); + type = ModContent.ProjectileType(); dmgMult = 1D; kbMult = 1f; break; @@ -70,7 +71,8 @@ namespace CalamityMod.Items.Weapons.Rogue } damage = (int)(damage * dmgMult); knockback = knockback * kbMult; - } + + } } public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) @@ -80,7 +82,6 @@ namespace CalamityMod.Items.Weapons.Rogue int idx = Projectile.NewProjectile(source, position, velocity, type, damage, knockback, player.whoAmI); if (idx.WithinBounds(Main.maxProjectiles)) Main.projectile[idx].Calamity().stealthStrike = mp.StealthStrikeAvailable(); - counter++; if (counter == 3) counter = 0; diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson index d672b623a1..b75593716d 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Rogue.hjson @@ -1337,7 +1337,7 @@ UtensilPoker: { DisplayName: Utensil Poker Tooltip: ''' - Fires random utensils in bursts of three + Fires utensils in bursts of three Stealth strikes replace any utensil with a powerful butcher knife 'Space chickens, that is all' ''' From 0d020c260a162ebd57c9de8d184869fe8aaaffd8 Mon Sep 17 00:00:00 2001 From: AquaSG Date: Thu, 31 Aug 2023 22:28:57 -0400 Subject: [PATCH 135/138] restoring turret tooltips that were missing for some reason --- .../Mods.CalamityMod.Items.Placeables.hjson | 56 ++++++++++++++----- ...ods.CalamityMod.Items.Weapons.Ranged.hjson | 2 +- 2 files changed, 43 insertions(+), 15 deletions(-) diff --git a/Localization/en-US/Mods.CalamityMod.Items.Placeables.hjson b/Localization/en-US/Mods.CalamityMod.Items.Placeables.hjson index d2815713ef..0f2df3541f 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Placeables.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Placeables.hjson @@ -3930,70 +3930,98 @@ HardenedEutrophicSand: { FireTurret: { DisplayName: Fire Turret - Tooltip: "" + Tooltip: + ''' + Roasts nearby enemies with a flamethrower at full blast + Cannot attack while a boss is alive + ''' } HostileFireTurret: { DisplayName: Hostile Fire Turret - Tooltip: "" + Tooltip: Roasts nearby players with a flamethrower at full blast } HostileIceTurret: { DisplayName: Hostile Ice Turret - Tooltip: "" + Tooltip: Lobs fragile ice mist bombs at nearby players } HostileLabTurret: { DisplayName: Hostile Lab Turret - Tooltip: "" + Tooltip: Shoots laser beams at nearby players } HostileLaserTurret: { DisplayName: Hostile Laser Turret - Tooltip: "" + Tooltip: Blasts nearby players with lightning-fast laser beams } HostileOnyxTurret: { DisplayName: Hostile Onyx Turret - Tooltip: "" + Tooltip: Shoots a shotgun spread of bullets at nearby players } HostilePlagueTurret: { DisplayName: Hostile Plague Turret - Tooltip: "" + Tooltip: Ejects homing plague missiles towards nearby players } HostileWaterTurret: { DisplayName: Hostile Water Turret - Tooltip: "" + Tooltip: Shoots high-speed water blasts at nearby players } IceTurret: { DisplayName: Ice Turret - Tooltip: "" + Tooltip: + ''' + Lobs fragile ice mist bombs at nearby enemies + Cannot attack while a boss is alive + ''' } LabTurret: { DisplayName: Lab Turret - Tooltip: "" + Tooltip: + ''' + Shoots laser beams at nearby enemies + Cannot attack while a boss is alive + ''' } LaserTurret: { DisplayName: Laser Turret - Tooltip: "" + Tooltip: + ''' + Blasts nearby enemies with lightning-fast laser beams + Cannot attack while a boss is alive + ''' } OnyxTurret: { DisplayName: Onyx Turret - Tooltip: "" + Tooltip: + ''' + Shoots a shotgun spread of bullets at nearby enemies + Cannot attack while a boss is alive + ''' } PlagueTurret: { DisplayName: Plague Turret - Tooltip: "" + Tooltip: + ''' + Ejects homing plague missiles towards nearby enemies + Cannot attack while a boss is alive + ''' } WaterTurret: { DisplayName: Water Turret - Tooltip: "" + Tooltip: + ''' + Shoots high-speed water blasts at nearby enemies + Cannot attack while a boss is alive + ''' } \ No newline at end of file diff --git a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson index 65e8c606eb..b40cc452aa 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Weapons.Ranged.hjson @@ -1285,4 +1285,4 @@ WulfrumBlunderbuss: { [c/83B87E:'The good thing about Wulfrum is that while it breaks fast, it can be reused even faster.] [c/83B87E:In fact, it is quite common for a robot to be turned into ammo right after it stops functioning.'] ''' -} +} \ No newline at end of file From 88d9f92d52cffb1d3fea0b404d6a61a9406d5d82 Mon Sep 17 00:00:00 2001 From: Done2222 Date: Fri, 1 Sep 2023 07:20:42 +0300 Subject: [PATCH 136/138] Purity and Rampart of Deities recipe fixes --- Items/Accessories/Purity.cs | 4 ++-- Items/Accessories/RampartofDeities.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Items/Accessories/Purity.cs b/Items/Accessories/Purity.cs index a0d2242d05..620e58a2c6 100644 --- a/Items/Accessories/Purity.cs +++ b/Items/Accessories/Purity.cs @@ -45,8 +45,8 @@ namespace CalamityMod.Items.Accessories CreateRecipe(). AddIngredient(). AddIngredient(). - AddIngredient(4). - AddIngredient(5). + AddIngredient(5). + AddIngredient(4). AddTile(ModContent.TileType()). Register(); } diff --git a/Items/Accessories/RampartofDeities.cs b/Items/Accessories/RampartofDeities.cs index 6ac921ae46..b3dfb4b051 100644 --- a/Items/Accessories/RampartofDeities.cs +++ b/Items/Accessories/RampartofDeities.cs @@ -58,7 +58,7 @@ namespace CalamityMod.Items.Accessories AddIngredient(ItemID.FrozenShield). AddIngredient(). AddIngredient(5). - AddIngredient(5). + AddIngredient(4). AddTile(). Register(); } From 5cfc71cddf9ecc79f8c17ea99b9e0394ef9e7bf4 Mon Sep 17 00:00:00 2001 From: Storm2103 Date: Thu, 31 Aug 2023 22:57:31 -0600 Subject: [PATCH 137/138] Failsave for Utensil Poker's count reset --- Items/Weapons/Rogue/UtensilPoker.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Items/Weapons/Rogue/UtensilPoker.cs b/Items/Weapons/Rogue/UtensilPoker.cs index ba75465275..dba6b5b87e 100644 --- a/Items/Weapons/Rogue/UtensilPoker.cs +++ b/Items/Weapons/Rogue/UtensilPoker.cs @@ -83,7 +83,7 @@ namespace CalamityMod.Items.Weapons.Rogue if (idx.WithinBounds(Main.maxProjectiles)) Main.projectile[idx].Calamity().stealthStrike = mp.StealthStrikeAvailable(); counter++; - if (counter == 3) + if (counter >= 3) counter = 0; return false; } From fcdc93c9f49e6513d6ae9d6b381ce04de493036a Mon Sep 17 00:00:00 2001 From: Mishiro Usui Date: Fri, 1 Sep 2023 13:25:28 +0100 Subject: [PATCH 138/138] Fixed shield sounds playing when they shouldn't --- CalPlayer/CalamityPlayerMiscEffects.cs | 3 +-- Cooldowns/CooldownHandler.cs | 5 +++++ Cooldowns/LunicCorpsShieldCooldowns.cs | 1 + Cooldowns/SpongeCooldowns.cs | 1 + Cooldowns/WulfrumRoverDriveCooldowns.cs | 3 ++- 5 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CalPlayer/CalamityPlayerMiscEffects.cs b/CalPlayer/CalamityPlayerMiscEffects.cs index 9c195f13ba..b297593fea 100644 --- a/CalPlayer/CalamityPlayerMiscEffects.cs +++ b/CalPlayer/CalamityPlayerMiscEffects.cs @@ -1152,7 +1152,7 @@ namespace CalamityMod.CalPlayer if (instance.timeLeft < 0) { handler.OnCompleted(); - if (handler.EndSound != null) + if (handler.EndSound != null && handler.ShouldPlayEndSound) SoundEngine.PlaySound(handler.EndSound.GetValueOrDefault()); expiredCooldowns.Add(id); } @@ -3612,7 +3612,6 @@ namespace CalamityMod.CalPlayer { CooldownInstance durabilityCooldown = Player.AddCooldown(WulfrumRoverDriveDurability.ID, RoverDrive.ShieldDurabilityMax); durabilityCooldown.timeLeft = RoverDriveShieldDurability; - SoundEngine.PlaySound(RoverDrive.ActivationSound, Player.Center); } // Add light if this shield is currently active diff --git a/Cooldowns/CooldownHandler.cs b/Cooldowns/CooldownHandler.cs index 4fe1a63e97..f9d83b7837 100644 --- a/Cooldowns/CooldownHandler.cs +++ b/Cooldowns/CooldownHandler.cs @@ -49,6 +49,11 @@ namespace CalamityMod.Cooldowns /// When the cooldown instance ends, this sound is played. Leave at null for no sound. /// public virtual SoundStyle? EndSound => null; + + /// + /// Set this to true to have the cooldown instance end sound play upon expiration. Defaults to true + /// + public virtual bool ShouldPlayEndSound => true; #endregion #region Display & Rendering diff --git a/Cooldowns/LunicCorpsShieldCooldowns.cs b/Cooldowns/LunicCorpsShieldCooldowns.cs index 8834314338..dbee30e4a1 100644 --- a/Cooldowns/LunicCorpsShieldCooldowns.cs +++ b/Cooldowns/LunicCorpsShieldCooldowns.cs @@ -90,6 +90,7 @@ namespace CalamityMod.Cooldowns public override Color CooldownStartColor => Color.Lerp(ringColorLerpStart, ringColorLerpEnd, instance.Completion); public override Color CooldownEndColor => Color.Lerp(ringColorLerpStart, ringColorLerpEnd, instance.Completion); public override SoundStyle? EndSound => LunicCorpsHelmet.ActivationSound; + public override bool ShouldPlayEndSound => instance.player.Calamity().lunicCorpsSet; public override void Tick() => instance.player.Calamity().playedLunicCorpsShieldSound = false; // When the recharge period completes, grant 1 point of shielding immediately so the rest my refill normally. diff --git a/Cooldowns/SpongeCooldowns.cs b/Cooldowns/SpongeCooldowns.cs index 6484749021..b9429b1bac 100644 --- a/Cooldowns/SpongeCooldowns.cs +++ b/Cooldowns/SpongeCooldowns.cs @@ -90,6 +90,7 @@ namespace CalamityMod.Cooldowns public override Color CooldownStartColor => Color.Lerp(ringColorLerpStart, ringColorLerpEnd, instance.Completion); public override Color CooldownEndColor => Color.Lerp(ringColorLerpStart, ringColorLerpEnd, instance.Completion); public override SoundStyle? EndSound => TheSponge.ActivationSound; + public override bool ShouldPlayEndSound => instance.player.Calamity().sponge; public override void Tick() => instance.player.Calamity().playedSpongeShieldSound = false; // When the recharge period completes, grant 1 point of shielding immediately so the rest my refill normally. diff --git a/Cooldowns/WulfrumRoverDriveCooldowns.cs b/Cooldowns/WulfrumRoverDriveCooldowns.cs index 894e7dd7f9..e4c6485992 100644 --- a/Cooldowns/WulfrumRoverDriveCooldowns.cs +++ b/Cooldowns/WulfrumRoverDriveCooldowns.cs @@ -98,6 +98,7 @@ namespace CalamityMod.Cooldowns if (modPlayer.roverDrive) modPlayer.RoverDriveShieldDurability = RoverDrive.ShieldDurabilityMax; } - public override SoundStyle? EndSound => null; + public override SoundStyle? EndSound => RoverDrive.ActivationSound; + public override bool ShouldPlayEndSound => instance.player.Calamity().roverDrive; } }