Mining speed fixes

- Fixed Chisel/HoC mining speed nerf applying post-cap
- Fixed Ocean Crest mining speed applying post-cap
- Updated Mining Potion + HoC tooltips
This commit is contained in:
Altixal committed 2024-06-06 18:35:18 +07:00
1 parent 1217829a54
commit cd15fb992c
3 files changed
+35 -29

No files matched your search

+27
View File
@@ -3698,6 +3698,33 @@ namespace CalamityMod.CalPlayer
#region PostUpdateEquips
public override void PostUpdateEquips()
{
// PostUpdateMiscEffects runs after the cap has been applied. Do NOT put mining speed stuff there.
// Ancient Chisel nerf (also affects Hand of Creation)
if (Player.chiselSpeed)
Player.pickSpeed += 0.1f;
if (oceanCrest)
{
bool surface = Player.Center.Y < Main.worldSurface * 16.0;
bool GetEffects = ((Main.raining && surface) || Player.dripping || (Player.wet && !Player.lavaWet && !Player.honeyWet));
if (GetEffects)
{
if (oceanCrestTimer < 300)
oceanCrestTimer += 5;
if (Player.StandingStill(0.1f) && !ZoneAbyss && Player.breath < 201 && Player.miscCounter % 2 == 0)
Player.breath += 1;
}
else
if (oceanCrestTimer > 0)
oceanCrestTimer--;
if (oceanCrestTimer > 0 || GetEffects)
Player.pickSpeed -= 0.15f; // 15% mining speed
Vector3 Light = new Vector3(0.090f, 0.180f, 0.200f);
Lighting.AddLight(Player.Center, Light * (0.55f + (oceanCrestTimer * 0.0035f)));
}
// True melee damage from various vanilla equipment placed here.
// Titan Glove and ALL upgrades.
-27
View File
@@ -342,28 +342,6 @@ namespace CalamityMod.CalPlayer
else
HasReducedDashFirstFrame = false;
}
if (oceanCrest)
{
bool surface = Player.Center.Y < Main.worldSurface * 16.0;
bool GetEffects = ((Main.raining && surface) || Player.dripping || (Player.wet && !Player.lavaWet && !Player.honeyWet));
if (GetEffects)
{
if (oceanCrestTimer < 300)
oceanCrestTimer += 5;
if (Player.StandingStill(0.1f) && !ZoneAbyss && Player.breath < 201 && Player.miscCounter % 2 == 0)
Player.breath += 1;
}
else
if (oceanCrestTimer > 0)
oceanCrestTimer--;
if (oceanCrestTimer > 0 || GetEffects)
Player.pickSpeed -= 0.15f; // 15% mining speed
Vector3 Light = new Vector3(0.090f, 0.180f, 0.200f);
Lighting.AddLight(Player.Center, Light * (0.55f + (oceanCrestTimer * 0.0035f)));
}
}
#endregion
@@ -2722,11 +2700,6 @@ namespace CalamityMod.CalPlayer
}
}
// Ancient Chisel nerf
if (Player.chiselSpeed)
Player.pickSpeed += 0.1f;
if (eGauntlet)
{
Player.GetDamage<MeleeDamageClass>() += 0.15f;
+8 -2
View File
@@ -716,9 +716,15 @@ namespace CalamityMod.Items
// Rebalances to vanilla item stats
#region Vanilla Item Rebalance Tooltips
// Ancient Chisel rebalance.
// Various mining speed nerfs
if (item.type == ItemID.MiningPotion)
EditTooltipByNum(0, (line) => line.Text.Replace("25", "15"));
if (item.type == ItemID.AncientChisel)
EditTooltipByNum(0, (line) => line.Text = "Increases mining speed by 15%");
EditTooltipByNum(0, (line) => line.Text.Replace("25", "15"));
if (item.type == ItemID.HandOfCreation)
EditTooltipByNum(0, (line) => line.Text.Replace("25", "15"));
// Frozen Turtle Shell rebalance.
if (item.type == ItemID.FrozenTurtleShell)