Small rework to Corrosive Spine + Whiskey fix

This commit is contained in:
mochi-angel committed 2024-12-14 18:52:01 -08:00
1 parent abc798caa9
commit 1bfe189dc8
7 files changed
+38 -65

No files matched your search

+13
View File
@@ -1546,6 +1546,19 @@ namespace CalamityMod.CalPlayer
dust2.color = Main.rand.NextBool() ? Color.Coral : Color.DarkTurquoise;
}
}
if (corrosiveSpine)
{
int cloudCount = 3;
for (int i = 0; i < cloudCount; i++)
{
float speed = 2f;
int damage = 40;
int cloud = Projectile.NewProjectile(Player.GetSource_FromThis(), Player.Center, Vector2.One.RotatedByRandom(MathHelper.TwoPi) * speed, ModContent.ProjectileType<ScourgeVenomCloud>(), damage, 0f, Player.whoAmI);
if (cloud.WithinBounds(Main.maxProjectiles))
Main.projectile[cloud].DamageType = DamageClass.Generic;
}
}
}
#endregion
+3 -1
View File
@@ -99,7 +99,7 @@ namespace CalamityMod.CalPlayer
ApplyDoTDebuff(wDeath, 0);
ApplyDoTDebuff(irradiated, 4, purity);
int sulphurDoT = 6 - (sulphurSet ? 2 : 0) - (sulphurskin ? 2 : 0);
int sulphurDoT = 6 - (sulphurSet ? 2 : 0) - (sulphurskin ? 2 : 0) - (corrosiveSpine ? 2 : 0);
ApplyDoTDebuff(sulphurPoison, sulphurDoT, purity);
ApplyDoTDebuff(rTide, 6, purity);
ApplyDoTDebuff(weakBrimstoneFlames, 7);
@@ -167,6 +167,8 @@ namespace CalamityMod.CalPlayer
increment *= 0.5f;
if (sulphurSet && !ASPoisoning)
increment *= 0.5f;
if (corrosiveSpine && !ASPoisoning)
increment *= 0.5f;
if (ZoneAbyssLayer1 && !ASPoisoning)
increment *= 0.33f;
+6 -37
View File
@@ -83,6 +83,7 @@ namespace CalamityMod.CalPlayer
target.Calamity().IncreasedSicknessEffects_ToxicHeart = toxicHeart;
target.Calamity().IncreasedSicknessAndWaterEffects_EvergreenGin = evergreenGin;
target.Calamity().IncreasedSicknessAndWaterEffects_CorrosiveSpine = corrosiveSpine;
switch (item.type)
{
@@ -198,6 +199,7 @@ namespace CalamityMod.CalPlayer
cgn.IncreasedSicknessEffects_ToxicHeart = toxicHeart;
cgn.IncreasedSicknessAndWaterEffects_EvergreenGin = evergreenGin;
cgn.IncreasedSicknessAndWaterEffects_CorrosiveSpine = corrosiveSpine;
switch (proj.type)
{
@@ -1031,39 +1033,6 @@ namespace CalamityMod.CalPlayer
titanCooldown = 15;
}
if (corrosiveSpine && modProj.stealthStrikeHitCount < 3 && (Player.ownedProjectileCounts[ProjectileType<Corrocloud1>()] + Player.ownedProjectileCounts[ProjectileType<Corrocloud2>()] + Player.ownedProjectileCounts[ProjectileType<Corrocloud3>()]) < 3)
{
for (int i = 0; i < 3; i++)
{
if (Main.rand.NextBool())
{
int type = -1;
switch (Main.rand.Next(15))
{
case 0:
type = ProjectileType<Corrocloud1>();
break;
case 1:
type = ProjectileType<Corrocloud2>();
break;
case 2:
type = ProjectileType<Corrocloud3>();
break;
}
if (type != -1)
{
int damage = (int)Player.GetTotalDamage<RogueDamageClass>().ApplyTo(22);
float speed = Main.rand.NextFloat(5f, 11f);
int cloud = Projectile.NewProjectile(spawnSource, position, Vector2.One.RotatedByRandom(MathHelper.TwoPi) * speed, type, damage, proj.knockBack, Player.whoAmI);
if (cloud.WithinBounds(Main.maxProjectiles))
Main.projectile[cloud].DamageType = DamageClass.Generic;
}
}
}
}
if (raiderTalisman && modProj.stealthStrike)
{
raiderCritLifespan = CalamityUtils.SecondsToFrames(RaidersTalisman.RaiderCooldown);
@@ -1164,10 +1133,6 @@ namespace CalamityMod.CalPlayer
{
target.AddBuff(BuffType<AstralInfectionDebuff>(), 120);
}
if (corrosiveSpine)
{
target.AddBuff(BuffID.Poisoned, 240);
}
}
if (summon)
{
@@ -1222,6 +1187,10 @@ namespace CalamityMod.CalPlayer
{
CalamityUtils.Inflict246DebuffsNPC(target, BuffType<CrushDepth>());
}
if (corrosiveSpine)
{
target.AddBuff(BuffType<Irradiated>(), 120);
}
if (alchFlask)
{
CalamityUtils.Inflict246DebuffsNPC(target, BuffType<Plague>());
+4 -23
View File
@@ -1,4 +1,5 @@
using CalamityMod.Projectiles.Rogue;
using CalamityMod.CalPlayer;
using CalamityMod.Projectiles.Rogue;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ID;
@@ -21,29 +22,9 @@ namespace CalamityMod.Items.Accessories
public override void UpdateAccessory(Player player, bool hideVisual)
{
CalamityPlayer modPlayer = player.Calamity();
modPlayer.corrosiveSpine = true;
player.moveSpeed += 0.05f;
player.Calamity().corrosiveSpine = true;
if (player.immune)
{
if (Main.rand.NextBool(15))
{
var source = player.GetSource_Accessory(Item);
int cloudCount = Main.rand.Next(2, 5);
for (int i = 0; i < cloudCount; i++)
{
int type = Utils.SelectRandom(Main.rand, new int[]
{
ModContent.ProjectileType<Corrocloud1>(),
ModContent.ProjectileType<Corrocloud2>(),
ModContent.ProjectileType<Corrocloud3>()
});
float speed = Main.rand.NextFloat(3f, 11f);
int damage = (int)player.GetTotalDamage<RogueDamageClass>().ApplyTo(80);
Projectile.NewProjectile(source, player.Center, Vector2.One.RotatedByRandom(MathHelper.TwoPi) * speed,
type, damage, 0f, player.whoAmI);
}
}
}
}
}
}
+1 -1
View File
@@ -14,7 +14,7 @@ namespace CalamityMod.Items.Potions.Alcohol
public static float DamageBoost = 0.04f;
public static float KnockbackBoost = 0.2f;
public static int CritBoost = 2;
public static float DefenseLossPercent = 5;
public static float DefenseLossPercent = 0.05f;
public override LocalizedText Tooltip => base.Tooltip.WithFormatArgs(DamageBoost.ToPercent(), KnockbackBoost.ToPercent(), CritBoost, DefenseLossPercent.ToPercent());
public override void SetStaticDefaults()
@@ -441,8 +441,9 @@ CorrosiveSpine: {
Tooltip:
'''
5% increased movement speed
All rogue weapons inflict poison and spawn poisoned clouds on enemy hits
You release a ton of clouds everywhere on hit
Multiplies all sickness and water-related debuff damage by 1.25x
All attacks irradiate enemies and reduces the severity of the sulphuric waters
You burst into radioactive clouds when struck
'''
}
+8 -1
View File
@@ -150,8 +150,9 @@ namespace CalamityMod.NPCs
// Toxic Heart effect
public bool IncreasedSicknessEffects_ToxicHeart = false;
// Evergreen Gin effect
// Sickness and Water debuff effects
public bool IncreasedSicknessAndWaterEffects_EvergreenGin = false;
public bool IncreasedSicknessAndWaterEffects_CorrosiveSpine = false;
/// <summary> Constant representing the grace period, in frames, in which a boss can remain outside of its native biome before enraging. </summary>
public const int biomeEnrageTimerMax = 300;
@@ -490,6 +491,7 @@ namespace CalamityMod.NPCs
myClone.IncreasedHeatEffects_FireBoots = IncreasedHeatEffects_FireBoots;
myClone.IncreasedHeatEffects_FlameWings = IncreasedHeatEffects_FlameWings;
myClone.IncreasedSicknessEffects_ToxicHeart = IncreasedSicknessEffects_ToxicHeart;
myClone.IncreasedSicknessAndWaterEffects_CorrosiveSpine = IncreasedSicknessAndWaterEffects_CorrosiveSpine;
myClone.IncreasedSicknessAndWaterEffects_EvergreenGin = IncreasedSicknessAndWaterEffects_EvergreenGin;
myClone.velocityPriorToPhaseSwap = velocityPriorToPhaseSwap;
@@ -911,6 +913,11 @@ namespace CalamityMod.NPCs
if (IncreasedSicknessEffects_ToxicHeart)
sicknessDamageMult += 0.5;
if (IncreasedSicknessAndWaterEffects_CorrosiveSpine)
{
sicknessDamageMult += 0.25;
waterDamageMult += 0.25;
}
if (IncreasedSicknessAndWaterEffects_EvergreenGin)
{
sicknessDamageMult += EvergreenGin.SicknessWaterDebuffBoost;