Merged LegRev and FTW into just Leg

also no more Yharon Dragonfolly summon
This commit is contained in:
GinYuH committed 2025-06-01 17:42:39 -07:00
1 parent d883e0dcaa
commit e2e1c7dbb8
135 files changed
+532 -535

No files matched your search

+1 -1
View File
@@ -3094,7 +3094,7 @@ namespace CalamityMod.CalPlayer
abyssDeath = false;
// Signus headcrab darkness
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
if (CalamityGlobalNPC.signus != -1)
{
+2 -2
View File
@@ -36,7 +36,7 @@ namespace CalamityMod.NPCs.AquaticScourge
NPC.knockBackResist = 0f;
NPC.alpha = 255;
NPC.LifeMaxNERB(80000, 96000, 1000000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 2;
NPC.behindTiles = true;
NPC.noGravity = true;
@@ -56,7 +56,7 @@ namespace CalamityMod.NPCs.AquaticScourge
else if (Main.expertMode)
NPC.scale *= 1.1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.25f;
NPC.Calamity().VulnerableToHeat = false;
+2 -2
View File
@@ -35,7 +35,7 @@ namespace CalamityMod.NPCs.AquaticScourge
NPC.knockBackResist = 0f;
NPC.alpha = 255;
NPC.LifeMaxNERB(80000, 96000, 1000000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 2;
NPC.behindTiles = true;
NPC.noGravity = true;
@@ -55,7 +55,7 @@ namespace CalamityMod.NPCs.AquaticScourge
else if (Main.expertMode)
NPC.scale *= 1.1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.25f;
NPC.Calamity().VulnerableToHeat = false;
+3 -3
View File
@@ -63,7 +63,7 @@ namespace CalamityMod.NPCs.AquaticScourge
NPC.aiStyle = -1;
AIType = -1;
NPC.LifeMaxNERB(80000, 96000, 1000000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 2;
NPC.knockBackResist = 0f;
NPC.value = Item.buyPrice(0, 16, 0, 0);
@@ -84,7 +84,7 @@ namespace CalamityMod.NPCs.AquaticScourge
else if (Main.expertMode)
NPC.scale *= 1.1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.25f;
NPC.Calamity().VulnerableToHeat = false;
@@ -205,7 +205,7 @@ namespace CalamityMod.NPCs.AquaticScourge
if (spawnInfo.Player.Calamity().ZoneSulphur && spawnInfo.Water)
{
if (!NPC.AnyNPCs(ModContent.NPCType<AquaticScourgeHead>()))
return (Main.getGoodWorld ? 0.05f : 0.01f);
return (CalamityWorld.LegendaryMode ? 0.05f : 0.01f);
}
return 0f;
+2 -2
View File
@@ -35,7 +35,7 @@ namespace CalamityMod.NPCs.AquaticScourge
NPC.knockBackResist = 0f;
NPC.alpha = 255;
NPC.LifeMaxNERB(80000, 96000, 1000000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 2;
NPC.behindTiles = true;
NPC.noGravity = true;
@@ -55,7 +55,7 @@ namespace CalamityMod.NPCs.AquaticScourge
else if (Main.expertMode)
NPC.scale *= 1.1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.25f;
NPC.Calamity().VulnerableToHeat = false;
+1 -1
View File
@@ -109,7 +109,7 @@ namespace CalamityMod.NPCs.AstrumAureus
NPC.Calamity().VulnerableToSickness = false;
SpawnModBiomes = new int[1] { ModContent.GetInstance<BiomeManagers.AstralInfectionBiome>().Type };
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.8f;
if (Main.zenithWorld)
NPC.scale *= 1.5f;
+2 -2
View File
@@ -308,11 +308,11 @@ namespace CalamityMod.NPCs.AstrumAureus
{
if (Main.netMode != NetmodeID.MultiplayerClient)
{
int totalProjectiles = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 36 : (3 + (int)((NPC.scale - 1f) * 3));
int totalProjectiles = CalamityWorld.LegendaryMode ? 36 : (3 + (int)((NPC.scale - 1f) * 3));
double radians = MathHelper.TwoPi / totalProjectiles;
int type = ModContent.ProjectileType<AstralLaser>();
int damage2 = NPC.GetProjectileDamage(type);
float velocity = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 10f : 6f;
float velocity = CalamityWorld.LegendaryMode ? 10f : 6f;
double angleA = radians * 0.5;
double angleB = MathHelper.ToRadians(90f) - angleA;
float velocityX = (float)(velocity * Math.Sin(angleA) / Math.Sin(angleB));
+1 -1
View File
@@ -130,7 +130,7 @@ namespace CalamityMod.NPCs.AstrumDeus
// Need segment amount to get a smooth transition down the worm based on length
int segmentAmt = Main.zenithWorld ? (CalamityWorld.death ? 8 : CalamityWorld.revenge ? 7 : Main.expertMode ? 6 : 5) : (CalamityWorld.death ? 40 : CalamityWorld.revenge ? 35 : Main.expertMode ? 30 : 25);
float cyanThreshold = Main.getGoodWorld ? 300f : 600f;
float cyanThreshold = CalamityWorld.LegendaryMode ? 300f : 600f;
float transitionStart = MathHelper.Lerp(cyanThreshold * 0.75f, cyanThreshold * 0.95f, 1f - (NPC.ai[3] / (float)segmentAmt));
float transitionEnd = MathHelper.Lerp(cyanThreshold * 0.8f, cyanThreshold, 1f - (NPC.ai[3] / (float)segmentAmt));
bool drawCyan = NPC.Calamity().newAI[3] >= transitionEnd && NPC.Calamity().newAI[3] <= cyanThreshold + transitionEnd;
+1 -1
View File
@@ -172,7 +172,7 @@ namespace CalamityMod.NPCs.AstrumDeus
bool deathModeEnragePhase = NPC.Calamity().newAI[0] == 3f;
bool doubleWormPhase = NPC.Calamity().newAI[0] != 0f && !deathModeEnragePhase;
float cyanThreshold = Main.getGoodWorld ? 300f : 600f;
float cyanThreshold = CalamityWorld.LegendaryMode ? 300f : 600f;
// Head is always the last segment to visually transition
float transitionStart = cyanThreshold * 0.95f;
bool drawCyan = NPC.Calamity().newAI[3] >= cyanThreshold;
+1 -1
View File
@@ -111,7 +111,7 @@ namespace CalamityMod.NPCs.AstrumDeus
bool deathModeEnragePhase = Main.npc[(int)NPC.ai[2]].Calamity().newAI[0] == 3f;
bool doubleWormPhase = NPC.Calamity().newAI[0] != 0f && !deathModeEnragePhase;
float cyanThreshold = Main.getGoodWorld ? 300f : 600f;
float cyanThreshold = CalamityWorld.LegendaryMode ? 300f : 600f;
// Tail is always the first segment to visually transition
float transitionStart = cyanThreshold * 0.75f;
float transitionEnd = cyanThreshold * 0.8f;
@@ -46,7 +46,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
// Adjust hostility and stats
bool nonHostile = calamityGlobalNPC.newAI[0] == 0f;
if (npc.justHit || npc.life <= npc.lifeMax * 0.999 || bossRush || Main.getGoodWorld)
if (npc.justHit || npc.life <= npc.lifeMax * 0.999 || bossRush || CalamityWorld.LegendaryMode)
{
if (nonHostile)
{
@@ -399,7 +399,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
}
Vector2 scourgePosition = npc.Center;
Vector2 predictionVector = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? Main.player[npc.target].velocity * 20f : Vector2.Zero;
Vector2 predictionVector = CalamityWorld.LegendaryMode ? Main.player[npc.target].velocity * 20f : Vector2.Zero;
float scourgeTargetX = player.Center.X + predictionVector.X;
float scourgeTargetY = player.Center.Y + predictionVector.Y;
@@ -432,7 +432,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
scourgeAcceleration *= accelerationMultiplier;
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
scourgeMaxSpeed *= 1.15f;
scourgeAcceleration *= 1.15f;
@@ -90,7 +90,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (expertMode)
astralFlameBarrageTimerIncrement += death ? (float)Math.Round(3f * (1f - lifeRatio)) : (float)Math.Round(2f * (1f - lifeRatio));
float walkingVelocity = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 6f : 5f;
float walkingVelocity = CalamityWorld.LegendaryMode ? 6f : 5f;
walkingVelocity += 3f * enrageScale;
if (phase5)
walkingVelocity += 2f;
@@ -98,7 +98,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
walkingVelocity += 1.5f * (1f - lifeRatio);
if (revenge)
walkingVelocity += Math.Abs(npc.Center.X - player.Center.X) * 0.0025f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
walkingVelocity *= 1.15f;
float walkingProjectileVelocity = walkingVelocity * 0.8f;
@@ -531,11 +531,11 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
calamityGlobalNPC.newAI[1] = speedMultLimit;
}
float velocity = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 27f : 20f;
float velocity = CalamityWorld.LegendaryMode ? 27f : 20f;
velocity += 6f * enrageScale;
if (expertMode)
velocity += death ? 6f * (1f - lifeRatio) : 4f * (1f - lifeRatio);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
velocity *= 1.15f;
npc.velocity = (new Vector2(player.Center.X, player.Center.Y - 500f) - npc.Center).SafeNormalize(Vector2.Zero) * velocity;
@@ -661,7 +661,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (Main.netMode != NetmodeID.MultiplayerClient)
{
float laserVelocity = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 7f : death ? 6f : 5f;
float laserVelocity = CalamityWorld.LegendaryMode ? 7f : death ? 6f : 5f;
int maxProjectiles = !phase3 ? (bossRush ? 13 : death ? 11 : 9) : (bossRush ? 17 : death ? 15 : 13);
int spread = !phase3 ? (bossRush ? 20 : death ? 18 : 16) : (bossRush ? 24 : death ? 22 : 20);
@@ -714,7 +714,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
fallSpeed += 0.36f * enrageScale;
if (expertMode)
fallSpeed += death ? 0.36f * (1f - lifeRatio) : 0.24f * (1f - lifeRatio);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
fallSpeed += 0.5f;
if (calamityGlobalNPC.newAI[1] > 0f)
@@ -741,7 +741,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
velocityXCap += 3.6f * enrageScale;
if (expertMode)
velocityXCap += death ? 3.6f * (1f - lifeRatio) : 2.4f * (1f - lifeRatio);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
velocityXCap += 5f;
if (calamityGlobalNPC.newAI[0] > 0f)
@@ -954,7 +954,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (calamityGlobalNPC.newAI[1] > 0f && !reduceFallSpeed)
maxFallSpeed *= calamityGlobalNPC.newAI[1] + 1f;
if (Main.getGoodWorld && !reduceFallSpeed)
if (CalamityWorld.LegendaryMode && !reduceFallSpeed)
{
gravity *= 1.15f;
maxFallSpeed *= 1.15f;
@@ -97,7 +97,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
calamityGlobalNPC.CurrentlyIncreasingDefenseOrDR = calamityGlobalNPC.newAI[1] < resistanceTime;
// Flight timer
float aiSwitchTimer = doubleWormPhase ? (Main.getGoodWorld ? 600f : 1200f) : (Main.getGoodWorld ? 900f : 1800f);
float aiSwitchTimer = doubleWormPhase ? (CalamityWorld.LegendaryMode ? 600f : 1200f) : (CalamityWorld.LegendaryMode ? 900f : 1800f);
calamityGlobalNPC.newAI[3] += 1f;
if (calamityGlobalNPC.newAI[3] >= aiSwitchTimer)
@@ -118,7 +118,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
// Become gradually more pissed as more worms are killed
int gfbMaxWormCount = 10;
int gfbWormCount = 0;
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
gfbWormCount = NPC.CountNPCS(ModContent.NPCType<AstrumDeusHead>());
if (gfbWormCount > gfbMaxWormCount)
gfbWormCount = gfbMaxWormCount;
@@ -230,7 +230,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
int startIndexHeadTwo = startIndexHeadOne + phase2Length + 1;
int headTwoID = NPC.NewNPC(npc.GetSource_FromAI(), (int)npc.Center.X, (int)npc.Center.Y, npc.type, startIndexHeadTwo);
Main.npc[headTwoID].Calamity().newAI[0] = 2f;
Main.npc[headTwoID].Calamity().newAI[3] = Main.getGoodWorld ? 300f : 600f;
Main.npc[headTwoID].Calamity().newAI[3] = CalamityWorld.LegendaryMode ? 300f : 600f;
Main.npc[headTwoID].velocity = Vector2.Normalize(player.Center - Main.npc[headTwoID].Center) * 16f;
Main.npc[headTwoID].timeLeft *= 20;
Main.npc[headTwoID].ForceNetUpdate();
@@ -524,7 +524,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
speed *= increaseSpeedMore ? 2f : increaseSpeed ? 1.5f : 1f;
turnSpeed *= increaseSpeedMore ? 2f : increaseSpeed ? 1.5f : 1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
speed *= 1.15f;
turnSpeed *= 1.15f;
@@ -366,7 +366,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
npc.chaseable = true;
npc.ai[3] += 1f;
npc.alpha = 0;
if (npc.ai[3] >= 2f || phase2 || Main.getGoodWorld)
if (npc.ai[3] >= 2f || phase2 || CalamityWorld.LegendaryMode)
{
npc.ai[0] = -1f;
npc.ai[1] = 0f;
@@ -419,7 +419,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
{
int proj = Projectile.NewProjectile(npc.GetSource_FromAI(), npc.Center + projectileVelocity.SafeNormalize(Vector2.UnitY) * 5f, projectileVelocity, type, damage, 0f, Main.myPlayer, player.position.X, player.position.Y);
Main.projectile[proj].timeLeft = 240;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
Main.projectile[proj].extraUpdates += 1;
}
@@ -440,7 +440,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
projectileVelocity = (player.Center - npc.Center).SafeNormalize(Vector2.UnitY) * velocity;
int numProj = death ? 8 : 4;
int spread = death ? 90 : 45;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
numProj *= 3;
spread *= 2;
@@ -454,7 +454,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
{
Vector2 perturbedSpeed = projectileVelocity.RotatedBy(MathHelper.Lerp(-rotation, rotation, i / (float)(numProj - 1)));
int proj2 = Projectile.NewProjectile(npc.GetSource_FromAI(), npc.Center + perturbedSpeed.SafeNormalize(Vector2.UnitY) * 5f, perturbedSpeed, type, damage, 0f, Main.myPlayer, 1f, 0f, projectileVelocityToPass);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
Main.projectile[proj2].extraUpdates += 1;
}
}
@@ -482,7 +482,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
npc.chaseable = false;
npc.localAI[0] += 1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.localAI[0] += 2f;
if (expertMode)
npc.localAI[0] += 1f - lifeRatio;
@@ -520,7 +520,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
int proj = Projectile.NewProjectile(npc.GetSource_FromAI(), npc.Center + offset, projectileVelocity, type, damage, 0f, Main.myPlayer, 1f, 0f);
Main.projectile[proj].timeLeft = 300;
Main.projectile[proj].tileCollide = false;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
Main.projectile[proj].extraUpdates += 1;
}
}
@@ -550,7 +550,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
{
Vector2 vector255 = spinningPoint.RotatedBy(radians2 * k);
int proj = Projectile.NewProjectile(npc.GetSource_FromAI(), npc.Center + vector255.SafeNormalize(Vector2.UnitY) * 5f, vector255, type, damage, 0f, Main.myPlayer, 1f, 0f, projectileVelocityToPass);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
Main.projectile[proj].extraUpdates += 1;
}
@@ -561,7 +561,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
{
Vector2 vector255 = spinningPoint.RotatedBy(radians2 * k);
int proj = Projectile.NewProjectile(npc.GetSource_FromAI(), npc.Center + vector255.SafeNormalize(Vector2.UnitY) * 5f, vector255 * 0.75f, type, damage, 0f, Main.myPlayer, 1f, 0f, projectileVelocityToPass);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
Main.projectile[proj].extraUpdates += 1;
}
}
@@ -653,7 +653,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
int damage = npc.GetProjectileDamage(type);
Projectile.NewProjectile(npc.GetSource_FromAI(), source, laserVelocity2, type, damage, 0f, Main.myPlayer, 0f, npc.whoAmI);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
Projectile.NewProjectile(npc.GetSource_FromAI(), source, -laserVelocity2, type, damage, 0f, Main.myPlayer, 0f, npc.whoAmI);
if (Main.zenithWorld)
@@ -694,7 +694,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (Main.netMode != NetmodeID.MultiplayerClient)
{
Projectile.NewProjectile(npc.GetSource_FromAI(), source, laserVelocity, ModContent.ProjectileType<BrimstoneTargetRay>(), 0, 0f, Main.myPlayer, 0f, npc.whoAmI);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
Projectile.NewProjectile(npc.GetSource_FromAI(), source, -laserVelocity, ModContent.ProjectileType<BrimstoneTargetRay>(), 0, 0f, Main.myPlayer, 0f, npc.whoAmI);
if (Main.zenithWorld)
@@ -716,7 +716,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (Main.netMode != NetmodeID.MultiplayerClient)
{
Projectile.NewProjectile(npc.GetSource_FromAI(), source.X, source.Y, npc.localAI[0], npc.localAI[1], ModContent.ProjectileType<BrimstoneTargetRay>(), 0, 0f, Main.myPlayer, 1f, npc.whoAmI);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
Projectile.NewProjectile(npc.GetSource_FromAI(), source.X, source.Y, -npc.localAI[0], -npc.localAI[1], ModContent.ProjectileType<BrimstoneTargetRay>(), 0, 0f, Main.myPlayer, 1f, npc.whoAmI);
if (Main.zenithWorld)
@@ -88,7 +88,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (npc.localAI[2] > 0f || bossRush)
enrageScale += 1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
enrageScale += 0.5f;
if (enrageScale > 3f)
@@ -252,7 +252,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
}
// Max spawn amount
int maxBirbs = (CalamityWorld.LegendaryMode && revenge) ? 12 : revenge ? 3 : 2;
int maxBirbs = CalamityWorld.LegendaryMode ? 12 : revenge ? 3 : 2;
// Variable for charging
float chargeDistance = 600f;
@@ -382,7 +382,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
bool spawnRight = player.velocity.X > 0f;
for (int i = 0; i < totalProjectiles; i++)
{
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
if (i >= (int)(totalProjectiles * 0.125) && i <= (int)(totalProjectiles * 0.375))
{
@@ -449,13 +449,13 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
{
int totalProjectiles = phase2 ? 40 : 48;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
totalProjectiles *= 2;
float radians = MathHelper.TwoPi / totalProjectiles;
int distance = phase2 ? 1200 : 1320;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
distance *= 2;
bool spawnRight = player.velocity.X > 0f;
@@ -564,7 +564,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
float velocity = 8f + (enrageScale - 1f) * 2f;
float follyQuickFlySpeed = velocity + npc.ai[2] + follyQuickFlyTargetDirection.Length() / 120f;
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
follyQuickFlySpeed *= 2f;
float follyQuickFlyVelMult = 20f;
@@ -573,7 +573,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
npc.velocity = (npc.velocity * (follyQuickFlyVelMult - 1f) + follyQuickFlyTargetDirection) / follyQuickFlyVelMult;
npc.ai[1] += 1f;
if (npc.ai[1] >= ((CalamityWorld.LegendaryMode && revenge) ? 90f : 180f))
if (npc.ai[1] >= ((CalamityWorld.LegendaryMode) ? 90f : 180f))
{
npc.TargetClosest();
npc.ai[0] = 0f;
@@ -771,7 +771,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (Main.netMode != NetmodeID.MultiplayerClient)
{
bool gfbSpawnFlag = CalamityWorld.LegendaryMode && revenge && (npc.ai[1] == 145f || npc.ai[1] == 150f || npc.ai[1] == 160f || npc.ai[1] == 165f);
bool gfbSpawnFlag = CalamityWorld.LegendaryMode && (npc.ai[1] == 145f || npc.ai[1] == 150f || npc.ai[1] == 160f || npc.ai[1] == 165f);
bool spawnFlag = NPC.CountNPCS(ModContent.NPCType<Bumblefuck2>()) < maxBirbs && (npc.ai[1] == 140f || (revenge && npc.ai[1] == 155f) || npc.ai[1] == 170f || gfbSpawnFlag);
if (spawnFlag)
{
@@ -933,7 +933,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
swarmerIdleTargetDist.Normalize();
swarmerIdleTargetDist *= swarmerIdleSpeed;
npc.velocity = (npc.velocity * 29f + swarmerIdleTargetDist) / 30f;
if (Main.getGoodWorld && !Main.zenithWorld)
if (CalamityWorld.LegendaryMode && !Main.zenithWorld)
npc.velocity *= 1.15f;
}
else if (npc.velocity.Length() > 2f)
@@ -981,7 +981,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
swarmerChargeTargetDist.Normalize();
swarmerChargeTargetDist *= swarmerChargeSpeed;
npc.velocity = (npc.velocity * (swarmerChargeVelMult - 1f) + swarmerChargeTargetDist) / swarmerChargeVelMult;
if (Main.getGoodWorld && !Main.zenithWorld)
if (CalamityWorld.LegendaryMode && !Main.zenithWorld)
npc.velocity *= 1.15f;
npc.ForceNetUpdate();
@@ -1009,7 +1009,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
swarmerDecelerateTargetDist.Normalize();
swarmerDecelerateTargetDist *= swarmerDecelerateSpeed;
npc.velocity = (npc.velocity * (swarmerDecelerateVelMult - 1f) + swarmerDecelerateTargetDist) / swarmerDecelerateVelMult;
if (Main.getGoodWorld && !Main.zenithWorld)
if (CalamityWorld.LegendaryMode && !Main.zenithWorld)
npc.velocity *= 1.15f;
if (npc.velocity.X < 0f)
@@ -1026,7 +1026,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
npc.damage = npc.defDamage;
npc.velocity = swarmerDecelerateTargetDist;
if (Main.getGoodWorld && !Main.zenithWorld)
if (CalamityWorld.LegendaryMode && !Main.zenithWorld)
npc.velocity *= 1.15f;
if (npc.velocity.X < 0f)
@@ -93,7 +93,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
SoundEngine.PlaySound(SoundID.Item109, npc.Center);
calamityGlobalNPC.newAI[2] = 2f;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
calamityGlobalNPC.newAI[3] = 0f;
SpawnDust();
@@ -117,7 +117,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
SoundEngine.PlaySound(SoundID.Item109, npc.Center);
calamityGlobalNPC.newAI[2] = 1f;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
calamityGlobalNPC.newAI[3] = 0f;
SpawnDust();
@@ -287,7 +287,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
baseVelocity += 1.5f * (1f - lifeRatio);
baseAcceleration += 0.03f * (1f - lifeRatio);
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
baseVelocity *= 1.15f;
baseAcceleration *= 1.15f;
@@ -355,7 +355,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (Main.zenithWorld)
type = ModContent.ProjectileType<SCalBrimstoneGigablast>();
float gigaBlastFrequency = (Main.getGoodWorld ? 120f : expertMode ? 180f : 240f) - enrageScale * 15f;
float gigaBlastFrequency = (CalamityWorld.LegendaryMode ? 120f : expertMode ? 180f : 240f) - enrageScale * 15f;
float projSpeed = bossRush ? 6.25f : 5f;
if (calamityGlobalNPC.newAI[3] <= 300f)
{
@@ -492,7 +492,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
return;
}
else if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
else if (CalamityWorld.LegendaryMode)
{
if (calamityGlobalNPC.newAI[3] < 900f)
calamityGlobalNPC.newAI[3] += 1f;
@@ -580,7 +580,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
projectileVelocity += 3f * enrageScale;
int type = ModContent.ProjectileType<BrimstoneHellfireball>();
int damage = npc.GetProjectileDamage(type);
bool shootPredictiveShot = CalamityWorld.LegendaryMode && CalamityWorld.revenge && Main.rand.NextBool();
bool shootPredictiveShot = CalamityWorld.LegendaryMode && Main.rand.NextBool();
Vector2 predictionVector = shootPredictiveShot ? player.velocity * 20f : Vector2.Zero;
Vector2 fireballVelocity = Vector2.Normalize(player.Center + predictionVector - npc.Center) * projectileVelocity;
Vector2 offset = Vector2.Normalize(fireballVelocity) * 40f;
@@ -862,7 +862,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
calCloneBroProjAttackMaxSpeed += 2f * enrageScale;
calCloneBroProjAttackAccel += 0.06f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
calCloneBroProjAttackMaxSpeed *= 1.15f;
calCloneBroProjAttackAccel *= 1.15f;
@@ -989,7 +989,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
calCloneBroChargeSpeed += 2f;
if (revenge)
calCloneBroChargeSpeed += 2f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
calCloneBroChargeSpeed *= 1.25f;
Vector2 calCloneBroChargeCenter = npc.Center;
@@ -1196,7 +1196,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
calCloneBroProjAttackMaxSpeed += 2f * enrageScale;
calCloneBroProjAttackAccel += 0.1f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
calCloneBroProjAttackMaxSpeed *= 1.15f;
calCloneBroProjAttackAccel *= 1.15f;
@@ -1320,7 +1320,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
calCloneBroChargeSpeed += 2f;
if (revenge)
calCloneBroChargeSpeed += 2f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
calCloneBroChargeSpeed *= 1.25f;
Vector2 calCloneBroChargeCenter = new Vector2(npc.position.X + npc.width * 0.5f, npc.position.Y + npc.height * 0.5f);
@@ -62,7 +62,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
if (phase4)
darkEnergyAmt += 1;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
darkEnergyAmt *= 2;
// Spawn a few Dark Energies as soon as the fight starts
@@ -121,7 +121,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
else if (npc.timeLeft < 1800)
npc.timeLeft = 1800;
float tileEnrageMult = (CalamityWorld.LegendaryMode && revenge) ? 1.5f : bossRush ? 1.375f : 1f;
float tileEnrageMult = (CalamityWorld.LegendaryMode) ? 1.5f : bossRush ? 1.375f : 1f;
npc.Calamity().CurrentlyEnraged = tileEnrageMult > 1f && !bossRush;
// Set AI variable to be used by Dark Energies
@@ -131,14 +131,14 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
float projectileFireRateMultiplier = MathHelper.Lerp(0.5f, 1.5f, 1f - ((tileEnrageMult - 1f) / 0.5f));
// Decides whether Ceaseless moves closer to its target or not
float distanceRequiredToMove = (Main.getGoodWorld || !anyDarkEnergies) ? 320f : bossRush ? 600f : death ? 520f : revenge ? 480f : expertMode ? 440f : 400f;
float distanceRequiredToMove = (CalamityWorld.LegendaryMode || !anyDarkEnergies) ? 320f : bossRush ? 600f : death ? 520f : revenge ? 480f : expertMode ? 440f : 400f;
bool move = Vector2.Distance(npc.Center, player.Center) > distanceRequiredToMove || !Collision.CanHit(npc.Center, 1, 1, player.Center, 1, 1);
// Succ attack
if (!anyDarkEnergies)
{
// This is here because it's used in multiple places
float suckDistance = (CalamityWorld.LegendaryMode && revenge) ? 2400f : bossRush ? 1920f : death ? 1600f : revenge ? 1440f : expertMode ? 1280f : 1040f;
float suckDistance = (CalamityWorld.LegendaryMode) ? 2400f : bossRush ? 1920f : death ? 1600f : revenge ? 1440f : expertMode ? 1280f : 1040f;
// Move closer to the target before trying to succ
if (movingDuringSuccPhase)
@@ -474,7 +474,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
acceleration *= 2f;
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.15f;
acceleration *= 1.15f;
@@ -484,8 +484,8 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
// Move between 8 different positions around the player, in order
float maxDistance = 320f;
Vector2 moveToOffset = succ ? Vector2.Zero : Main.getGoodWorld ? new Vector2(0f, -maxDistance) : Vector2.Zero;
if (!succ && Main.getGoodWorld)
Vector2 moveToOffset = succ ? Vector2.Zero : CalamityWorld.LegendaryMode ? new Vector2(0f, -maxDistance) : Vector2.Zero;
if (!succ && CalamityWorld.LegendaryMode)
{
// Move to a new location every few seconds
calamityGlobalNPC.newAI[2] += 1f;
@@ -537,7 +537,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
Vector2 distanceFromDestination = destination - npc.Center;
// Movement
if (npc.Distance(destination) > maxDistance || succ || !Main.getGoodWorld)
if (npc.Distance(destination) > maxDistance || succ || !CalamityWorld.LegendaryMode)
CalamityUtils.SmoothMovement(npc, 0f, distanceFromDestination, velocity, acceleration, true);
}
+14 -14
View File
@@ -50,7 +50,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
bool death = CalamityWorld.death || bossRush;
float exhaustionGateValue = 360f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
exhaustionGateValue *= 0.5f;
float numberOfAttacksBeforeExhaustion = 12f;
@@ -147,7 +147,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
}
// The dumbest thing to ever exist
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
chargeVelocity *= 1.25f;
if (exhausted)
@@ -305,7 +305,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
}
// The dumbest thing to ever exist
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
chargeTime *= 2;
// Set variables for spawn effects
@@ -609,7 +609,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
npc.damage = setDamage;
// The dumbest thing to ever exist
if (CalamityWorld.LegendaryMode && revenge && npc.ai[2] % 10f == 0f)
if (CalamityWorld.LegendaryMode && npc.ai[2] % 10f == 0f)
{
// Rotation and direction
int dir = Math.Sign(player.Center.X - npc.Center.X);
@@ -781,7 +781,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X + 900f), (int)(npc.Center.Y - calamityGlobalNPC.newAI[2]), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, npc.whoAmI, 0f, 255);
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X - 900f), (int)(npc.Center.Y - calamityGlobalNPC.newAI[2]), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, npc.whoAmI, 0f, 255);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X + 1800f), (int)(npc.Center.Y - calamityGlobalNPC.newAI[2]), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, npc.whoAmI, 0f, 255);
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X - 1800f), (int)(npc.Center.Y - calamityGlobalNPC.newAI[2]), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, npc.whoAmI, 0f, 255);
@@ -828,7 +828,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X + 50f + calamityGlobalNPC.newAI[2]), (int)(npc.Center.Y + 540f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, 1f, -sharkronVelocity, 255);
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X - 50f - calamityGlobalNPC.newAI[2]), (int)(npc.Center.Y + 540f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, -1f, -sharkronVelocity, 255);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X + 50f + calamityGlobalNPC.newAI[2] * 0.5f), (int)(npc.Center.Y + 270f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, 1f, -sharkronVelocity, 255);
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X - 50f - calamityGlobalNPC.newAI[2] * 0.5f), (int)(npc.Center.Y + 270f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, -1f, -sharkronVelocity, 255);
@@ -984,7 +984,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
npc.damage = setDamage;
// The dumbest thing to ever exist
if (CalamityWorld.LegendaryMode && revenge && npc.ai[2] % 8f == 0f)
if (CalamityWorld.LegendaryMode && npc.ai[2] % 8f == 0f)
{
// Rotation and direction
int dir = Math.Sign(player.Center.X - npc.Center.X);
@@ -1141,13 +1141,13 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
Vector2 phase2GoreDirection = npc.rotation.ToRotationVector2() * (Vector2.UnitX * npc.direction) * (npc.width + 20) / 2f + npc.Center;
int type = ModContent.ProjectileType<OldDukeGore>();
int damage = npc.GetProjectileDamage(type);
int totalGore = Main.getGoodWorld ? 40 : 20;
int totalGore = CalamityWorld.LegendaryMode ? 40 : 20;
for (int i = 0; i < totalGore; i++)
{
float velocityX = npc.direction * goreVelocityX * (Main.rand.NextFloat(0.2f, 0.8f) + 0.5f);
float velocityY = goreVelocityY * (Main.rand.NextFloat(0.2f, 0.8f) + 0.5f);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocityX *= Main.rand.NextFloat() + 0.5f;
velocityY *= Main.rand.NextFloat() + 0.5f;
@@ -1211,7 +1211,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X + 50f + calamityGlobalNPC.newAI[2]), (int)(npc.Center.Y - 540f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, 1f, sharkronVelocity, 255);
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X - 50f - calamityGlobalNPC.newAI[2]), (int)(npc.Center.Y - 540f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, -1f, sharkronVelocity, 255);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X + 50f + calamityGlobalNPC.newAI[2] * 0.5f), (int)(npc.Center.Y + 270f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, 1f, -sharkronVelocity, 255);
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X - 50f - calamityGlobalNPC.newAI[2] * 0.5f), (int)(npc.Center.Y + 270f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, -1f, -sharkronVelocity, 255);
@@ -1379,7 +1379,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
npc.damage = setDamage;
// The dumbest thing to ever exist
if (CalamityWorld.LegendaryMode && revenge && npc.ai[2] % 6f == 0f)
if (CalamityWorld.LegendaryMode && npc.ai[2] % 6f == 0f)
{
// Rotation and direction
int dir = Math.Sign(player.Center.X - npc.Center.X);
@@ -1517,13 +1517,13 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
Vector2 phase3GoreDirection = npc.rotation.ToRotationVector2() * (Vector2.UnitX * npc.direction) * (npc.width + 20) / 2f + npc.Center;
int type = ModContent.ProjectileType<OldDukeGore>();
int damage = npc.GetProjectileDamage(type);
int totalGore = Main.getGoodWorld ? 40 : 20;
int totalGore = CalamityWorld.LegendaryMode ? 40 : 20;
for (int i = 0; i < totalGore; i++)
{
float velocityX = npc.direction * goreVelocityX * (Main.rand.NextFloat(0.2f, 0.8f) + 0.5f);
float velocityY = goreVelocityY * (Main.rand.NextFloat(0.2f, 0.8f) + 0.5f);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocityX *= Main.rand.NextFloat() + 0.5f;
velocityY *= Main.rand.NextFloat() + 0.5f;
@@ -1546,7 +1546,7 @@ namespace CalamityMod.NPCs.CalamityAIs.CalamityBossAIs
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X + x), (int)(npc.Center.Y - calamityGlobalNPC.newAI[2]), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, npc.whoAmI, 0f, 255);
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X - x), (int)(npc.Center.Y - calamityGlobalNPC.newAI[2]), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, npc.whoAmI, 0f, 255);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X + x), (int)(npc.Center.Y - calamityGlobalNPC.newAI[2] * 0.5f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, npc.whoAmI, 0f, 255);
NPC.NewNPC(npc.GetSource_FromAI(), (int)(npc.Center.X - x), (int)(npc.Center.Y - calamityGlobalNPC.newAI[2] * 0.5f), ModContent.NPCType<SulphurousSharkron>(), 0, 0f, 0f, npc.whoAmI, 0f, 255);
+16 -16
View File
@@ -1979,11 +1979,11 @@ namespace CalamityMod.NPCs
else if (npc.type == NPCID.KingSlime)
{
if (CalamityWorld.death)
npc.scale = Main.getGoodWorld ? 6f : 2.5f;
npc.scale = CalamityWorld.LegendaryMode ? 6f : 2.5f;
else
npc.scale = Main.getGoodWorld ? 3f : 1.5f;
npc.scale = CalamityWorld.LegendaryMode ? 3f : 1.5f;
npc.lifeMax = (int)Math.Round(npc.lifeMax * (Main.getGoodWorld ? 1.8 : 1.5));
npc.lifeMax = (int)Math.Round(npc.lifeMax * (CalamityWorld.LegendaryMode ? 1.8 : 1.5));
}
else if ((npc.type == NPCID.Wraith || npc.type == NPCID.Mimic || npc.type == NPCID.Reaper || npc.type == NPCID.PresentMimic || npc.type == NPCID.SandElemental || npc.type == NPCID.Ghost) && CalamityWorld.LegendaryMode)
{
@@ -4124,14 +4124,14 @@ namespace CalamityMod.NPCs
{
npc.TargetClosest();
float velocity = Main.getGoodWorld ? 12f : (CalamityWorld.death || BossRushEvent.BossRushActive) ? 10.5f : 9f;
float velocity = CalamityWorld.LegendaryMode ? 12f : (CalamityWorld.death || BossRushEvent.BossRushActive) ? 10.5f : 9f;
if (npc.ai[1] == 70f)
velocity *= 0.4f;
npc.velocity = (Main.player[npc.target].Center - npc.Center).SafeNormalize(Vector2.UnitY) * velocity;
}
if (Main.getGoodWorld && !npc.dontTakeDamage)
if (CalamityWorld.LegendaryMode && !npc.dontTakeDamage)
{
if ((double)(npc.Center.Y / 16f) < Main.worldSurface)
npc.dontTakeDamage = true;
@@ -6779,7 +6779,7 @@ namespace CalamityMod.NPCs
{
if (Main.netMode != NetmodeID.MultiplayerClient)
{
int slimeAmt = Main.getGoodWorld ? Main.rand.Next(6) + 10 : Main.rand.Next(2) + 2; // 2 to 3 extra
int slimeAmt = CalamityWorld.LegendaryMode ? Main.rand.Next(6) + 10 : Main.rand.Next(2) + 2; // 2 to 3 extra
for (int s = 0; s < slimeAmt; s++)
{
int slime = NPC.NewNPC(npc.GetSource_FromAI(), (int)npc.Center.X, (int)(npc.position.Y + npc.height), NPCID.BlueSlime, 0, 0f, 0f, 0f, 0f, 255);
@@ -6787,8 +6787,8 @@ namespace CalamityMod.NPCs
npc2.SetDefaults(NPCID.BabySlime);
npc2.velocity.X = npc.velocity.X * 2f;
npc2.velocity.Y = npc.velocity.Y;
npc2.velocity.X += Main.rand.Next(-20, 20) * (Main.getGoodWorld ? 0.5f : 0.1f) + s * npc.direction * (Main.getGoodWorld ? 0.5f : 0.3f);
npc2.velocity.Y -= Main.rand.Next(0, 10) * (Main.getGoodWorld ? 0.5f : 0.1f) + s;
npc2.velocity.X += Main.rand.Next(-20, 20) * (CalamityWorld.LegendaryMode ? 0.5f : 0.1f) + s * npc.direction * (CalamityWorld.LegendaryMode ? 0.5f : 0.3f);
npc2.velocity.Y -= Main.rand.Next(0, 10) * (CalamityWorld.LegendaryMode ? 0.5f : 0.1f) + s;
npc2.ai[0] = -1000 * Main.rand.Next(3);
if (Main.dedServ && slime < Main.maxNPCs)
@@ -6801,7 +6801,7 @@ namespace CalamityMod.NPCs
case NPCID.CursedHammer:
case NPCID.EnchantedSword:
case NPCID.CrimsonAxe:
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.justHit = false;
break;
@@ -6812,13 +6812,13 @@ namespace CalamityMod.NPCs
case NPCID.IceTortoise:
case NPCID.BlackRecluse:
case NPCID.BlackRecluseWall:
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.justHit = false;
break;
case NPCID.Paladin:
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.justHit = false;
break;
@@ -6826,7 +6826,7 @@ namespace CalamityMod.NPCs
if (npc.type == NPCType<Plagueshell>())
{
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.justHit = false;
}
}
@@ -7660,7 +7660,7 @@ namespace CalamityMod.NPCs
if (npc.IsABestiaryIconDummy)
return null;
if (Main.LocalPlayer.Calamity().trippy || (npc.type == NPCID.KingSlime && CalamityWorld.LegendaryMode && CalamityWorld.revenge))
if (Main.LocalPlayer.Calamity().trippy || (npc.type == NPCID.KingSlime && CalamityWorld.LegendaryMode))
return new Color(Main.DiscoR, Main.DiscoG, Main.DiscoB, Main.DiscoR);
if (npc.type == NPCID.KingSlime && CalamityWorld.death)
@@ -8352,7 +8352,7 @@ namespace CalamityMod.NPCs
{
Color currentColor = npc.GetAlpha(drawColor);
float opacityScale = 1f - MathHelper.Lerp(0.34f, 1f, npc.life / (float)secondAfterimageSetHealthValue);
float opacity = Main.getGoodWorld ? 0.7f : opacityScale;
float opacity = CalamityWorld.LegendaryMode ? 0.7f : opacityScale;
opacity = MathHelper.Clamp(opacity, 0f, 1f);
currentColor.R = (byte)((float)(int)currentColor.R * opacity);
@@ -8455,7 +8455,7 @@ namespace CalamityMod.NPCs
Color currentColor = npc.GetAlpha(drawColor);
float opacity = (1f - Main.npc[NPC.crimsonBoss].life / (float)Main.npc[NPC.crimsonBoss].lifeMax) * 2f;
opacity *= opacity;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
opacity = 1f;
opacity = MathHelper.Clamp(opacity, 0f, 1f);
@@ -8492,7 +8492,7 @@ namespace CalamityMod.NPCs
{
currentColor = npc.GetAlpha(drawColor);
float opacityScale = 1f - Main.npc[NPC.crimsonBoss].life / (float)secondAfterimageSetHealthValue;
opacity = Main.getGoodWorld ? 1f : opacityScale;
opacity = CalamityWorld.LegendaryMode ? 1f : opacityScale;
opacity = MathHelper.Clamp(opacity, 0f, 1f);
currentColor.R = (byte)((float)(int)currentColor.R * opacity);
+1 -1
View File
@@ -123,7 +123,7 @@ namespace CalamityMod.NPCs.CeaselessVoid
if (NPC.Opacity > 1f)
NPC.Opacity = 1f;
NPC.scale = MathHelper.Lerp(0.05f, Main.getGoodWorld ? 0.5f : 1f, NPC.Opacity);
NPC.scale = MathHelper.Lerp(0.05f, CalamityWorld.LegendaryMode ? 0.5f : 1f, NPC.Opacity);
}
else
{
+5 -5
View File
@@ -31,13 +31,13 @@ namespace CalamityMod.NPCs.Crabulon
NPC.GetNPCDamage();
NPC.width = 14;
NPC.height = 14;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.scale = 2f;
NPC.lifeMax = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 180 : 15;
NPC.lifeMax = CalamityWorld.LegendaryMode ? 180 : 15;
if (BossRushEvent.BossRushActive)
NPC.lifeMax = 8000;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 2;
AIType = -1;
NPC.knockBackResist = 0.5f;
@@ -71,7 +71,7 @@ namespace CalamityMod.NPCs.Crabulon
bool death = CalamityWorld.death || BossRushEvent.BossRushActive;
float xVelocityLimit = BossRushEvent.BossRushActive ? 12f : death ? 8f : revenge ? 6f : 5f;
float yVelocityLimit = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 0.25f : death ? 0.75f : revenge ? 0.9f : 1f;
float yVelocityLimit = CalamityWorld.LegendaryMode ? 0.25f : death ? 0.75f : revenge ? 0.9f : 1f;
// Get a target
if (NPC.target < 0 || NPC.target == Main.maxPlayers || Main.player[NPC.target].dead || !Main.player[NPC.target].active)
@@ -103,7 +103,7 @@ namespace CalamityMod.NPCs.Crabulon
NPC.rotation = NPC.velocity.X * 0.1f;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
float pushVelocity = 0.5f;
foreach (NPC n in Main.ActiveNPCs)
+6 -6
View File
@@ -95,7 +95,7 @@ namespace CalamityMod.NPCs.Crabulon
NPC.Calamity().VulnerableToCold = true;
NPC.Calamity().VulnerableToSickness = true;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
NPC.scale *= 1.5f;
NPC.defense += 12;
@@ -208,7 +208,7 @@ namespace CalamityMod.NPCs.Crabulon
enrageScale += 1f;
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
enrageScale += 0.5f;
if (NPC.ai[0] < 2f)
@@ -285,7 +285,7 @@ namespace CalamityMod.NPCs.Crabulon
walkingVelocity += 0.75f;
if (phase4)
walkingVelocity += 1f;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
walkingVelocity *= 2f;
bool shouldWalkSlower = false;
@@ -982,7 +982,7 @@ namespace CalamityMod.NPCs.Crabulon
{
if (Main.netMode != NetmodeID.MultiplayerClient)
{
int crabShroomSpawnFreq = (int)(NPC.lifeMax * ((CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 0.01 : Main.getGoodWorld ? 0.02 : 0.05));
int crabShroomSpawnFreq = (int)(NPC.lifeMax * (CalamityWorld.LegendaryMode ? 0.01 : CalamityWorld.LegendaryMode ? 0.02 : 0.05));
if ((NPC.life + crabShroomSpawnFreq) < NPC.localAI[0])
{
NPC.localAI[0] = NPC.life;
@@ -994,8 +994,8 @@ namespace CalamityMod.NPCs.Crabulon
int npcType = ModContent.NPCType<CrabShroom>();
int crabShroom = NPC.NewNPC(NPC.GetSource_FromAI(), x, y, npcType);
Main.npc[crabShroom].SetDefaults(npcType);
Main.npc[crabShroom].velocity.X = Main.rand.Next(-50, 51) * (Main.getGoodWorld ? 0.2f : 0.1f);
Main.npc[crabShroom].velocity.Y = Main.rand.Next(-50, -31) * (Main.getGoodWorld ? 0.2f : 0.1f);
Main.npc[crabShroom].velocity.X = Main.rand.Next(-50, 51) * (CalamityWorld.LegendaryMode ? 0.2f : 0.1f);
Main.npc[crabShroom].velocity.Y = Main.rand.Next(-50, -31) * (CalamityWorld.LegendaryMode ? 0.2f : 0.1f);
if (Main.dedServ && crabShroom < Main.maxNPCs)
NetMessage.SendData(MessageID.SyncNPC, -1, -1, null, crabShroom);
}
+10 -10
View File
@@ -111,7 +111,7 @@ namespace CalamityMod.NPCs.Cryogen
NPC.HitSound = HitSound;
NPC.DeathSound = DeathSound;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.8f;
if (Main.zenithWorld)
@@ -294,7 +294,7 @@ namespace CalamityMod.NPCs.Cryogen
else if (NPC.timeLeft < 1800)
NPC.timeLeft = 1800;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
int spawnType = Main.zenithWorld ? NPCID.RedDevil : NPCID.IceGolem;
if (!NPC.AnyNPCs(spawnType))
@@ -322,13 +322,13 @@ namespace CalamityMod.NPCs.Cryogen
float chargePhaseGateValue = bossRush ? 240f : 360f;
float chargeDuration = 60f;
float chargeTelegraphTime = NPC.ai[0] == 2f ? ((CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 60f : 80f) : ((CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 90f : 120f);
float chargeTelegraphTime = NPC.ai[0] == 2f ? (CalamityWorld.LegendaryMode ? 60f : 80f) : (CalamityWorld.LegendaryMode ? 90f : 120f);
float chargeTelegraphMaxRotationIncrement = 1f;
float chargeTelegraphRotationIncrement = chargeTelegraphMaxRotationIncrement / chargeTelegraphTime;
float chargeSlowDownTime = 15f;
float chargeVelocityMin = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 24f : 12f;
float chargeVelocityMax = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 42f : 30f;
if (Main.getGoodWorld)
float chargeVelocityMin = CalamityWorld.LegendaryMode ? 24f : 12f;
float chargeVelocityMax = CalamityWorld.LegendaryMode ? 42f : 30f;
if (CalamityWorld.LegendaryMode)
{
chargePhaseGateValue *= 0.7f;
chargeDuration *= 0.8f;
@@ -414,7 +414,7 @@ namespace CalamityMod.NPCs.Cryogen
playerYDist *= playerDistance;
float inertia = 50f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.5f;
NPC.velocity.X = (NPC.velocity.X * inertia + playerXDist) / (inertia + 1f);
@@ -688,7 +688,7 @@ namespace CalamityMod.NPCs.Cryogen
playerYDist *= playerDistance;
float inertia = 50f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.5f;
NPC.velocity.X = (NPC.velocity.X * inertia + playerXDist) / (inertia + 1f);
@@ -851,7 +851,7 @@ namespace CalamityMod.NPCs.Cryogen
playerYDist *= playerDistance;
float inertia = 50f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.5f;
NPC.velocity.X = (NPC.velocity.X * inertia + playerXDist) / (inertia + 1f);
@@ -1130,7 +1130,7 @@ namespace CalamityMod.NPCs.Cryogen
}
float inertia = 30f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.5f;
NPC.velocity.X = (NPC.velocity.X * inertia + playerchargeXDist) / (inertia + 1f);
+1 -1
View File
@@ -31,7 +31,7 @@ namespace CalamityMod.NPCs.Cryogen
NPC.GetNPCDamage();
NPC.width = 216;
NPC.height = 216;
NPC.scale *= (CalamityWorld.death || BossRushEvent.BossRushActive || Main.getGoodWorld) ? 0.8f : 1f;
NPC.scale *= (CalamityWorld.death || BossRushEvent.BossRushActive || CalamityWorld.LegendaryMode) ? 0.8f : 1f;
NPC.DR_NERD(0.4f);
NPC.LifeMaxNERB(2800, 3360, 33600);
NPC.Opacity = 0f;
+3 -3
View File
@@ -44,11 +44,11 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.height = 88;
NPC.defense = 5;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.defense += 27;
NPC.LifeMaxNERB(1500, 1800, 40000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax = 4800;
NPC.aiStyle = -1;
AIType = -1;
@@ -173,7 +173,7 @@ namespace CalamityMod.NPCs.DesertScourge
// Calculate contact damage based on velocity
float maxChaseSpeed = Main.zenithWorld ? DesertNuisanceHead.SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? DesertNuisanceHead.SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? DesertNuisanceHead.SegmentVelocity_GoodWorld :
death ? DesertNuisanceHead.SegmentVelocity_Death :
DesertNuisanceHead.SegmentVelocity_Expert;
maxChaseSpeed += maxChaseSpeed * 0.2f * (1f - lifeRatio);
@@ -44,11 +44,11 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.height = 78;
NPC.defense = 4;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.defense += 26;
NPC.LifeMaxNERB(1300, 1560, 35000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax = 4000;
NPC.aiStyle = -1;
AIType = -1;
@@ -181,7 +181,7 @@ namespace CalamityMod.NPCs.DesertScourge
// Calculate contact damage based on velocity
float maxChaseSpeed = Main.zenithWorld ? DesertNuisanceHeadYoung.SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? DesertNuisanceHeadYoung.SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? DesertNuisanceHeadYoung.SegmentVelocity_GoodWorld :
death ? DesertNuisanceHeadYoung.SegmentVelocity_Death :
DesertNuisanceHeadYoung.SegmentVelocity_Expert;
maxChaseSpeed += maxChaseSpeed * 0.2f * (1f - lifeRatio);
+6 -6
View File
@@ -56,14 +56,14 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.GetNPCDamage();
NPC.defense = 3;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.defense += 19;
NPC.width = 88;
NPC.height = 88;
NPC.LifeMaxNERB(1500, 1800, 40000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax = 4800;
NPC.aiStyle = -1;
AIType = -1;
@@ -146,7 +146,7 @@ namespace CalamityMod.NPCs.DesertScourge
speed += 0.085f * enrageScale;
turnSpeed += 0.17f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
speed *= 1.1f;
turnSpeed *= 1.2f;
@@ -168,7 +168,7 @@ namespace CalamityMod.NPCs.DesertScourge
{
int previous = NPC.whoAmI;
int minLength = 8;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
minLength *= 2;
int bodyTypeAIVariable = 0;
@@ -272,7 +272,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.spriteDirection = -1;
float maxChaseSpeed = Main.zenithWorld ? SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? SegmentVelocity_GoodWorld :
death ? SegmentVelocity_Death :
SegmentVelocity_Expert;
maxChaseSpeed += maxChaseSpeed * 0.2f * (1f - lifeRatio);
@@ -299,7 +299,7 @@ namespace CalamityMod.NPCs.DesertScourge
}
}
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
speed *= 1.5f;
turnSpeed *= 1.5f;
@@ -48,14 +48,14 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.GetNPCDamage();
NPC.defense = 2;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.defense += 18;
NPC.width = 78;
NPC.height = 78;
NPC.LifeMaxNERB(1300, 1560, 35000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax = 4000;
NPC.aiStyle = -1;
AIType = -1;
@@ -142,7 +142,7 @@ namespace CalamityMod.NPCs.DesertScourge
speed += 0.07f * enrageScale;
turnSpeed += 0.14f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
speed *= 1.1f;
turnSpeed *= 1.2f;
@@ -203,7 +203,7 @@ namespace CalamityMod.NPCs.DesertScourge
{
int previous = NPC.whoAmI;
int minLength = 8;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
minLength *= 2;
int bodyTypeAIVariable = 0;
@@ -311,7 +311,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.spriteDirection = -1;
float maxChaseSpeed = Main.zenithWorld ? SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? SegmentVelocity_GoodWorld :
death ? SegmentVelocity_Death :
SegmentVelocity_Expert;
maxChaseSpeed += maxChaseSpeed * 0.2f * (1f - lifeRatio);
@@ -338,7 +338,7 @@ namespace CalamityMod.NPCs.DesertScourge
}
}
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
speed *= 1.5f;
turnSpeed *= 1.5f;
+3 -3
View File
@@ -26,11 +26,11 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.height = 88;
NPC.defense = 8;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.defense += 34;
NPC.LifeMaxNERB(1500, 1800, 40000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax = 4800;
NPC.aiStyle = -1;
AIType = -1;
@@ -137,7 +137,7 @@ namespace CalamityMod.NPCs.DesertScourge
// Calculate contact damage based on velocity
float maxChaseSpeed = Main.zenithWorld ? DesertNuisanceHead.SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? DesertNuisanceHead.SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? DesertNuisanceHead.SegmentVelocity_GoodWorld :
death ? DesertNuisanceHead.SegmentVelocity_Death :
DesertNuisanceHead.SegmentVelocity_Expert;
maxChaseSpeed += maxChaseSpeed * 0.2f * (1f - lifeRatio);
@@ -26,11 +26,11 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.height = 78;
NPC.defense = 7;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.defense += 33;
NPC.LifeMaxNERB(1300, 1560, 35000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax = 4000;
NPC.aiStyle = -1;
AIType = -1;
@@ -145,7 +145,7 @@ namespace CalamityMod.NPCs.DesertScourge
// Calculate contact damage based on velocity
float maxChaseSpeed = Main.zenithWorld ? DesertNuisanceHeadYoung.SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? DesertNuisanceHeadYoung.SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? DesertNuisanceHeadYoung.SegmentVelocity_GoodWorld :
death ? DesertNuisanceHeadYoung.SegmentVelocity_Death :
DesertNuisanceHeadYoung.SegmentVelocity_Expert;
maxChaseSpeed += maxChaseSpeed * 0.2f * (1f - lifeRatio);
+3 -3
View File
@@ -50,7 +50,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.DR_NERD(0.05f);
NPC.LifeMaxNERB(4200, 5000, 1150000);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 4;
NPC.aiStyle = -1;
AIType = -1;
@@ -65,7 +65,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.netAlways = true;
NPC.dontCountMe = true;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.4f;
NPC.Calamity().VulnerableToCold = true;
@@ -217,7 +217,7 @@ namespace CalamityMod.NPCs.DesertScourge
// Calculate contact damage based on velocity
float maxChaseSpeed = Main.zenithWorld ? DesertScourgeHead.SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? DesertScourgeHead.SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? DesertScourgeHead.SegmentVelocity_GoodWorld :
death ? DesertScourgeHead.SegmentVelocity_Death :
expertMode ? DesertScourgeHead.SegmentVelocity_Expert :
DesertScourgeHead.SegmentVelocity_Normal;
+8 -8
View File
@@ -95,7 +95,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.height = 104;
NPC.LifeMaxNERB(4200, 5000, 1150000);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 4;
NPC.aiStyle = -1;
AIType = -1;
@@ -110,7 +110,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.DeathSound = DeathSound;
NPC.netAlways = true;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.4f;
if (Main.zenithWorld)
@@ -257,7 +257,7 @@ namespace CalamityMod.NPCs.DesertScourge
speed += 0.085f * enrageScale;
turnSpeed += 0.17f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
speed *= 1.1f;
turnSpeed *= 1.2f;
@@ -431,7 +431,7 @@ namespace CalamityMod.NPCs.DesertScourge
{
int previous = NPC.whoAmI;
int minLength = death ? 24 : revenge ? 21 : expertMode ? 18 : 15;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
minLength *= 3;
int bodyTypeAIVariable = 0;
@@ -542,7 +542,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.spriteDirection = -1;
float maxChaseSpeed = Main.zenithWorld ? SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? SegmentVelocity_GoodWorld :
death ? SegmentVelocity_Death :
expertMode ? SegmentVelocity_Expert :
SegmentVelocity_Normal;
@@ -601,15 +601,15 @@ namespace CalamityMod.NPCs.DesertScourge
{
// Spit a huge spread of sand upwards that falls down
SoundEngine.PlaySound(SandBlastSound, NPC.Center);
float velocity = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 16f : bossRush ? 10f : death ? 8.5f : revenge ? 8f : expertMode ? 7.5f : 6f;
float velocity = CalamityWorld.LegendaryMode ? 16f : bossRush ? 10f : death ? 8.5f : revenge ? 8f : expertMode ? 7.5f : 6f;
int type = ModContent.ProjectileType<DesertScourgeSpit>();
int damage = NPC.GetProjectileDamage(type);
Vector2 projectileVelocity = (NPC.Center + NPC.velocity * 10f - NPC.Center).SafeNormalize(Vector2.UnitY) * velocity;
int numProj = bossRush ? 30 : death ? 24 : revenge ? 21 : expertMode ? 18 : 12;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
numProj *= 2;
int spread = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 120 : 90;
int spread = CalamityWorld.LegendaryMode ? 120 : 90;
float rotation = MathHelper.ToRadians(spread);
for (int i = 0; i < numProj; i++)
{
+3 -3
View File
@@ -30,7 +30,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.DR_NERD(0.1f);
NPC.LifeMaxNERB(4200, 5000, 1150000);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 4;
NPC.aiStyle = -1;
AIType = -1;
@@ -45,7 +45,7 @@ namespace CalamityMod.NPCs.DesertScourge
NPC.netAlways = true;
NPC.dontCountMe = true;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.4f;
NPC.Calamity().VulnerableToCold = true;
@@ -179,7 +179,7 @@ namespace CalamityMod.NPCs.DesertScourge
// Calculate contact damage based on velocity
float maxChaseSpeed = Main.zenithWorld ? DesertScourgeHead.SegmentVelocity_ZenithSeed :
Main.getGoodWorld ? DesertScourgeHead.SegmentVelocity_GoodWorld :
CalamityWorld.LegendaryMode ? DesertScourgeHead.SegmentVelocity_GoodWorld :
death ? DesertScourgeHead.SegmentVelocity_Death :
expertMode ? DesertScourgeHead.SegmentVelocity_Expert :
DesertScourgeHead.SegmentVelocity_Normal;
+2 -2
View File
@@ -89,7 +89,7 @@ namespace CalamityMod.NPCs.DevourerofGods
NPC.BossBar = Main.BigBossProgressBar.NeverValid;
NPC.dontCountMe = true;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.5f;
// Scale HP in Master
@@ -275,7 +275,7 @@ namespace CalamityMod.NPCs.DevourerofGods
float segmentVelocity = bossRush ? 19f : death ? 17.5f : 16f;
if (expertMode)
segmentVelocity += 4f * (1f - lifeRatio);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
segmentVelocity *= 1.1f;
// Calculate contact damage based on velocity
+10 -10
View File
@@ -213,7 +213,7 @@ namespace CalamityMod.NPCs.DevourerofGods
NPC.DeathSound = SoundID.NPCDeath14;
NPC.netAlways = true;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.5f;
// Scale HP in Master
@@ -425,7 +425,7 @@ namespace CalamityMod.NPCs.DevourerofGods
groundPhaseTurnSpeed += Vector2.Distance(destination, NPC.Center) * 0.0002f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
segmentVelocity *= 1.1f;
speed *= 1.1f;
@@ -751,10 +751,10 @@ namespace CalamityMod.NPCs.DevourerofGods
// Fireballs
// Check angle and distance to make sure it's realistic that they'd be fired
if (NPC.Opacity >= 1f && (distanceFromTarget > 480f || (CalamityWorld.LegendaryMode && CalamityWorld.revenge)) && (player.Center - NPC.Center).SafeNormalize(Vector2.UnitY).ToRotation().AngleTowards(NPC.velocity.ToRotation(), MathHelper.PiOver4) == NPC.velocity.ToRotation())
if (NPC.Opacity >= 1f && (distanceFromTarget > 480f || CalamityWorld.LegendaryMode) && (player.Center - NPC.Center).SafeNormalize(Vector2.UnitY).ToRotation().AngleTowards(NPC.velocity.ToRotation(), MathHelper.PiOver4) == NPC.velocity.ToRotation())
{
calamityGlobalNPC.newAI[0] += 1f;
if (calamityGlobalNPC.newAI[0] >= ((CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 30f : 150f) && calamityGlobalNPC.newAI[0] % ((CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 30f : phase7 ? 30f : 60f) == 0f)
if (calamityGlobalNPC.newAI[0] >= (CalamityWorld.LegendaryMode ? 30f : 150f) && calamityGlobalNPC.newAI[0] % (CalamityWorld.LegendaryMode ? 30f : phase7 ? 30f : 60f) == 0f)
{
float fireballSpeed = 8f;
Vector2 fireballVelocity = Vector2.Normalize(player.Center - NPC.Center) * fireballSpeed + NPC.velocity * 0.5f;
@@ -769,7 +769,7 @@ namespace CalamityMod.NPCs.DevourerofGods
if (Main.netMode != NetmodeID.MultiplayerClient)
Projectile.NewProjectile(NPC.GetSource_FromAI(), NPC.Center, fireballVelocity, type, damage, 0f, Main.myPlayer);
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
{
for (int l = 0; l < 8; l++)
{
@@ -1112,7 +1112,7 @@ namespace CalamityMod.NPCs.DevourerofGods
speedCopy += Vector2.Distance(destination, NPC.Center) * 0.005f;
turnSpeedCopy += Vector2.Distance(destination, NPC.Center) * 0.00025f;
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
{
if ((player.Center - NPC.Center).SafeNormalize(Vector2.UnitY).ToRotation().AngleTowards(NPC.velocity.ToRotation(), MathHelper.PiOver4) == NPC.velocity.ToRotation())
speedCopy *= 2f;
@@ -1270,7 +1270,7 @@ namespace CalamityMod.NPCs.DevourerofGods
else if (increaseSpeed)
groundPhaseTurnSpeed *= 2f;
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
{
if ((player.Center - NPC.Center).SafeNormalize(Vector2.UnitY).ToRotation().AngleTowards(NPC.velocity.ToRotation(), MathHelper.PiOver4) == NPC.velocity.ToRotation())
segmentVelocity *= 2f;
@@ -1871,7 +1871,7 @@ namespace CalamityMod.NPCs.DevourerofGods
turnSpeedCopy += distanceFromTarget * 0.0001f * (1f - lifeRatio);
}
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
{
if ((player.Center - NPC.Center).SafeNormalize(Vector2.UnitY).ToRotation().AngleTowards(NPC.velocity.ToRotation(), MathHelper.PiOver4) == NPC.velocity.ToRotation())
speedCopy *= 2f;
@@ -2015,7 +2015,7 @@ namespace CalamityMod.NPCs.DevourerofGods
else if (increaseSpeed)
groundPhaseTurnSpeed *= 2f;
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
{
if ((player.Center - NPC.Center).SafeNormalize(Vector2.UnitY).ToRotation().AngleTowards(NPC.velocity.ToRotation(), MathHelper.PiOver4) == NPC.velocity.ToRotation())
segmentVelocity *= 2f;
@@ -2331,7 +2331,7 @@ namespace CalamityMod.NPCs.DevourerofGods
float mult = revenge ? 1.5f : 3f;
for (int i = 0; i < totalSpreads; i++)
{
int totalProjectiles = (CalamityWorld.LegendaryMode && revenge) ? 30 : bossRush ? 18 : 12;
int totalProjectiles = (CalamityWorld.LegendaryMode) ? 30 : bossRush ? 18 : 12;
float radians = MathHelper.TwoPi / totalProjectiles;
float newVelocity = finalVelocity - i * mult;
float velocityMult = 1f + ((finalVelocity - newVelocity) / (newVelocity * 2f) / 100f);
+2 -2
View File
@@ -85,7 +85,7 @@ namespace CalamityMod.NPCs.DevourerofGods
NPC.takenDamageMultiplier = 1.25f;
NPC.dontCountMe = true;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.5f;
// Scale HP in Master
@@ -309,7 +309,7 @@ namespace CalamityMod.NPCs.DevourerofGods
float segmentVelocity = bossRush ? 19f : death ? 17.5f : 16f;
if (expertMode)
segmentVelocity += 4f * (1f - lifeRatio);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
segmentVelocity *= 1.1f;
// Calculate contact damage based on velocity
+5 -5
View File
@@ -424,7 +424,7 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
float timeToLineUpAttack = 30f;
float timeToLineUpCharge = bossRush ? 45f : death ? 60f : revenge ? 68f : expertMode ? 75f : 90f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
timeToLineUpAttack *= 0.5f;
timeToLineUpCharge *= 0.5f;
@@ -445,7 +445,7 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
// Charge velocity
float chargeVelocity = bossRush ? 115f : death ? 105f : revenge ? 101.25f : expertMode ? 97.5f : 90f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
baseVelocity *= 1.5f;
chargeVelocity *= 1.15f;
@@ -466,7 +466,7 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
float rocketPhaseDuration = lastMechAlive ? 60f : 90f;
int numRockets = nerfedAttacks ? 2 : 3;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
numRockets += 3;
// Default vector to fly to
@@ -488,7 +488,7 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
int randomLocationVarianceX = shouldGetBuffedByBerserkPhase ? 50 : 20;
int randomLocationVarianceY = shouldGetBuffedByBerserkPhase ? 250 : 100;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
randomLocationVarianceX *= 2;
randomLocationVarianceY *= 2;
@@ -1180,7 +1180,7 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
NPC.ForceNetUpdate();
// Plasma bolts on charge
if (Main.netMode != NetmodeID.MultiplayerClient && (!(Main.zenithWorld && !exoMechdusa) || (CalamityWorld.LegendaryMode && revenge)))
if (Main.netMode != NetmodeID.MultiplayerClient && (!(Main.zenithWorld && !exoMechdusa) || (CalamityWorld.LegendaryMode)))
{
int totalProjectiles = bossRush ? 16 : death ? 12 : 8;
float radians = MathHelper.TwoPi / totalProjectiles;
+2 -2
View File
@@ -888,7 +888,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
else
{
// Enrage if the target is more than the deathray length away
if ((distanceFromTarget > DeathrayEnrageDistance || (CalamityWorld.LegendaryMode && revenge)) && EnragedState == (float)Enraged.No)
if ((distanceFromTarget > DeathrayEnrageDistance || (CalamityWorld.LegendaryMode)) && EnragedState == (float)Enraged.No)
{
// Play enrage sound
if (Main.LocalPlayer.active && !Main.LocalPlayer.dead && Vector2.Distance(Main.LocalPlayer.Center, NPC.Center) < soundDistance)
@@ -908,7 +908,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
NPC.velocity *= decelerationVelocityMult;
int totalProjectiles = bossRush ? 12 : death ? 10 : revenge ? 9 : expertMode ? 8 : 6;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
totalProjectiles += 4;
float radians = MathHelper.TwoPi / totalProjectiles;
+4 -4
View File
@@ -457,7 +457,7 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
float attackPhaseGateValue = shouldGetBuffedByBerserkPhase ? berserkAttackTime : normalAttackTime;
float timeToLineUpAttack = phase2 ? 30f : 45f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
timeToLineUpAttack *= 0.5f;
// Spin variables
@@ -496,7 +496,7 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
// Charge variables
float chargeVelocity = nerfedAttacks ? 60f : bossRush ? 81f : death ? 74f : revenge ? 70.5f : expertMode ? 67f : 60f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeVelocity *= 1.15f;
float chargeDistance = 2000f;
@@ -521,7 +521,7 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
float baseVelocity = ((AIState == (int)Phase.Deathray || lineUpAttack || AIState == (int)Phase.LaserShotgun) ? 40f : 20f) * baseVelocityMult;
float decelerationVelocityMult = 0.85f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
baseVelocity *= 1.5f;
// Laser shotgun variables
@@ -535,7 +535,7 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
int randomLocationVarianceX = shouldGetBuffedByBerserkPhase ? 50 : 20;
int randomLocationVarianceY = shouldGetBuffedByBerserkPhase ? 250 : 100;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
randomLocationVarianceX *= 2;
randomLocationVarianceY *= 2;
+1 -1
View File
@@ -531,7 +531,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
else
baseVelocity *= increaseSpeedMult;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
baseVelocity *= 1.15f;
// Calculate contact damage based on velocity
+1 -1
View File
@@ -534,7 +534,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
else
baseVelocity *= increaseSpeedMult;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
baseVelocity *= 1.15f;
// Calculate contact damage based on velocity
+2 -2
View File
@@ -253,7 +253,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
}
public float GetSlowdownAreaEdgeRadius(bool lastMechAlive) =>
(BossRushEvent.BossRushActive ? 400f : CalamityWorld.death ? 600f : CalamityWorld.revenge ? 700f : Main.expertMode ? 800f : 1000f) * (lastMechAlive ? 0.6f : 1f) * (Main.zenithWorld && !exoMechdusa ? 2 : Main.getGoodWorld ? 0.5f : 1f);
(BossRushEvent.BossRushActive ? 400f : CalamityWorld.death ? 600f : CalamityWorld.revenge ? 700f : Main.expertMode ? 800f : 1000f) * (lastMechAlive ? 0.6f : 1f) * (Main.zenithWorld && !exoMechdusa ? 2 : CalamityWorld.LegendaryMode ? 0.5f : 1f);
public int CheckForOtherMechs(ref int targetIndex, out bool exoPrimeAlive, out bool exoTwinsAlive)
{
@@ -527,7 +527,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
else
baseVelocity *= increaseSpeedMult;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
baseVelocity *= 1.15f;
float turnDegrees = baseVelocity * 0.1f * (shouldGetBuffedByBerserkPhase ? 1.25f : 1.1f);
+1 -1
View File
@@ -532,7 +532,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
else
baseVelocity *= increaseSpeedMult;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
baseVelocity *= 1.15f;
// Calculate contact damage based on velocity
+2 -2
View File
@@ -24,10 +24,10 @@ namespace CalamityMod.NPCs.HiveMind
NPC.lifeMax = 120;
if (BossRushEvent.BossRushActive)
NPC.lifeMax = 2000;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 4;
if ((CalamityWorld.LegendaryMode && CalamityWorld.revenge))
if (CalamityWorld.LegendaryMode)
NPC.reflectsProjectiles = true;
NPC.aiStyle = -1;
+6 -6
View File
@@ -29,7 +29,7 @@ namespace CalamityMod.NPCs.HiveMind
NPC.lifeMax = 75;
if (BossRushEvent.BossRushActive)
NPC.lifeMax = 1800;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 4;
NPC.aiStyle = -1;
@@ -73,9 +73,9 @@ namespace CalamityMod.NPCs.HiveMind
if (NPC.target < 0 || NPC.target == Main.maxPlayers || Main.player[NPC.target].dead || !Main.player[NPC.target].active)
NPC.TargetClosest();
float velocity = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 10f : death ? 7f : revenge ? 6f : 4f;
float acceleration = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 0.5f : death ? 0.35f : revenge ? 0.3f : 0.2f;
float deceleration = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 0.9f : death ? 0.95f : revenge ? 0.96f : 0.98f;
float velocity = CalamityWorld.LegendaryMode ? 10f : death ? 7f : revenge ? 6f : 4f;
float acceleration = CalamityWorld.LegendaryMode ? 0.5f : death ? 0.35f : revenge ? 0.3f : 0.2f;
float deceleration = CalamityWorld.LegendaryMode ? 0.9f : death ? 0.95f : revenge ? 0.96f : 0.98f;
if (BossRushEvent.BossRushActive)
{
velocity *= 2f;
@@ -121,7 +121,7 @@ namespace CalamityMod.NPCs.HiveMind
if (dropRain && Main.netMode != NetmodeID.MultiplayerClient)
{
NPC.ai[0] += 1f;
float rainDropRate = Main.getGoodWorld ? 10f : death ? 15f : revenge ? 20f : 30f;
float rainDropRate = CalamityWorld.LegendaryMode ? 10f : death ? 15f : revenge ? 20f : 30f;
if (NPC.ai[0] >= rainDropRate)
{
NPC.ai[0] = 0f;
@@ -129,7 +129,7 @@ namespace CalamityMod.NPCs.HiveMind
int shaderainYos = (int)(NPC.position.Y + NPC.height + 4f);
int type = ModContent.ProjectileType<ShaderainHostile>();
int damage = NPC.GetProjectileDamage(type);
float randomXVelocity = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? Main.rand.NextFloat() * 5f : 0f;
float randomXVelocity = CalamityWorld.LegendaryMode ? Main.rand.NextFloat() * 5f : 0f;
float velocityY = 8f;
Projectile.NewProjectile(NPC.GetSource_FromAI(), shaderainXPos, shaderainYos, randomXVelocity, velocityY, type, damage, 0f, Main.myPlayer);
}
+4 -4
View File
@@ -34,7 +34,7 @@ namespace CalamityMod.NPCs.HiveMind
NPC.lifeMax = 50;
if (BossRushEvent.BossRushActive)
NPC.lifeMax = 1300;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 2;
NPC.knockBackResist = 0.9f;
@@ -110,7 +110,7 @@ namespace CalamityMod.NPCs.HiveMind
float hiveMindVelocity = Main.npc[hiveMind].velocity.Length();
float relocateSpeed = getFuckedAI ? 1.2f : death ? 0.8f : revenge ? 0.7f : expertMode ? 0.6f : 0.5f;
float acceleration = 0.8f;
float distanceFromMind = Main.getGoodWorld ? 256f : 128f;
float distanceFromMind = CalamityWorld.LegendaryMode ? 256f : 128f;
float hiveMindX = Main.npc[hiveMind].Center.X;
float hiveMindY = Main.npc[hiveMind].Center.Y;
@@ -183,7 +183,7 @@ namespace CalamityMod.NPCs.HiveMind
if (Collision.CanHit(NPC.position, NPC.width, NPC.height, Main.player[Main.npc[hiveMind].target].position, Main.player[Main.npc[hiveMind].target].width, Main.player[Main.npc[hiveMind].target].height))
{
float projSpeed = death ? 8f : revenge ? 7f : expertMode ? 6f : 4f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
projSpeed *= 1.5f;
Vector2 projDirection = NPC.Center;
@@ -193,7 +193,7 @@ namespace CalamityMod.NPCs.HiveMind
playerDist = projSpeed / playerDist;
playerX *= playerDist;
playerY *= playerDist;
int type = (CalamityWorld.LegendaryMode && CalamityWorld.revenge && Main.rand.NextBool(5)) ? ProjectileID.CursedFlameHostile : ModContent.ProjectileType<VileClot>();
int type = (CalamityWorld.LegendaryMode && Main.rand.NextBool(5)) ? ProjectileID.CursedFlameHostile : ModContent.ProjectileType<VileClot>();
int damage = type == ProjectileID.CursedFlameHostile ? 30 : NPC.GetProjectileDamage(type);
Vector2 projectileVelocity = new Vector2(playerX, playerY);
if (type == ProjectileID.CursedFlameHostile)
+4 -4
View File
@@ -38,7 +38,7 @@ namespace CalamityMod.NPCs.HiveMind
NPC.lifeMax = 75;
if (BossRushEvent.BossRushActive)
NPC.lifeMax = 1300;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 2;
NPC.knockBackResist = 0.9f;
@@ -104,7 +104,7 @@ namespace CalamityMod.NPCs.HiveMind
float hiveMindVelocity = Main.npc[hiveMind].velocity.Length();
float relocateSpeed = getFuckedAI ? 1.2f : death ? 0.8f : revenge ? 0.7f : expertMode ? 0.6f : 0.5f;
float acceleration = 0.8f;
float distanceFromMind = Main.getGoodWorld ? 192f : 96f;
float distanceFromMind = CalamityWorld.LegendaryMode ? 192f : 96f;
float hiveMindX = Main.npc[hiveMind].Center.X;
float hiveMindY = Main.npc[hiveMind].Center.Y;
@@ -177,7 +177,7 @@ namespace CalamityMod.NPCs.HiveMind
if (Collision.CanHit(NPC.position, NPC.width, NPC.height, Main.player[Main.npc[hiveMind].target].position, Main.player[Main.npc[hiveMind].target].width, Main.player[Main.npc[hiveMind].target].height))
{
float projSpeed = death ? 8f : revenge ? 7f : expertMode ? 6f : 4f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
projSpeed *= 1.5f;
Vector2 projDirection = NPC.Center;
@@ -187,7 +187,7 @@ namespace CalamityMod.NPCs.HiveMind
playerDist = projSpeed / playerDist;
playerX *= playerDist;
playerY *= playerDist;
int type = (CalamityWorld.LegendaryMode && CalamityWorld.revenge && Main.rand.NextBool(5)) ? ProjectileID.CursedFlameHostile : ModContent.ProjectileType<VileClot>();
int type = (CalamityWorld.LegendaryMode && Main.rand.NextBool(5)) ? ProjectileID.CursedFlameHostile : ModContent.ProjectileType<VileClot>();
int damage = type == ProjectileID.CursedFlameHostile ? 30 : NPC.GetProjectileDamage(type);
Vector2 projectileVelocity = new Vector2(playerX, playerY);
if (type == ProjectileID.CursedFlameHostile)
+3 -3
View File
@@ -203,7 +203,7 @@ namespace CalamityMod.NPCs.HiveMind
vileSpitFireRate = 12;
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
reelbackFade *= 10;
arcTime *= 0.5f;
@@ -574,7 +574,7 @@ namespace CalamityMod.NPCs.HiveMind
{
NPC.localAI[0] = 1f;
int maxBlobs = death ? 15 : revenge ? 7 : expertMode ? 6 : 5;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
maxBlobs *= 2;
if (Main.zenithWorld)
maxBlobs = 50;
@@ -1168,7 +1168,7 @@ namespace CalamityMod.NPCs.HiveMind
int type = ModContent.ProjectileType<ShadeNimbusHostile>();
int damage = NPC.GetProjectileDamage(type);
Vector2 cloudSpawnPos = new Vector2(NPC.position.X + Main.rand.Next(NPC.width), NPC.position.Y + Main.rand.Next(NPC.height));
Vector2 randomVelocity = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? Main.rand.NextVector2CircularEdge(4f, 4f) : Vector2.Zero;
Vector2 randomVelocity = CalamityWorld.LegendaryMode ? Main.rand.NextVector2CircularEdge(4f, 4f) : Vector2.Zero;
Projectile.NewProjectile(NPC.GetSource_FromAI(), cloudSpawnPos, randomVelocity, type, damage, 0, Main.myPlayer, 11f);
}
+2 -2
View File
@@ -25,7 +25,7 @@ namespace CalamityMod.NPCs.HiveMind
NPC.width = 30; //324
NPC.height = 30; //216
NPC.defense = 0;
NPC.lifeMax = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 10 : 1000;
NPC.lifeMax = CalamityWorld.LegendaryMode ? 10 : 1000;
NPC.knockBackResist = 0f;
NPC.chaseable = false;
NPC.HitSound = SoundID.NPCHit1;
@@ -131,7 +131,7 @@ namespace CalamityMod.NPCs.HiveMind
{
Dust.NewDust(NPC.position, NPC.width, NPC.height, DustID.Demonite, hit.HitDirection, -1f, 0, default, 1f);
}
if (Main.netMode != NetmodeID.MultiplayerClient && (!NPC.AnyNPCs(ModContent.NPCType<HiveMind>()) || (CalamityWorld.LegendaryMode && CalamityWorld.revenge)))
if (Main.netMode != NetmodeID.MultiplayerClient && (!NPC.AnyNPCs(ModContent.NPCType<HiveMind>()) || CalamityWorld.LegendaryMode))
{
Vector2 spawnAt = NPC.Bottom;
NPC.NewNPC(NPC.GetSource_Death(), (int)spawnAt.X, (int)spawnAt.Y, ModContent.NPCType<HiveMind>());
+11 -11
View File
@@ -83,7 +83,7 @@ namespace CalamityMod.NPCs.Leviathan
NPC.Calamity().VulnerableToElectricity = true;
NPC.Calamity().VulnerableToWater = false;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.8f;
if (Main.zenithWorld)
@@ -192,9 +192,9 @@ namespace CalamityMod.NPCs.Leviathan
bubbleVelocity += 4f * enrageScale;
if (!leviAlive)
bubbleVelocity += 2f * (1f - lifeRatio);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
bubbleVelocity *= 1.15f;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
bubbleVelocity *= 2f;
// Phases
@@ -617,14 +617,14 @@ namespace CalamityMod.NPCs.Leviathan
float velocity = death ? 13.5f : 12f;
velocity += 6f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
velocity *= 1.15f;
Vector2 chargeSetupLocation = Vector2.Normalize(targetVector - NPC.Center - NPC.velocity) * velocity;
float acceleration = death ? 0.28f : 0.25f;
acceleration += 0.2f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
acceleration *= 1.15f;
if (Math.Abs(NPC.Center.Y - targetVector.Y) > 50f * NPC.scale || Math.Abs(NPC.Center.X - player.Center.X) > 350f * NPC.scale)
@@ -654,7 +654,7 @@ namespace CalamityMod.NPCs.Leviathan
float telegraphDist = 500f;
// In Legendary, the projectiles she fires is randomized
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
LegendaryModeAttackChosen = Main.rand.Next(3);
if (LegendaryModeAttackChosen == 2)
@@ -708,7 +708,7 @@ namespace CalamityMod.NPCs.Leviathan
int totalProjectiles = 8;
int projectileDistance = 600;
int type = ModContent.ProjectileType<WaterSpear>();
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
float radians = MathHelper.TwoPi / totalProjectiles;
int damage = NPC.GetProjectileDamage(type);
@@ -827,7 +827,7 @@ namespace CalamityMod.NPCs.Leviathan
if (revenge)
chargeVelocity += 2f + (death ? 6f * (1f - lifeRatio) : 4f * (1f - lifeRatio));
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeVelocity *= 1.15f;
NPC.velocity = Vector2.Normalize(player.Center - NPC.Center) * chargeVelocity;
@@ -853,7 +853,7 @@ namespace CalamityMod.NPCs.Leviathan
NPC.Calamity().canBreakPlayerDefense = true;
NPC.damage = (int)Math.Round(NPC.defDamage * 1.5);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge && NPC.ai[1] % 5f == 0f)
if (CalamityWorld.LegendaryMode && NPC.ai[1] % 5f == 0f)
{
SoundEngine.PlaySound(SoundID.Item85, NPC.Center);
Vector2 bubbleSpawnPos = new Vector2(NPC.position.X + (NPC.width / 2) + (15 * NPC.direction * NPC.scale), NPC.position.Y + 30 * NPC.scale);
@@ -923,7 +923,7 @@ namespace CalamityMod.NPCs.Leviathan
Vector2 chargeSetupLocation = Vector2.Normalize(player.Center + new Vector2(NPC.localAI[0], -distance) - NPC.Center - NPC.velocity) * 12f;
float acceleration = revenge ? 0.75f : 0.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
acceleration *= 1.15f;
NPC.SimpleFlyMovement(chargeSetupLocation, acceleration);
@@ -980,7 +980,7 @@ namespace CalamityMod.NPCs.Leviathan
if (DrawProjectileTelegraphTimer > 0)
{
Color telegraphColor = Color.Black;
switch (CalamityWorld.LegendaryMode && CalamityWorld.revenge ? LegendaryModeAttackChosen : (int)NPC.localAI[3])
switch (CalamityWorld.LegendaryMode ? LegendaryModeAttackChosen : (int)NPC.localAI[3])
{
case 0:
telegraphColor = new Color(55, 70, 240);
+1 -1
View File
@@ -46,7 +46,7 @@ namespace CalamityMod.NPCs.Leviathan
NPC.Calamity().VulnerableToCold = false;
NPC.Calamity().VulnerableToSickness = false;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.8f;
}
+1 -1
View File
@@ -55,7 +55,7 @@ namespace CalamityMod.NPCs.Leviathan
NPC.Calamity().VulnerableToElectricity = true;
NPC.Calamity().VulnerableToWater = false;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.3f;
// Scale stats in Expert and Master
+7 -7
View File
@@ -84,7 +84,7 @@ namespace CalamityMod.NPCs.Leviathan
NPC.Calamity().VulnerableToElectricity = true;
NPC.Calamity().VulnerableToWater = false;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.3f;
if (Main.zenithWorld)
@@ -313,7 +313,7 @@ namespace CalamityMod.NPCs.Leviathan
hoverAcceleration += death ? 0.15f * (1f - lifeRatio) : 0.1f * (1f - lifeRatio);
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
hoverSpeed *= 1.15f;
hoverAcceleration *= 1.15f;
@@ -413,7 +413,7 @@ namespace CalamityMod.NPCs.Leviathan
if (Main.zenithWorld)
{
type = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? ProjectileID.BouncyBoulder : ProjectileID.Boulder;
type = CalamityWorld.LegendaryMode ? ProjectileID.BouncyBoulder : ProjectileID.Boulder;
leviCenter.Y -= 5; //Shoot a bit more up since boulders are affected by gravity
damage *= 2;
}
@@ -452,7 +452,7 @@ namespace CalamityMod.NPCs.Leviathan
NPC.ai[1] += activePlayerAmt / 2;
bool spawnedAberration = false;
float aberrationSpawnDelay = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 20f : (!sirenAlive || phase4) ? 60f : 40f;
float aberrationSpawnDelay = CalamityWorld.LegendaryMode ? 20f : (!sirenAlive || phase4) ? 60f : 40f;
if (NPC.ai[1] > aberrationSpawnDelay)
{
NPC.ai[1] = 0f;
@@ -460,7 +460,7 @@ namespace CalamityMod.NPCs.Leviathan
spawnedAberration = true;
}
int spawnLimit = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 10 : (sirenAlive && !phase4) ? 1 : (death ? 2 : 3);
int spawnLimit = CalamityWorld.LegendaryMode ? 10 : (sirenAlive && !phase4) ? 1 : (death ? 2 : 3);
if (spawnedAberration && NPC.CountNPCS(ModContent.NPCType<AquaticAberration>()) < spawnLimit)
{
SoundEngine.PlaySound(soundChoice with { Pitch = soundChoice.Pitch + extrapitch }, npcCenter);
@@ -575,7 +575,7 @@ namespace CalamityMod.NPCs.Leviathan
if (revenge && (!sirenAlive || phase4))
lineupSpeed += death ? 9f * (1f - lifeRatio) : 6f * (1f - lifeRatio);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
lineupSpeed *= 1.15f;
Vector2 leviChargeCenter = npcCenter;
@@ -611,7 +611,7 @@ namespace CalamityMod.NPCs.Leviathan
chargeAcceleration += death ? 0.15f * (1f - lifeRatio) : 0.1f * (1f - lifeRatio);
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
chargeSpeed *= 1.15f;
chargeAcceleration *= 1.15f;
+2 -1
View File
@@ -1,6 +1,7 @@
using System.IO;
using CalamityMod.CalPlayer;
using CalamityMod.Items.Accessories;
using CalamityMod.World;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using ReLogic.Content;
@@ -58,7 +59,7 @@ namespace CalamityMod.NPCs.Leviathan
NPC.Calamity().VulnerableToWater = false;
NPC.Calamity().ProvidesProximityRage = false;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.8f;
}
+1 -1
View File
@@ -439,7 +439,7 @@ namespace CalamityMod.NPCs.NormalNPCs
{
if (!CalamityPlayer.areThereAnyDamnBosses && NPC.downedPlantBoss && !NPC.AnyNPCs(ModContent.NPCType<ArmoredDiggerHead>()))
{
float spawnRateDivisor = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 125f : CalamityWorld.revenge ? 425f : 500f;
float spawnRateDivisor = CalamityWorld.LegendaryMode ? 125f : CalamityWorld.revenge ? 425f : 500f;
return 1 / spawnRateDivisor;
}
}
+2 -2
View File
@@ -38,7 +38,7 @@ namespace CalamityMod.NPCs.NormalNPCs
NPC.height = 30;
if (Main.tenthAnniversaryWorld)
NPC.scale *= 0.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.1f;
NPC.defense = 5;
@@ -81,7 +81,7 @@ namespace CalamityMod.NPCs.NormalNPCs
bool charging = (attemptingToCharge && farEnoughForCharge && closeEnoughForCharge) || NPC.ai[1] > 0f;
float projectileShootGateValue = CalamityWorld.death ? 180f : 270f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
projectileShootGateValue *= 0.5f;
Vector2 lookAt = target.Center - NPC.Center;
+9 -9
View File
@@ -60,7 +60,7 @@ namespace CalamityMod.NPCs.NormalNPCs
NPC.height = 100;
if (Main.tenthAnniversaryWorld)
NPC.scale *= 0.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.8f;
NPC.defense = 10;
@@ -247,7 +247,7 @@ namespace CalamityMod.NPCs.NormalNPCs
acceleration += phase1MaxAccelerationIncrease * ((1f - lifeRatio) / (1f - phase2LifeRatio));
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
maxVelocity *= 1.15f;
acceleration *= 1.15f;
@@ -302,7 +302,7 @@ namespace CalamityMod.NPCs.NormalNPCs
if (!Main.player[NPC.target].dead)
{
NPC.ai[3] += 1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.ai[3] += 0.5f;
}
@@ -346,7 +346,7 @@ namespace CalamityMod.NPCs.NormalNPCs
chargeSpeed += 1f * enrageScale;
if (death)
chargeSpeed += phase1MaxChargeSpeedIncrease * ((1f - lifeRatio) / (1f - phase2LifeRatio));
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeSpeed += 1f;
NPC.velocity = (Main.player[NPC.target].Center - NPC.Center).SafeNormalize(Vector2.UnitY) * chargeSpeed;
@@ -380,7 +380,7 @@ namespace CalamityMod.NPCs.NormalNPCs
maxVelocity += 6f * enrageScale;
if (death)
maxVelocity += (phase1MaxChargeSpeedIncrease * 6f) * ((1f - lifeRatio) / (1f - phase2LifeRatio));
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
maxVelocity += 6f;
if (NPC.velocity.Length() < maxVelocity)
@@ -576,7 +576,7 @@ namespace CalamityMod.NPCs.NormalNPCs
if (distanceFromDestination > distanceFromTarget)
maxVelocity += MathHelper.Lerp(0f, 12f, MathHelper.Clamp((distanceFromDestination - distanceFromTarget) / 1000f, 0f, 1f));
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
maxVelocity *= 1.15f;
acceleration *= 1.15f;
@@ -675,7 +675,7 @@ namespace CalamityMod.NPCs.NormalNPCs
float chargeSpeed = 4.5f + (death ? 1.25f * ((phase2LifeRatio - lifeRatio) / phase2LifeRatio) : 0f);
chargeSpeed += 4f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeSpeed *= 1.2f;
NPC.velocity = (Main.player[NPC.target].Center - NPC.Center).SafeNormalize(Vector2.UnitY) * chargeSpeed;
@@ -714,7 +714,7 @@ namespace CalamityMod.NPCs.NormalNPCs
maxVelocity += 6f * enrageScale;
if (death)
maxVelocity += 7.5f * ((1f - lifeRatio) / (1f - phase2LifeRatio));
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
maxVelocity *= 1.2f;
// Spawn Energy Bombs along the way
@@ -782,7 +782,7 @@ namespace CalamityMod.NPCs.NormalNPCs
maxVelocity += 6f * enrageScale;
acceleration += 0.08f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
maxVelocity *= 1.15f;
acceleration *= 1.15f;
+2 -2
View File
@@ -81,7 +81,7 @@ namespace CalamityMod.NPCs.NormalNPCs
bool death = CalamityWorld.death || BossRushEvent.BossRushActive;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
if (Main.rand.NextBool(5))
NPC.reflectsProjectiles = true;
@@ -135,7 +135,7 @@ namespace CalamityMod.NPCs.NormalNPCs
Vector2 idealVelocity = NPC.SafeDirectionTo(Main.player[NPC.target].Center) * (death ? 7f : 5.5f);
float acceleration = death ? 0.14f : 0.105f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
idealVelocity *= 1.2f;
acceleration *= 1.4f;
+4 -3
View File
@@ -4,6 +4,7 @@ using CalamityMod.Items.Accessories.Vanity;
using CalamityMod.Items.Materials;
using CalamityMod.Items.Placeables.Banners;
using CalamityMod.Items.Placeables.Ores;
using CalamityMod.World;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.GameContent.Bestiary;
@@ -89,8 +90,8 @@ namespace CalamityMod.NPCs.NormalNPCs
npcPos.X += velocity.X;
npcPos.Y += velocity.Y;
int spread = Main.getGoodWorld ? 100 : 20;
for (int i = 0; i < (Main.getGoodWorld ? 10 : 2); i++)
int spread = CalamityWorld.LegendaryMode ? 100 : 20;
for (int i = 0; i < (CalamityWorld.LegendaryMode ? 10 : 2); i++)
{
velocity = Main.player[NPC.target].Center - npcPos;
targetDist = velocity.Length();
@@ -408,7 +409,7 @@ namespace CalamityMod.NPCs.NormalNPCs
{
return 0f;
}
return SpawnCondition.Sky.Chance * (Main.getGoodWorld ? 0.5f : 0.1f);
return SpawnCondition.Sky.Chance * (CalamityWorld.LegendaryMode ? 0.5f : 0.1f);
}
public override void ModifyNPCLoot(NPCLoot npcLoot)
+1 -1
View File
@@ -50,7 +50,7 @@ namespace CalamityMod.NPCs.NormalNPCs
NPC.height = 102;
if (Main.tenthAnniversaryWorld)
NPC.scale *= 0.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 1.1f;
NPC.defense = 24;
+1 -1
View File
@@ -212,7 +212,7 @@ namespace CalamityMod.NPCs.OldDuke
if (Main.rand.NextBool(8) && Main.player[closestPlayer].statLife < Main.player[closestPlayer].statLifeMax2)
Item.NewItem(NPC.GetSource_Loot(), (int)NPC.position.X, (int)NPC.position.Y, NPC.width, NPC.height, ItemID.Heart);
if (Main.netMode != NetmodeID.MultiplayerClient && Main.getGoodWorld)
if (Main.netMode != NetmodeID.MultiplayerClient && CalamityWorld.LegendaryMode)
{
int spawnX = NPC.width / 2;
int type = ModContent.ProjectileType<OldDukeGore>();
+2 -2
View File
@@ -584,8 +584,8 @@ namespace CalamityMod.NPCs.Other
public override void ModifyNPCLoot(NPCLoot npcLoot)
{
double pisquaredover6 = Math.Pow(MathHelper.Pi, 2) / 6;
npcLoot.AddIf(() => CalamityWorld.LegendaryMode && CalamityWorld.revenge, ModContent.ItemType<SuspiciousLookingNOU>()); // guaranteed in legendarev mode
npcLoot.AddIf(() => !(CalamityWorld.LegendaryMode && CalamityWorld.revenge), ModContent.ItemType<SuspiciousLookingNOU>(), 27); // otherwise 1 in 27
npcLoot.AddIf(() => CalamityWorld.LegendaryMode, ModContent.ItemType<SuspiciousLookingNOU>()); // guaranteed in legendarev mode
npcLoot.AddIf(() => !CalamityWorld.LegendaryMode, ModContent.ItemType<SuspiciousLookingNOU>(), 27); // otherwise 1 in 27
npcLoot.Add(ModContent.ItemType<DeliciousMeat>(), 1, 22, (int)(pisquaredover6 * 100));
}
}
+7 -7
View File
@@ -252,12 +252,12 @@ namespace CalamityMod.NPCs.Perforator
if (NPC.ai[3] == 0f && NPC.life > 0)
NPC.ai[3] = NPC.lifeMax;
bool canSpawnWorms = !small || !medium || !large || Main.getGoodWorld;
bool canSpawnWorms = !small || !medium || !large || CalamityWorld.LegendaryMode;
if (NPC.life > 0 && canSpawnWorms)
{
if (Main.netMode != NetmodeID.MultiplayerClient)
{
int wormSpawnGateValue = (int)(NPC.lifeMax * (Main.getGoodWorld ? 0.15 : 0.25));
int wormSpawnGateValue = (int)(NPC.lifeMax * (CalamityWorld.LegendaryMode ? 0.15 : 0.25));
if ((NPC.life + wormSpawnGateValue) < NPC.ai[3])
{
NPC.ai[3] = NPC.life;
@@ -277,7 +277,7 @@ namespace CalamityMod.NPCs.Perforator
wormType = ModContent.NPCType<PerforatorHeadLarge>();
}
if (Main.getGoodWorld && lifeRatio < 0.5f)
if (CalamityWorld.LegendaryMode && lifeRatio < 0.5f)
{
if (lifeRatio > 0.35f)
NPC.NewNPC(NPC.GetSource_FromAI(), (int)NPC.Center.X + Main.rand.Next(-25, 26), (int)NPC.Center.Y + Main.rand.Next(-25, 26), ModContent.NPCType<PerforatorHeadLarge>(), 1);
@@ -329,7 +329,7 @@ namespace CalamityMod.NPCs.Perforator
// Emit ichor blobs
if (phase2)
{
if (wormsAlive == 0 || large || bossRush || floatAboveToFireBlobs || (CalamityWorld.LegendaryMode && CalamityWorld.revenge))
if (wormsAlive == 0 || large || bossRush || floatAboveToFireBlobs || CalamityWorld.LegendaryMode)
{
NPC.ai[2] += 1f;
if (NPC.ai[2] >= blobPhaseGateValue)
@@ -360,7 +360,7 @@ namespace CalamityMod.NPCs.Perforator
bool ichorBlobBigWormPhase = wormsAlive > 0 && large;
int numBlobs = expertMode ? (ichorBlobBigWormPhase ? 4 : 6) : (ichorBlobBigWormPhase ? 2 : 4);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
numBlobs *= 2;
int type = ModContent.ProjectileType<IchorBlob>();
@@ -373,7 +373,7 @@ namespace CalamityMod.NPCs.Perforator
blobVelocity.Normalize();
blobVelocity *= Main.rand.Next(400, 801) * (bossRush ? 0.02f : 0.01f);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
blobVelocity *= Main.rand.NextFloat() + 1f;
float blobVelocityYAdd = Math.Abs(blobVelocity.Y) * 0.25f;
@@ -480,7 +480,7 @@ namespace CalamityMod.NPCs.Perforator
int numProj = death ? 16 : revenge ? 14 : expertMode ? 12 : 10;
if (phase3)
numProj = death ? 12 : revenge ? 10 : expertMode ? 8 : 6;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
numProj *= 2;
int spread = 75;
@@ -176,7 +176,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
float challengeAmt = (1f - lifeRatio) * 100f;
float nukeBarrageChallengeAmt = (0.5f - lifeRatio) * 200f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
challengeAmt *= 1.5f;
nukeBarrageChallengeAmt *= 1.5f;
@@ -209,7 +209,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
// Missile countdown
if (halfLife && MissileCountdown == 0)
MissileCountdown = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 300 : 600;
MissileCountdown = CalamityWorld.LegendaryMode ? 300 : 600;
if (MissileCountdown > 1)
MissileCountdown--;
@@ -250,7 +250,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
if (enrageScale > 1.5f)
enrageScale = 1.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
enrageScale += 0.5f;
if (bossRush)
@@ -545,7 +545,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
NPC.velocity *= 1.01f;
// Spawn honey in legendary rev+
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge && calamityGlobalNPC.newAI[0] % 6f == 0f)
if (CalamityWorld.LegendaryMode && calamityGlobalNPC.newAI[0] % 6f == 0f)
{
if (Main.netMode != NetmodeID.MultiplayerClient)
{
@@ -803,7 +803,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
NPC.direction = playerLocation < 0 ? 1 : -1;
NPC.spriteDirection = NPC.direction;
if (NPC.ai[2] > ((CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 3f : 5f))
if (NPC.ai[2] > (CalamityWorld.LegendaryMode ? 3f : 5f))
{
NPC.ai[0] = -1f;
NPC.ai[1] = 2f;
+4 -4
View File
@@ -80,7 +80,7 @@ namespace CalamityMod.NPCs.Polterghast
}
float chargePhaseGateValue = 480f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargePhaseGateValue *= 0.5f;
bool chargePhase = Main.npc[CalamityGlobalNPC.ghostBoss].Calamity().newAI[0] >= chargePhaseGateValue - 60f;
@@ -98,11 +98,11 @@ namespace CalamityMod.NPCs.Polterghast
direction *= 0.5f;
NPC.rotation = direction.ToRotation();
if (!chargePhase || (CalamityWorld.LegendaryMode && CalamityWorld.revenge))
if (!chargePhase || CalamityWorld.LegendaryMode)
{
NPC.ai[2] += 1f;
float shootMineGateValue = 150f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
shootMineGateValue *= 0.5f;
if (NPC.ai[2] >= shootMineGateValue)
@@ -130,7 +130,7 @@ namespace CalamityMod.NPCs.Polterghast
if (SPEEN < 0f)
SPEEN = 0f;
NPC.ai[1] += (Main.getGoodWorld ? 1.5f : 0.5f) + SPEEN;
NPC.ai[1] += (CalamityWorld.LegendaryMode ? 1.5f : 0.5f) + SPEEN;
}
public override Color? GetAlpha(Color drawColor) => new Color(200, 200, 200, 0);
+3 -3
View File
@@ -44,7 +44,7 @@ namespace CalamityMod.NPCs.Polterghast
NPC.defense = 45;
NPC.DR_NERD(0.1f);
NPC.LifeMaxNERB(62500, 75000, 60000);
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.lifeMax *= 4;
NPC.knockBackResist = 0f;
@@ -121,7 +121,7 @@ namespace CalamityMod.NPCs.Polterghast
Vector2 vector = NPC.Center;
float chargePhaseGateValue = 480f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargePhaseGateValue *= 0.5f;
float colorChangeTime = 180f;
@@ -440,7 +440,7 @@ namespace CalamityMod.NPCs.Polterghast
spriteEffects = SpriteEffects.FlipHorizontally;
float chargePhaseGateValue = 480f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargePhaseGateValue *= 0.5f;
float timeToReachFullColor = 120f;
+2 -2
View File
@@ -222,7 +222,7 @@ namespace CalamityMod.NPCs.Polterghast
// Velocity and acceleration
calamityGlobalNPC.newAI[0] += 1f;
float chargePhaseGateValue = 480f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargePhaseGateValue *= 0.5f;
bool chargePhase = calamityGlobalNPC.newAI[0] >= chargePhaseGateValue;
@@ -1120,7 +1120,7 @@ namespace CalamityMod.NPCs.Polterghast
}
float chargePhaseGateValue = 480f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargePhaseGateValue *= 0.5f;
float timeToReachFullColor = 120f;
+4 -4
View File
@@ -94,7 +94,7 @@ namespace CalamityMod.NPCs.Polterghast
}
float chargePhaseGateValue = 480f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargePhaseGateValue *= 0.5f;
bool chargePhase = Main.npc[CalamityGlobalNPC.ghostBoss].Calamity().newAI[0] >= chargePhaseGateValue - 60f;
@@ -150,7 +150,7 @@ namespace CalamityMod.NPCs.Polterghast
NPC.ai[2] += 1f;
if (NPC.ai[3] == 0f)
{
if (NPC.ai[2] > ((CalamityWorld.LegendaryMode && revenge) ? 12f : 120f))
if (NPC.ai[2] > ((CalamityWorld.LegendaryMode) ? 12f : 120f))
{
NPC.ai[2] = 0f;
NPC.ai[3] = 1f;
@@ -183,7 +183,7 @@ namespace CalamityMod.NPCs.Polterghast
private void Movement(bool phase2, bool expertMode, bool revenge, bool death, bool speedBoost, bool despawnBoost, float lifeRatio, float tileEnrageMult, Player player)
{
float chargePhaseGateValue = 480f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargePhaseGateValue *= 0.5f;
float colorChangeTime = 180f;
@@ -325,7 +325,7 @@ namespace CalamityMod.NPCs.Polterghast
Color lightRed = new Color(255, 100, 100, 255);
float chargePhaseGateValue = 480f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargePhaseGateValue *= 0.5f;
float timeToReachFullColor = 120f;
+2 -2
View File
@@ -329,7 +329,7 @@ namespace CalamityMod.NPCs.PrimordialWyrm
float ancientDoomGateValue = death ? 95f : revenge ? 100f : expertMode ? 105f : 120f;
float lightningChargePhaseGateValue = death ? 120f : revenge ? 135f : expertMode ? 150f : 180f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
lightningRainDuration *= 0.5f;
eidolonWyrmPhaseDuration *= 0.25f;
@@ -448,7 +448,7 @@ namespace CalamityMod.NPCs.PrimordialWyrm
// Velocity and turn speed values
float velocityScale = death ? 1.8f : revenge ? 1.5f : expertMode ? 1.2f : 0f;
float baseVelocity = (targetDownDeep ? 10f : 15f) + (targetDownDeep ? velocityScale : velocityScale * 1.5f);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
baseVelocity *= 1.15f;
float turnSpeed = baseVelocity * 0.015f;
@@ -368,9 +368,9 @@ namespace CalamityMod.NPCs.ProfanedGuardians
// Charge variables
float chargeVelocityMult = 0.25f;
float maxChargeVelocity = bossRush ? 32f : death ? 28f : revenge ? 26f : expertMode ? 24f : 20f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
maxChargeVelocity *= 1.15f;
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
maxChargeVelocity *= 2f;
float inertia = bossRush ? 40f : death ? 45f : revenge ? 47f : expertMode ? 50f : 55f;
@@ -378,7 +378,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
inertia *= 0.8f;
if (!phase1)
inertia *= 0.75f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.8f;
bool speedUp = Vector2.Distance(NPC.Center, player.Center) > 960f;
@@ -457,7 +457,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
calamityGlobalNPC.newAI[0] = -NPC.direction;
float velocity = bossRush ? 18f : death ? 16f : revenge ? 15f : expertMode ? 14f : 12f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
velocity *= 1.25f;
if (healerAlive)
velocity *= 0.8f;
@@ -792,7 +792,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
bool targetRanAwayAndWillNowBeFucked = NPC.ai[2] == 1f;
bool boostVelocityToCatchUp = NPC.ai[1] == 0f || targetRanAwayAndWillNowBeFucked;
float velocity = bossRush ? 18f : death ? 16f : revenge ? 15f : expertMode ? 14f : 12f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
velocity *= 1.25f;
if (boostVelocityToCatchUp)
velocity *= 2f;
@@ -849,7 +849,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
else if (NPC.ai[1] % spearShootDivisor == 0f)
{
float spearVelocity = bossRush ? 18f : death ? 16f : revenge ? 15f : expertMode ? 14f : 12f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
spearVelocity *= 1.25f;
if (boostVelocityToCatchUp)
spearVelocity *= 1.5f;
@@ -906,7 +906,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
float velocity = bossRush ? 4.5f : death ? 4f : revenge ? 3.75f : expertMode ? 3.5f : 3f;
if (NPC.ai[1] < laserGateValue)
velocity *= 6f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
velocity *= 1.25f;
calamityGlobalNPC.newAI[0] = -NPC.direction;
@@ -924,7 +924,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
// Limit Y velocity while firing laser
if (NPC.ai[1] >= laserGateValue)
{
float speedCap = Main.getGoodWorld ? 4f : 2f;
float speedCap = CalamityWorld.LegendaryMode ? 4f : 2f;
if (NPC.velocity.Y > speedCap)
NPC.velocity.Y = speedCap;
if (NPC.velocity.Y < -speedCap)
@@ -984,7 +984,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
if (revenge)
Projectile.NewProjectile(NPC.GetSource_FromAI(), shootFrom, -laserVelocity, type, damage, 0f, Main.myPlayer, -beamDirection * MathHelper.TwoPi / rotation, NPC.whoAmI);
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
{
rotation *= 0.33f;
laserVelocity = laserVelocity.RotatedBy(-(double)beamDirection * MathHelper.TwoPi / 2f);
@@ -262,7 +262,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
// Charge variables
float chargeVelocityMult = 0.25f;
float maxChargeVelocity = bossRush ? 25f : death ? 22f : revenge ? 20.5f : expertMode ? 19f : 16f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
maxChargeVelocity *= 1.15f;
// Whether the commander is calling all guardians together for the laser attack
@@ -382,7 +382,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
}
float moveVelocity = bossRush ? 24f : death ? 22f : revenge ? 21f : expertMode ? 20f : 18f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
moveVelocity *= 1.25f;
if (healerAlive)
moveVelocity *= 0.8f;
@@ -457,7 +457,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
if (distanceFromDestination.Length() > 40f)
{
float inertia = (commanderUsingLaser || commanderGoingLowOrHighInPhase1) ? 10f : 15f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.8f;
NPC.velocity = (NPC.velocity * (inertia - 1) + desiredVelocity) / inertia;
@@ -489,7 +489,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
if (NPC.ai[1] >= -throwRocksGateValue)
{
NPC.velocity *= 0.8f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.velocity *= 0.5f;
}
@@ -555,7 +555,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
if (distanceFromDestination.Length() > 40f)
{
float inertia = commanderGoingLowOrHighInPhase2 ? 8f : 15f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.8f;
NPC.velocity = (NPC.velocity * (inertia - 1) + desiredVelocity) / inertia;
@@ -217,7 +217,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
bool useCrystalShards = AIState == (float)Phase.CrystalShards;
float velocity = useCrystalShards ? (bossRush ? 18f : death ? 16f : revenge ? 15f : expertMode ? 14f : 12f) : (Main.npc[CalamityGlobalNPC.doughnutBoss].velocity.Length() + 5f);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
velocity *= 1.25f;
float idealDistanceFromDestination = useCrystalShards ? 80f : 160f;
@@ -251,7 +251,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
if (distanceFromDestination.Length() > 40f)
{
float inertia = 10f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.8f;
NPC.velocity = (NPC.velocity * (inertia - 1) + desiredVelocity) / inertia;
@@ -407,7 +407,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
float inertia = bossRush ? 28f : death ? 32f : revenge ? 34f : expertMode ? 36f : 40f;
if (lifeRatio < 0.5f)
inertia *= 0.8f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.8f;
NPC.velocity = (NPC.velocity * (inertia - 1) + desiredVelocity) / inertia;
+1 -1
View File
@@ -209,7 +209,7 @@ namespace CalamityMod.NPCs.ProfanedGuardians
// Start off slow
Vector2 finalVelocity = NPC.SafeDirectionTo(player.Center, -Vector2.UnitY) * chargeSpeed;
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
finalVelocity *= Main.rand.NextFloat(1f, 1.7f);
NPC.Calamity().newAI[2] = finalVelocity.X;
+7 -7
View File
@@ -261,7 +261,7 @@ namespace CalamityMod.NPCs.Providence
NPC.Calamity().VulnerableToSickness = false;
NPC.Calamity().VulnerableToWater = true;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.25f;
// Scale HP in Master
@@ -884,7 +884,7 @@ namespace CalamityMod.NPCs.Providence
acceleration = 2f;
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.2f;
acceleration *= 1.2f;
@@ -900,12 +900,12 @@ namespace CalamityMod.NPCs.Providence
float moveUpThreshold = player.position.Y - (NPC.position.Y + NPC.height);
if (moveUpThreshold < (laserPhaseSlow ? 150f : 200f)) // 150
NPC.velocity.Y -= Main.getGoodWorld ? 0.4f : 0.2f;
NPC.velocity.Y -= CalamityWorld.LegendaryMode ? 0.4f : 0.2f;
if (moveUpThreshold > (laserPhaseSlow ? 200f : 250f)) // 200
NPC.velocity.Y += Main.getGoodWorld ? 0.4f : 0.2f;
NPC.velocity.Y += CalamityWorld.LegendaryMode ? 0.4f : 0.2f;
float speedCap = laserPhaseSlow ? 2f : 6f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
speedCap *= 1.5f;
if (NPC.velocity.Y > speedCap)
@@ -1567,7 +1567,7 @@ namespace CalamityMod.NPCs.Providence
{
Projectile.NewProjectile(NPC.GetSource_FromAI(), fireFrom, vector2, projectileType, holySpearDamage, 0f, Main.myPlayer);
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
Projectile.NewProjectile(NPC.GetSource_FromAI(), fireFrom, -vector2, projectileType, holySpearDamage, 0f, Main.myPlayer);
}
}
@@ -1594,7 +1594,7 @@ namespace CalamityMod.NPCs.Providence
{
Projectile.NewProjectile(NPC.GetSource_FromAI(), fireFrom, velocity2, projectileType, holySpearDamage, 0f, Main.myPlayer, 1f, 0f);
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
Projectile.NewProjectile(NPC.GetSource_FromAI(), fireFrom, -velocity2, projectileType, holySpearDamage, 0f, Main.myPlayer, 1f, 0f);
}
}
+4 -4
View File
@@ -497,7 +497,7 @@ namespace CalamityMod.NPCs.Ravager
NPC.ai[1] += 1f;
}
float jumpGateValue = Main.getGoodWorld ? 0f : 180f;
float jumpGateValue = CalamityWorld.LegendaryMode ? 0f : 180f;
if (NPC.ai[1] >= jumpGateValue)
{
NPC.ai[1] = -20f;
@@ -594,7 +594,7 @@ namespace CalamityMod.NPCs.Ravager
bool anyRockPillars = NPC.AnyNPCs(ModContent.NPCType<RockPillar>());
bool anyFlamePillars = NPC.AnyNPCs(ModContent.NPCType<FlamePillar>());
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
{
if (!expertMode || anyRockPillars || anyFlamePillars)
SoundEngine.PlaySound(PillarSound, NPC.Center);
@@ -636,12 +636,12 @@ namespace CalamityMod.NPCs.Ravager
{
SoundEngine.PlaySound(PillarSound, NPC.Center);
}
if (!anyRockPillars || Main.getGoodWorld)
if (!anyRockPillars || CalamityWorld.LegendaryMode)
{
NPC.NewNPC(NPC.GetSource_FromAI(), (int)(player.Center.X - spawnDistance * 1.25f), (int)player.Center.Y - 100, ModContent.NPCType<RockPillar>());
NPC.NewNPC(NPC.GetSource_FromAI(), (int)(player.Center.X + spawnDistance * 1.25f), (int)player.Center.Y - 100, ModContent.NPCType<RockPillar>());
}
else if (!anyFlamePillars || Main.getGoodWorld)
else if (!anyFlamePillars || CalamityWorld.LegendaryMode)
{
float distanceMultiplier = finalPhase ? 2.5f : 2f;
NPC.NewNPC(NPC.GetSource_FromAI(), (int)player.Center.X - (int)(spawnDistance * distanceMultiplier), (int)player.Center.Y - 100, ModContent.NPCType<FlamePillar>());
+9 -9
View File
@@ -138,12 +138,12 @@ namespace CalamityMod.NPCs.Signus
double lifeRatio = NPC.life / (double)NPC.lifeMax;
lifeToAlpha = (int)((Main.getGoodWorld ? 200D : 100D) * (1D - lifeRatio));
lifeToAlpha = (int)((CalamityWorld.LegendaryMode ? 200D : 100D) * (1D - lifeRatio));
int maxCharges = death ? 1 : revenge ? 2 : expertMode ? 3 : 4;
int maxTeleports = (death && lifeRatio < 0.9) ? 1 : revenge ? 2 : expertMode ? 3 : 4;
float inertia = bossRush ? 9f : death ? 10f : revenge ? 11f : expertMode ? 12f : 14f;
float chargeVelocity = bossRush ? 16f : death ? 14f : revenge ? 13f : expertMode ? 12f : 10f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
inertia *= 0.5f;
chargeVelocity *= 1.15f;
@@ -197,7 +197,7 @@ namespace CalamityMod.NPCs.Signus
else if (NPC.timeLeft < 1800)
NPC.timeLeft = 1800;
if (lifeToAlpha < (Main.getGoodWorld ? 100 : 50) && NPC.ai[0] != 1f)
if (lifeToAlpha < (CalamityWorld.LegendaryMode ? 100 : 50) && NPC.ai[0] != 1f)
{
for (int i = 0; i < 2; i++)
{
@@ -263,7 +263,7 @@ namespace CalamityMod.NPCs.Signus
playerYDist *= playerDistance;
float inertia2 = 50f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia2 *= 0.5f;
NPC.velocity.X = (NPC.velocity.X * inertia2 + playerXDist) / (inertia2 + 1f);
@@ -298,7 +298,7 @@ namespace CalamityMod.NPCs.Signus
if (expertMode)
NPC.localAI[1] += death ? 3f * (float)(1D - lifeRatio) : 2f * (float)(1D - lifeRatio);
if (NPC.localAI[1] >= (Main.getGoodWorld ? 0f : 120f))
if (NPC.localAI[1] >= (CalamityWorld.LegendaryMode ? 0f : 120f))
{
NPC.localAI[1] = 0f;
@@ -573,7 +573,7 @@ namespace CalamityMod.NPCs.Signus
{
if (Main.netMode != NetmodeID.MultiplayerClient)
{
int totalLamps = (Main.getGoodWorld && !Main.zenithWorld) ? 10 : 5;
int totalLamps = (CalamityWorld.LegendaryMode && !Main.zenithWorld) ? 10 : 5;
if (NPC.CountNPCS(ModContent.NPCType<CosmicLantern>()) < totalLamps)
{
bool buffed = false;
@@ -712,10 +712,10 @@ namespace CalamityMod.NPCs.Signus
if ((phase2 || buffed) && NPC.ai[2] % 3f == 0f)
{
SoundEngine.PlaySound(SoundID.Item73, NPC.Center);
int type = (CalamityWorld.LegendaryMode && revenge) ? ModContent.ProjectileType<PeanutRocket>() : ModContent.ProjectileType<EssenceDust>();
int damage = (CalamityWorld.LegendaryMode && revenge) ? 60 : NPC.GetProjectileDamage(type);
int type = (CalamityWorld.LegendaryMode) ? ModContent.ProjectileType<PeanutRocket>() : ModContent.ProjectileType<EssenceDust>();
int damage = (CalamityWorld.LegendaryMode) ? 60 : NPC.GetProjectileDamage(type);
Vector2 velocity = Main.zenithWorld ? new Vector2(Main.rand.Next(-10, 11), Main.rand.Next(-10, 11)) : Vector2.Zero;
if (Main.getGoodWorld && !Main.zenithWorld)
if (CalamityWorld.LegendaryMode && !Main.zenithWorld)
{
velocity = new Vector2(Main.rand.Next(-5, 6), Main.rand.Next(-5, 6));
}
+2 -2
View File
@@ -26,11 +26,11 @@ namespace CalamityMod.NPCs.SlimeGod
NPC.GetNPCDamage();
NPC.width = 40;
NPC.height = 30;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.scale = 2f;
NPC.defense = 6;
NPC.lifeMax = BossRushEvent.BossRushActive ? 10000 : (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 360 : 180;
NPC.lifeMax = BossRushEvent.BossRushActive ? 10000 : CalamityWorld.LegendaryMode ? 360 : 180;
NPC.knockBackResist = 0.7f;
AnimationType = NPCID.Slimer;
NPC.lavaImmune = false;
+2 -2
View File
@@ -26,11 +26,11 @@ namespace CalamityMod.NPCs.SlimeGod
NPC.GetNPCDamage();
NPC.width = 40;
NPC.height = 30;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.scale = 2f;
NPC.defense = 4;
NPC.lifeMax = BossRushEvent.BossRushActive ? 5000 : (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 180 : 90;
NPC.lifeMax = BossRushEvent.BossRushActive ? 5000 : CalamityWorld.LegendaryMode ? 180 : 90;
NPC.knockBackResist = 0.9f;
AnimationType = NPCID.CorruptSlime;
NPC.lavaImmune = false;
+2 -2
View File
@@ -25,11 +25,11 @@ namespace CalamityMod.NPCs.SlimeGod
NPC.GetNPCDamage();
NPC.width = 40;
NPC.height = 30;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.scale = 2f;
NPC.defense = 4;
NPC.lifeMax = BossRushEvent.BossRushActive ? 10000 : (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 220 : 110;
NPC.lifeMax = BossRushEvent.BossRushActive ? 10000 : CalamityWorld.LegendaryMode ? 220 : 110;
NPC.knockBackResist = 0.8f;
AnimationType = NPCID.CorruptSlime;
NPC.lavaImmune = false;
+2 -2
View File
@@ -32,11 +32,11 @@ namespace CalamityMod.NPCs.SlimeGod
NPC.GetNPCDamage();
NPC.width = 40;
NPC.height = 30;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.scale = 2f;
NPC.defense = 6;
NPC.lifeMax = BossRushEvent.BossRushActive ? 12000 : (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 260 : 130;
NPC.lifeMax = BossRushEvent.BossRushActive ? 12000 : CalamityWorld.LegendaryMode ? 260 : 130;
NPC.knockBackResist = 0.7f;
NPC.lavaImmune = false;
NPC.noGravity = false;
+2 -2
View File
@@ -112,7 +112,7 @@ namespace CalamityMod.NPCs.SlimeGod
addedStretch = -landingRecoil;
// Used for teleporting
float scale = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 0.6f : Main.getGoodWorld ? 0.8f : 1f;
float scale = CalamityWorld.LegendaryMode ? 0.6f : CalamityWorld.LegendaryMode ? 0.8f : 1f;
// How fast the slime slams down
float slamVelocity = bossRush ? 20f : death ? 16f : revenge ? 15f : expertMode ? 14f : 12f;
@@ -155,7 +155,7 @@ namespace CalamityMod.NPCs.SlimeGod
if (lifeRatio <= 0.5f && Main.netMode != NetmodeID.MultiplayerClient && expertMode)
{
// Spread of random globs in meme mode
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
int type = ModContent.ProjectileType<UnstableCrimulanGlob>();
for (int i = 0; i < 30; i++)
+6 -6
View File
@@ -101,7 +101,7 @@ namespace CalamityMod.NPCs.SlimeGod
setDamage += 22;
}
float scale = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 0.6f : Main.getGoodWorld ? 0.8f : 1f;
float scale = CalamityWorld.LegendaryMode ? 0.6f : CalamityWorld.LegendaryMode ? 0.8f : 1f;
NPC.aiAction = 0;
// Get a target
@@ -131,7 +131,7 @@ namespace CalamityMod.NPCs.SlimeGod
if (lifeRatio <= 0.5f && Main.netMode != NetmodeID.MultiplayerClient && expertMode)
{
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
{
int type = ModContent.ProjectileType<UnstableEbonianGlob>();
for (int i = 0; i < 30; i++)
@@ -319,7 +319,7 @@ namespace CalamityMod.NPCs.SlimeGod
{
if (Main.netMode != NetmodeID.MultiplayerClient)
{
int numProjectiles = Main.getGoodWorld ? 12 : death ? 6 : 4;
int numProjectiles = CalamityWorld.LegendaryMode ? 12 : death ? 6 : 4;
float projectileVelocity = death ? 8f : 6f;
int type = ModContent.ProjectileType<UnstableEbonianGlob>();
int damage = NPC.GetProjectileDamage(type);
@@ -499,15 +499,15 @@ namespace CalamityMod.NPCs.SlimeGod
// Charge variables
float chargeVelocityMult = 0.1f;
float maxChargeVelocity = (bossRush || enraged) ? 12f : death ? 10f : revenge ? 9f : expertMode ? 8f : 6f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
maxChargeVelocity *= 1.15f;
if (CalamityWorld.LegendaryMode && revenge)
if (CalamityWorld.LegendaryMode)
maxChargeVelocity *= 2f;
float inertia = (bossRush || enraged) ? 100f : death ? 110f : revenge ? 114f : expertMode ? 120f : 130f;
if (lifeRatio < 0.75f)
inertia *= 0.8f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
inertia *= 0.8f;
// Start charge
+4 -4
View File
@@ -101,7 +101,7 @@ namespace CalamityMod.NPCs.SlimeGod
NPC.npcSlots = 10f;
NPC.width = 96;
NPC.height = 98;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
NPC.scale = 2f;
NPC.defense = 6;
@@ -548,7 +548,7 @@ namespace CalamityMod.NPCs.SlimeGod
flySpeed *= 1.1f;
if (bossRush)
flySpeed *= 1.2f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
flySpeed *= 1.3f;
Vector2 flyDestination = aggressionLevel >= (int)AggressionLevel.ChargeAtPlayer ? player.Center : player.Center - Vector2.UnitY * 320f;
@@ -590,9 +590,9 @@ namespace CalamityMod.NPCs.SlimeGod
float maxInertiaDistance = 600f;
float totalInertiaAdjustmentDistance = maxInertiaDistance - minInertiaDistance;
float distanceFromInertiaAdjustmentCutoff = distanceFromFlyDestination - minInertiaDistance;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
maxInertia *= 0.8f;
if (CalamityWorld.LegendaryMode && CalamityWorld.revenge)
if (CalamityWorld.LegendaryMode)
maxInertia *= Main.rand.NextFloat(0.2f, 1f);
float inertia = distanceFromFlyDestination >= maxInertiaDistance ? maxInertia :
+1 -1
View File
@@ -127,7 +127,7 @@ namespace CalamityMod.NPCs.SlimeGod
addedStretch = -landingRecoil;
// Used for teleporting
float scale = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 0.6f : Main.getGoodWorld ? 0.8f : 1f;
float scale = CalamityWorld.LegendaryMode ? 0.6f : CalamityWorld.LegendaryMode ? 0.8f : 1f;
// How fast the slime slams down
float slamVelocity = bossRush ? 22.25f : death ? 18.25f : revenge ? 16.5f : expertMode ? 15.5f : 13.5f;
+1 -1
View File
@@ -123,7 +123,7 @@ namespace CalamityMod.NPCs.SlimeGod
addedStretch = -landingRecoil;
float scale = (CalamityWorld.LegendaryMode && CalamityWorld.revenge) ? 0.6f : Main.getGoodWorld ? 0.8f : 1f;
float scale = CalamityWorld.LegendaryMode ? 0.6f : CalamityWorld.LegendaryMode ? 0.8f : 1f;
// How fast the slime slams down
float slamVelocity = bossRush ? 20f : death ? 16f : revenge ? 15f : expertMode ? 14f : 12f;
+1 -1
View File
@@ -69,7 +69,7 @@ namespace CalamityMod.NPCs.StormWeaver
else if (Main.expertMode)
NPC.scale *= 1.1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.7f;
NPC.Calamity().VulnerableToElectricity = false;
+5 -5
View File
@@ -121,7 +121,7 @@ namespace CalamityMod.NPCs.StormWeaver
else if (Main.expertMode)
NPC.scale *= 1.1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.7f;
NPC.Calamity().VulnerableToElectricity = false;
@@ -193,7 +193,7 @@ namespace CalamityMod.NPCs.StormWeaver
bool phase4 = lifeRatio < 0.3f;
// Update armored settings to naked settings
if (phase2 && (!CalamityWorld.LegendaryMode || !revenge))
if (phase2 && !CalamityWorld.LegendaryMode)
{
// Spawn armor gore, roar and set other crucial variables
if (!NPC.chaseable)
@@ -280,7 +280,7 @@ namespace CalamityMod.NPCs.StormWeaver
}
// Used for body and tail projectile firing timings in phase 1
if (!phase2 || (CalamityWorld.LegendaryMode && revenge))
if (!phase2 || CalamityWorld.LegendaryMode)
NPC.localAI[0] += 1f;
}
@@ -621,7 +621,7 @@ namespace CalamityMod.NPCs.StormWeaver
}
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.4f;
acceleration *= 1.4f;
@@ -847,7 +847,7 @@ namespace CalamityMod.NPCs.StormWeaver
float lifeRatio = NPC.life / (float)NPC.lifeMax;
bool phase2 = lifeRatio < 0.8f && (!CalamityWorld.LegendaryMode || !revenge);
bool phase2 = lifeRatio < 0.8f && !CalamityWorld.LegendaryMode;
bool phase3 = lifeRatio < 0.55f;
// Gate value that decides when Storm Weaver will charge
+1 -1
View File
@@ -68,7 +68,7 @@ namespace CalamityMod.NPCs.StormWeaver
else if (Main.expertMode)
NPC.scale *= 1.1f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.scale *= 0.7f;
NPC.Calamity().VulnerableToElectricity = false;
+1 -1
View File
@@ -210,7 +210,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
GeneralParticleHandler.SpawnParticle(spark2);
}
float distanceFromSCal = Main.getGoodWorld ? 300f : 225f;
float distanceFromSCal = CalamityWorld.LegendaryMode ? 300f : 225f;
NPC.position = SCal.Center - MathHelper.ToRadians(RotationalDegreeOffset).ToRotationVector2() * distanceFromSCal - NPC.Size * 0.5f;
NPC.velocity = Vector2.Zero;
RotationalDegreeOffset += 0.5f;
+12 -12
View File
@@ -454,7 +454,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
bool teleport = false;
// permafrost and zenith scal are mutually exclusive unless it's legendary
bool zenithAI = Main.zenithWorld && (!permafrost || (CalamityWorld.LegendaryMode && revenge && permafrost));
bool zenithAI = Main.zenithWorld && (!permafrost || (CalamityWorld.LegendaryMode && permafrost));
// Percent life remaining
float lifeRatio = NPC.life / (float)NPC.lifeMax;
@@ -489,7 +489,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
int bodyHeight = 42;
int baseBulletHellProjectileGateValue = revenge ? 8 : expertMode ? 9 : 10;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
baseBulletHellProjectileGateValue -= 2;
Vector2 vectorCenter = NPC.Center;
@@ -1970,9 +1970,9 @@ namespace CalamityMod.NPCs.SupremeCalamitas
else
{
SoundEngine.PlaySound(SoundID.Item74, NPC.Center);
int totalSeekers = Main.getGoodWorld ? 20 : 10;
int totalSeekers = CalamityWorld.LegendaryMode ? 20 : 10;
int degreesBetweenEachSeeker = 360 / totalSeekers;
int distanceFromSCal = Main.getGoodWorld ? 300 : 225;
int distanceFromSCal = CalamityWorld.LegendaryMode ? 300 : 225;
for (int i = 0; i < totalSeekers; i++)
{
int FireEye = NPC.NewNPC(NPC.GetSource_FromAI(), (int)(vectorCenter.X + (Math.Sin(i * degreesBetweenEachSeeker) * distanceFromSCal)), (int)(vectorCenter.Y + (Math.Cos(i * degreesBetweenEachSeeker) * distanceFromSCal)), ModContent.NPCType<SoulSeekerSupreme>(), NPC.whoAmI, 0, 0, 0, -1);
@@ -2182,7 +2182,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
float velocity = 12f;
float acceleration = 0.12f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.15f;
acceleration *= 1.15f;
@@ -2296,7 +2296,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
float chargeVelocity = (wormAlive ? 26f : 30f) + (1f - lifeRatio) * 8f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeVelocity *= 1.15f;
if (!canDespawn)
@@ -2398,7 +2398,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
float velocity = 32f;
float acceleration = 1.2f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.15f;
acceleration *= 1.15f;
@@ -2477,7 +2477,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
float velocity = 32f;
float acceleration = 1.2f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.15f;
acceleration *= 1.15f;
@@ -2748,7 +2748,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
float velocity = 12f;
float acceleration = 0.12f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.15f;
acceleration *= 1.15f;
@@ -2857,7 +2857,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
float chargeVelocity = (wormAlive ? 26f : 30f) + (1f - lifeRatio) * 8f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeVelocity *= 1.15f;
if (!canDespawn)
@@ -2931,7 +2931,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
float velocity = 32f;
float acceleration = 1.2f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.15f;
acceleration *= 1.15f;
@@ -3015,7 +3015,7 @@ namespace CalamityMod.NPCs.SupremeCalamitas
float velocity = 32f;
float acceleration = 1.2f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
velocity *= 1.15f;
acceleration *= 1.15f;
@@ -107,7 +107,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
// Phase 2
if (npc.ai[0] < 0f)
{
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
NPC.brainOfGravity = npc.whoAmI;
// Spawn gore
@@ -237,7 +237,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
float velocityScale = death ? 6f : 4.5f;
float velocityBoost = velocityScale * (1f - lifeRatio);
float nonChargeSpeed = (death ? 24f : 18f) + velocityBoost + 3f * enrageScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
nonChargeSpeed *= 1.15f;
float minInertia = death ? 50f : 75f;
@@ -291,7 +291,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
// Velocity
npc.velocity = (Main.player[npc.target].Center + (death ? Main.player[npc.target].velocity * 20f * enrageScale : Vector2.Zero) - npc.Center).SafeNormalize(Vector2.UnitY) * chargeVelocity;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.velocity *= 1.15f;
}
}
@@ -336,7 +336,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
npc.velocity = (Main.player[npc.target].Center - npc.Center).SafeNormalize(Vector2.UnitY) * (-chargeVelocity - 2f * enrageScale);
if (death)
npc.velocity *= 1.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.velocity *= 1.15f;
}
}
@@ -728,7 +728,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
float targetYDistPhase1 = Main.player[npc.target].Center.Y - brainCenterPhase1.Y;
float targetDistancePhase1 = (float)Math.Sqrt(targetXDistPhase1 * targetXDistPhase1 + targetYDistPhase1 * targetYDistPhase1);
float maxMoveVelocity = (death ? 4f : 1.5f) + velocityScale;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
maxMoveVelocity *= 2f;
if (targetDistancePhase1 < maxMoveVelocity)
@@ -997,7 +997,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
Vector2 destination = Main.player[npc.target].Center + (death ? Main.player[npc.target].velocity * 20f : Vector2.Zero);
Vector2 targetDirection = destination - npc.Center;
targetDirection = targetDirection.SafeNormalize(Vector2.UnitY);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
targetDirection *= chargeVelocity + 6f;
npc.velocity = (npc.velocity * 49f + targetDirection) / 50f;
@@ -1052,7 +1052,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
public static int GetBrainOfCthuluCreepersCountRevDeath()
{
return CalamityWorld.LegendaryMode ? 40 : Main.getGoodWorld ? 35 : (CalamityWorld.death || BossRushEvent.BossRushActive) ? 30 : 20;
return CalamityWorld.LegendaryMode ? 40 : CalamityWorld.LegendaryMode ? 35 : (CalamityWorld.death || BossRushEvent.BossRushActive) ? 30 : 20;
}
private static float GetCrimsonBossKnockBack(NPC npc, int numPlayers, float lifeScale, float baseKnockBackResist)
@@ -83,7 +83,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
idleTime = 20;
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
iceMistFireRate = 30;
iceMistSpeed = 15f;
@@ -195,7 +195,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
}
// Total segment variable
int totalSegments = Main.getGoodWorld ? 100 : 80;
int totalSegments = CalamityWorld.LegendaryMode ? 100 : 80;
// Calculate aggression based on how many broken segments there are
float brokenSegmentAggressionMultiplier = 1f;
@@ -230,7 +230,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (oblivionAlive)
{
calamityGlobalNPC.newAI[3] = 0f;
totalSegments = Main.getGoodWorld ? 75 : 60;
totalSegments = CalamityWorld.LegendaryMode ? 75 : 60;
spitLaserSpreads = false;
noFlyZoneBoxHeight = 2000;
}
@@ -264,7 +264,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
speed *= brokenSegmentAggressionMultiplier;
turnSpeed *= brokenSegmentAggressionMultiplier;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
segmentVelocity *= 1.2f;
speed *= 1.2f;
@@ -58,7 +58,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
idlePhaseVelocity = 10f;
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
idlePhaseAcceleration *= 1.15f;
idlePhaseVelocity *= 1.15f;
@@ -86,7 +86,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
chargeVelocity *= 1.13f;
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeVelocity *= 1.15f;
int bubbleBelchPhaseTimer = death ? 60 : 80;
@@ -94,7 +94,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
float bubbleBelchPhaseAcceleration = death ? 0.35f : 0.3f;
float bubbleBelchPhaseVelocity = death ? 5.5f : 5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
bubbleBelchPhaseAcceleration *= 1.5f;
bubbleBelchPhaseVelocity *= 1.5f;
@@ -112,7 +112,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
float bubbleSpinPhaseVelocity = 20f;
float bubbleSpinPhaseRotation = MathHelper.TwoPi / (bubbleSpinPhaseTimer / 2);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
bubbleSpinBubbleVelocity *= 1.5f;
int spawnEffectPhaseTimer = 75;
@@ -192,7 +192,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
chargeTime += Main.rand.Next(5, 66);
// Spawn cthulhunadoes in phase 3
if (phase3AI && ((!phase4 && !deathModeSurprise) || Main.getGoodWorld))
if (phase3AI && ((!phase4 && !deathModeSurprise) || CalamityWorld.LegendaryMode))
{
calamityGlobalNPC.newAI[0] += 1f;
float timeGateValue = 600f;
@@ -94,7 +94,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
npc.localAI[1] -= 1f;
int vileSpitGateValue = (int)MathHelper.Lerp(death ? 45f : 90f, 900f, lifeRatio);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
vileSpitGateValue = (int)(vileSpitGateValue * 0.5f);
Vector2 vileSpitShootLocation = npc.Center + npc.velocity;
@@ -414,7 +414,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
segmentAcceleration += (npc.justHit ? 0.16f : 0.04f);
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
segmentVelocity += 4f;
segmentAcceleration += 0.05f;
@@ -451,7 +451,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
int npcWidth = npc.width;
npcWidth = (int)(npcWidth * npc.scale);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npcWidth = 62;
targetDistance = (targetDistance - npcWidth) / targetDistance;
@@ -73,7 +73,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
bool visible = true;
bool takeDamage = true;
float lessTimeSpentPerPhaseMultiplier = phase2 ? (death ? 0.375f : 0.5f) : (death ? 0.75f : 1f);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
lessTimeSpentPerPhaseMultiplier *= 0.2f;
float extraPhaseTime;
@@ -151,7 +151,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
npc.damage = 0;
float idleTimer = phase2 ? (death ? 10f : 15f) : (death ? 20f : 30f);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
idleTimer *= 0.5f;
if (idleTimer < 10f)
idleTimer = 10f;
@@ -144,7 +144,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
hoverAcceleration += 0.15f * (1f - lifeRatio);
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
hoverSpeed += 3f;
hoverAcceleration += 0.08f;
@@ -173,7 +173,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
npc.ai[3] += 1f;
float servantSpawnGateValue = death ? 10f : 40f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
servantSpawnGateValue *= 0.8f;
if (npc.ai[3] >= servantSpawnGateValue && shootProjectile)
@@ -226,7 +226,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
chargeSpeed += 5f * enrageScale;
if (death)
chargeSpeed += 10f * (1f - lifeRatio);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeSpeed += 4f;
npc.velocity = npc.SafeDirectionTo(Main.player[npc.target].Center) * chargeSpeed;
@@ -240,7 +240,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
npc.damage = npc.defDamage;
int chargeDelay = death ? (75 - (int)Math.Round(30f * (1f - lifeRatio))) : 95;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeDelay -= 30;
float slowDownGateValue = chargeDelay * (death ? 0.85f : 0.65f);
@@ -256,7 +256,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
decelerationScalar = 0f;
npc.velocity *= (MathHelper.Lerp(death ? 0.76f : 0.92f, death ? 0.88f : 0.96f, decelerationScalar));
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.velocity *= 0.99f;
if (npc.velocity.X > -0.1 && npc.velocity.X < 0.1)
@@ -307,7 +307,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
// Avoid cheap bullshit
npc.damage = 0;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.reflectsProjectiles = true;
if (npc.ai[0] == 1f)
@@ -326,13 +326,13 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
npc.rotation += npc.ai[2];
float phaseChangeRate = death ? 2f : 1f;
float servantSpawnGateValue = Main.getGoodWorld ? 4f : 20f;
float servantSpawnGateValue = CalamityWorld.LegendaryMode ? 4f : 20f;
npc.ai[1] += phaseChangeRate;
if (npc.ai[1] % servantSpawnGateValue == 0f)
{
float servantVelocity = death ? 11.3f : 5.65f;
Vector2 servantSpawnVelocity = Main.rand.NextVector2CircularEdge(servantVelocity, servantVelocity);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
servantSpawnVelocity *= 3f;
Vector2 servantSpawnCenter = npc.Center + servantSpawnVelocity.SafeNormalize(Vector2.UnitY) * ProjectileOffset;
@@ -457,7 +457,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
}
}
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
hoverSpeed += 1f;
hoverAcceleration += 0.1f;
@@ -520,7 +520,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
chargeSpeed *= 1.15f;
if (npc.ai[3] == 2f)
chargeSpeed *= 1.3f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
chargeSpeed *= 1.2f;
npc.velocity = npc.SafeDirectionTo(Main.player[npc.target].Center) * chargeSpeed;
+29 -29
View File
@@ -63,12 +63,12 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (tile.WallType == WallID.LihzahrdBrickUnsafe)
enrage = false;
else
turboEnrage = bossRush || Main.getGoodWorld;
turboEnrage = bossRush || CalamityWorld.LegendaryMode;
}
else
turboEnrage = bossRush || Main.getGoodWorld;
turboEnrage = bossRush || CalamityWorld.LegendaryMode;
if (bossRush || Main.getGoodWorld)
if (bossRush || CalamityWorld.LegendaryMode)
enrage = true;
npc.Calamity().CurrentlyEnraged = !bossRush && (enrage || turboEnrage);
@@ -98,7 +98,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
int despawnDistance = turboEnrage ? 7500 : enrage ? 6000 : 4500;
// Deactivate torches
if (Main.netMode != NetmodeID.MultiplayerClient && Main.getGoodWorld && npc.velocity.Y > 0f)
if (Main.netMode != NetmodeID.MultiplayerClient && CalamityWorld.LegendaryMode && npc.velocity.Y > 0f)
{
for (int j = (int)(npc.position.X / 16f); (float)j < (npc.position.X + (float)npc.width) / 16f; j++)
{
@@ -115,7 +115,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
}
// Spawn arm dust
if (!Main.getGoodWorld)
if (!CalamityWorld.LegendaryMode)
{
if (!leftFistAlive)
{
@@ -190,7 +190,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (enrage)
divisor = 5f;
if (turboEnrage && Main.getGoodWorld)
if (turboEnrage && CalamityWorld.LegendaryMode)
divisor = 2f;
Vector2 projectileFirePos = new Vector2(npc.Center.X, npc.Center.Y - 60f);
@@ -212,7 +212,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
{
int bodyLaser = Projectile.NewProjectile(npc.GetSource_FromAI(), projectileFirePos + laserVelocity.SafeNormalize(Vector2.UnitY) * 40f, laserVelocity, type, damage, 0f, Main.myPlayer);
Main.projectile[bodyLaser].timeLeft = enrage ? 720 : 360;
if (turboEnrage && Main.getGoodWorld)
if (turboEnrage && CalamityWorld.LegendaryMode)
Main.projectile[bodyLaser].extraUpdates += 1;
}
}
@@ -231,7 +231,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (npc.ai[1] > 0f)
{
npc.ai[1] += (death ? 2f : 1f);
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
npc.ai[1] += 100f;
if (enrage || death)
@@ -530,7 +530,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
destination.Normalize();
destination *= projectileVelocity;
int totalFireballsPerSide = 3;
int totalIterations = (turboEnrage && Main.getGoodWorld) ? 11 : death ? 25 : 35;
int totalIterations = (turboEnrage && CalamityWorld.LegendaryMode) ? 11 : death ? 25 : 35;
float rotation = MathHelper.ToRadians(90);
for (int i = 0; i < totalIterations; i++)
{
@@ -540,7 +540,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
Vector2 perturbedSpeed = destination.RotatedBy(MathHelper.Lerp(-rotation, rotation, i / (float)(totalIterations - 1)));
int proj = Projectile.NewProjectile(npc.GetSource_FromAI(), npc.Center + Vector2.UnitY * (npc.height / 2 * 0.8f) * npc.scale + Vector2.Normalize(perturbedSpeed) * (npc.width / 3) * npc.scale, perturbedSpeed, type, damage, 0f, Main.myPlayer);
Main.projectile[proj].timeLeft = enrage ? 480 : 240;
if (turboEnrage && Main.getGoodWorld)
if (turboEnrage && CalamityWorld.LegendaryMode)
Main.projectile[proj].extraUpdates += 1;
}
}
@@ -578,7 +578,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
Vector2 projVelocity = laserVelocity.RotatedBy(radians * j + MathHelper.PiOver2);
int bodyLaser = Projectile.NewProjectile(npc.GetSource_FromAI(), fireFrom, projVelocity, type, damage, 0f, Main.myPlayer);
Main.projectile[bodyLaser].timeLeft = enrage ? 720 : 360;
if (turboEnrage && Main.getGoodWorld)
if (turboEnrage && CalamityWorld.LegendaryMode)
Main.projectile[bodyLaser].extraUpdates += 1;
}
}
@@ -643,8 +643,8 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
void CustomGravity(bool isSlamming)
{
float gravity = turboEnrage ? (Main.getGoodWorld ? 1.15f : 0.85f) : enrage ? 0.75f : (!leftFistAlive && !rightFistAlive) ? 0.45f : 0.3f;
float maxFallSpeed = reduceFallSpeed ? 12f : turboEnrage ? (Main.getGoodWorld ? 40f : 30f) : enrage ? 25f : (!leftFistAlive && !rightFistAlive) ? 15f : 10f;
float gravity = turboEnrage ? (CalamityWorld.LegendaryMode ? 1.15f : 0.85f) : enrage ? 0.75f : (!leftFistAlive && !rightFistAlive) ? 0.45f : 0.3f;
float maxFallSpeed = reduceFallSpeed ? 12f : turboEnrage ? (CalamityWorld.LegendaryMode ? 40f : 30f) : enrage ? 25f : (!leftFistAlive && !rightFistAlive) ? 15f : 10f;
if (isSlamming && !reduceFallSpeed)
{
gravity *= 4f;
@@ -715,15 +715,15 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (tile.WallType == WallID.LihzahrdBrickUnsafe)
enrage = false;
else
turboEnrage = bossRush || Main.getGoodWorld;
turboEnrage = bossRush || CalamityWorld.LegendaryMode;
}
else
turboEnrage = bossRush || Main.getGoodWorld;
turboEnrage = bossRush || CalamityWorld.LegendaryMode;
if (bossRush || Main.getGoodWorld)
if (bossRush || CalamityWorld.LegendaryMode)
enrage = true;
float aggression = turboEnrage ? (Main.getGoodWorld ? 4f : 3f) : enrage ? 2f : death ? 1.7f : 1f;
float aggression = turboEnrage ? (CalamityWorld.LegendaryMode ? 4f : 3f) : enrage ? 2f : death ? 1.7f : 1f;
Vector2 fistCenter = golem.Center + golem.velocity + new Vector2(0f, -9f * npc.scale);
fistCenter.X += (float)((npc.type == NPCID.GolemFistLeft) ? -84 : 78) * npc.scale;
@@ -805,7 +805,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
Dust dust = Dust.NewDustPerfect(npc.Center + largeRandDustRecoil + largeRandDustRadius + smallRandDustRadius, 228, largeRandDustRecoil);
dust.fadeIn = 1.5f;
dust.scale = 0.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
dust.noLight = true;
dust.noGravity = true;
@@ -846,7 +846,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
// Set damage
npc.damage = npc.defDamage;
if (Main.netMode != NetmodeID.MultiplayerClient && Main.getGoodWorld)
if (Main.netMode != NetmodeID.MultiplayerClient && CalamityWorld.LegendaryMode)
{
for (int j = (int)(npc.position.X / 16f) - 1; (float)j < (npc.position.X + (float)npc.width) / 16f + 1f; j++)
{
@@ -1042,12 +1042,12 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (tile.WallType == WallID.LihzahrdBrickUnsafe)
enrage = false;
else
turboEnrage = bossRush || Main.getGoodWorld;
turboEnrage = bossRush || CalamityWorld.LegendaryMode;
}
else
turboEnrage = bossRush || Main.getGoodWorld;
turboEnrage = bossRush || CalamityWorld.LegendaryMode;
if (bossRush || Main.getGoodWorld)
if (bossRush || CalamityWorld.LegendaryMode)
enrage = true;
// Alpha
@@ -1188,7 +1188,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
{
int bodyLaser = Projectile.NewProjectile(npc.GetSource_FromAI(), projectileFirePos + laserVelocity.SafeNormalize(Vector2.UnitY) * 40f, laserVelocity, projType, dmg, 0f, Main.myPlayer);
Main.projectile[bodyLaser].timeLeft = enrage ? 600 : 300;
if (turboEnrage && Main.getGoodWorld)
if (turboEnrage && CalamityWorld.LegendaryMode)
Main.projectile[bodyLaser].extraUpdates += 1;
npc.netUpdate = true;
@@ -1217,7 +1217,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
{
int extraLasers = Projectile.NewProjectile(npc.GetSource_FromAI(), projectileFirePos + laserVelocity.SafeNormalize(Vector2.UnitY) * 40f, laserVelocity, projType, dmg, 0f, Main.myPlayer);
Main.projectile[extraLasers].timeLeft = enrage ? 600 : 300;
if (turboEnrage && Main.getGoodWorld)
if (turboEnrage && CalamityWorld.LegendaryMode)
Main.projectile[extraLasers].extraUpdates += 1;
npc.netUpdate = true;
@@ -1286,12 +1286,12 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (tile.WallType == WallID.LihzahrdBrickUnsafe)
enrage = false;
else
turboEnrage = bossRush || Main.getGoodWorld;
turboEnrage = bossRush || CalamityWorld.LegendaryMode;
}
else
turboEnrage = bossRush || Main.getGoodWorld;
turboEnrage = bossRush || CalamityWorld.LegendaryMode;
if (bossRush || Main.getGoodWorld)
if (bossRush || CalamityWorld.LegendaryMode)
enrage = true;
if (turboEnrage)
@@ -1522,12 +1522,12 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
int damage = npc.GetProjectileDamage(type);
int freeHeadLaser = Projectile.NewProjectile(npc.GetSource_FromAI(), freeHeadProjSpawn + laserVelocity.SafeNormalize(Vector2.UnitY) * 40f, laserVelocity, type, damage, 0f, Main.myPlayer);
Main.projectile[freeHeadLaser].timeLeft = enrage ? 600 : 300;
if (turboEnrage && Main.getGoodWorld)
if (turboEnrage && CalamityWorld.LegendaryMode)
Main.projectile[freeHeadLaser].extraUpdates += 1;
}
}
if (!Main.getGoodWorld)
if (!CalamityWorld.LegendaryMode)
{
npc.position += npc.netOffset;
int randDustOffset = Main.rand.Next(2) * 2 - 1;
@@ -27,7 +27,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
bool teleported = false;
npc.aiAction = 0;
float teleportScaleSpeed = 2f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
{
teleportScaleSpeed -= 1f - lifeRatio;
teleportScale *= teleportScaleSpeed;
@@ -317,7 +317,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
npc.ai[0] += teleportRate;
teleportScale = MathHelper.Clamp((60f - npc.ai[0]) / 60f, 0f, 1f);
teleportScale = 0.5f + teleportScale * 0.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
teleportScale *= teleportScaleSpeed;
if (npc.ai[0] >= 60f)
@@ -399,7 +399,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
npc.ai[0] += teleportRate;
teleportScale = MathHelper.Clamp(npc.ai[0] / 30f, 0f, 1f);
teleportScale = 0.5f + teleportScale * 0.5f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
teleportScale *= teleportScaleSpeed;
if (npc.ai[0] >= 30f && Main.netMode != NetmodeID.MultiplayerClient)
@@ -516,7 +516,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
float jumpVelocityLimit = redCrystalAlive ? 3f : 4.5f;
if (death)
jumpVelocityLimit += 3f;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
jumpVelocityLimit = 8f;
if ((npc.direction == 1 && npc.velocity.X < jumpVelocityLimit) || (npc.direction == -1 && npc.velocity.X > -jumpVelocityLimit))
@@ -554,12 +554,12 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
return false;
// Adjust size based on HP
float maxScale = death ? (Main.getGoodWorld ? 6f : 2.5f) : (Main.getGoodWorld ? 3f : 1.5f);
float maxScale = death ? (CalamityWorld.LegendaryMode ? 6f : 2.5f) : (CalamityWorld.LegendaryMode ? 3f : 1.5f);
float minScale = death ? 0.5f : 0.75f;
float maxScaledValue = maxScale - minScale;
// Inversed scale in FTW
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
lifeRatio = (maxScaledValue - lifeRatio * maxScaledValue) + minScale;
else
lifeRatio = lifeRatio * maxScaledValue + minScale;
@@ -48,7 +48,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (bossRush)
aggressionLevel = 5;
if (Main.getGoodWorld)
if (CalamityWorld.LegendaryMode)
aggressionLevel = 6;
if (npc.type == NPCID.MoonLordCore)
@@ -811,7 +811,7 @@ namespace CalamityMod.NPCs.VanillaNPCAIOverrides.Bosses
if (npc.localAI[1] < 0f)
{
npc.localAI[1] = 0f;
if (Main.netMode != NetmodeID.MultiplayerClient && Main.getGoodWorld && Main.remixWorld)
if (Main.netMode != NetmodeID.MultiplayerClient && CalamityWorld.LegendaryMode && Main.remixWorld)
{
for (int k = 0; k < 30; k++)
{
Loaded 100 of 135 files, more files were not shown because too many files have changed in this diff. Show more