Aureus Spawn color drawing fix and more fucking Dark Energy changes.

This commit is contained in:
mountaindrew10 committed 2023-02-08 08:37:25 -06:00
1 parent 61ab0c90b6
commit b0bd4f2ffc
2 files changed
+15 -2

No files matched your search

+1 -1
View File
@@ -236,7 +236,7 @@ namespace CalamityMod.NPCs.AstrumAureus
spriteEffects = SpriteEffects.FlipHorizontally;
if (NPC.ai[0] >= 60f)
NPC.DrawBackglow(Color.Lerp(Color.Cyan, Color.Orange, (float)Math.Sin(Main.GlobalTimeWrappedHourly) / 2f + 1f) with { A = 0 }, 2f + 8f * ((float)Math.Sin(Main.GlobalTimeWrappedHourly * MathHelper.TwoPi) + 1f), spriteEffects, NPC.frame, screenPos);
NPC.DrawBackglow(Color.Lerp(Color.Cyan, Color.Orange, (float)Math.Sin(Main.GlobalTimeWrappedHourly) / 2f + 0.5f) with { A = 0 }, 2f + 8f * ((float)Math.Sin(Main.GlobalTimeWrappedHourly * MathHelper.TwoPi) + 1f), spriteEffects, NPC.frame, screenPos);
Texture2D texture2D15 = TextureAssets.Npc[NPC.type].Value;
Vector2 vector11 = new Vector2(TextureAssets.Npc[NPC.type].Value.Width / 2, TextureAssets.Npc[NPC.type].Value.Height / Main.npcFrameCount[NPC.type] / 2);
+14 -1
View File
@@ -105,7 +105,7 @@ namespace CalamityMod.NPCs.CeaselessVoid
}
// Stay invincible for 200 frames to avoid being instantly killed and don't deal damage to avoid unfair hits
if (NPC.Opacity < 1f)
if (NPC.Opacity < 1f && NPC.dontTakeDamage)
{
NPC.damage = 0;
@@ -117,8 +117,21 @@ namespace CalamityMod.NPCs.CeaselessVoid
}
else
{
if (NPC.dontTakeDamage)
{
for (int k = 0; k < 10; k++)
{
int dust = Dust.NewDust(NPC.position, NPC.width, NPC.height, (int)CalamityDusts.PurpleCosmilite, 0, 0, 0, default, 1f);
Main.dust[dust].noGravity = true;
}
}
NPC.damage = NPC.defDamage;
NPC.dontTakeDamage = false;
float scalar = (float)Math.Cos(NPC.Calamity().newAI[1] * MathHelper.TwoPi) / 2f + 0.5f;
NPC.scale = MathHelper.Lerp(0.9f, 1f, scalar);
NPC.Opacity = MathHelper.Lerp(0.5f, 1f, scalar);
NPC.Calamity().newAI[1] += 1f;
}
// Force despawn if Ceaseless Void isn't active