Merge branch 'master' into weapons
This commit is contained in:
commit
8a112b2b91
143 files changed
+637
-462
No files matched your search
@@ -1,23 +0,0 @@
|
||||
using Terraria;
|
||||
using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.Buffs.StatBuffs
|
||||
{
|
||||
public class EvasionScarfBoost : ModBuff
|
||||
{
|
||||
public override void SetDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Evasion Scarf Boost");
|
||||
Description.SetDefault("10% increased damage, 10% increased crit chance, and 15% increased melee speed");
|
||||
Main.debuff[Type] = false;
|
||||
Main.pvpBuff[Type] = true;
|
||||
Main.buffNoSave[Type] = true;
|
||||
longerExpertDebuff = false;
|
||||
}
|
||||
|
||||
public override void Update(Player player, ref int buffIndex)
|
||||
{
|
||||
player.Calamity().eScarfBoost = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 547 B |
@@ -1,23 +0,0 @@
|
||||
using Terraria;
|
||||
using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.Buffs.StatBuffs
|
||||
{
|
||||
public class ScarfMeleeBoost : ModBuff
|
||||
{
|
||||
public override void SetDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Scarf Boost");
|
||||
Description.SetDefault("10% increased damage, 5% increased crit chance, and 5% increased melee speed");
|
||||
Main.debuff[Type] = false;
|
||||
Main.pvpBuff[Type] = true;
|
||||
Main.buffNoSave[Type] = true;
|
||||
longerExpertDebuff = false;
|
||||
}
|
||||
|
||||
public override void Update(Player player, ref int buffIndex)
|
||||
{
|
||||
player.Calamity().sMeleeBoost = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 575 B |
@@ -613,7 +613,8 @@ namespace CalamityMod.CalPlayer
|
||||
public int tarraMageHealCooldown = 0;
|
||||
public int tarraCrits = 0;
|
||||
public bool tarraRanged = false;
|
||||
public bool tarraThrowing = false;
|
||||
public int tarraRangedCooldown = 0;
|
||||
public bool tarraThrowing = false;
|
||||
public bool tarragonImmunityCooldown = false;
|
||||
public bool tarragonImmunity = false;
|
||||
public int tarraThrowingCrits = 0;
|
||||
@@ -765,8 +766,6 @@ namespace CalamityMod.CalPlayer
|
||||
public bool xWrath = false;
|
||||
public bool graxDefense = false;
|
||||
public bool encased = false;
|
||||
public bool sMeleeBoost = false;
|
||||
public bool eScarfBoost = false;
|
||||
public bool tFury = false;
|
||||
public bool cadence = false;
|
||||
public bool omniscience = false;
|
||||
@@ -1796,8 +1795,6 @@ namespace CalamityMod.CalPlayer
|
||||
xWrath = false;
|
||||
graxDefense = false;
|
||||
encased = false;
|
||||
sMeleeBoost = false;
|
||||
eScarfBoost = false;
|
||||
tFury = false;
|
||||
cadence = false;
|
||||
omniscience = false;
|
||||
@@ -2080,7 +2077,8 @@ namespace CalamityMod.CalPlayer
|
||||
gSabatonCooldown = 0;
|
||||
astralStarRainCooldown = 0;
|
||||
bloodflareMageCooldown = 0;
|
||||
tarraMageHealCooldown = 0;
|
||||
tarraRangedCooldown = 0;
|
||||
tarraMageHealCooldown = 0;
|
||||
bossRushImmunityFrameCurseTimer = 0;
|
||||
aBulwarkRareMeleeBoostTimer = 0;
|
||||
acidRoundMultiplier = 1D;
|
||||
@@ -2201,8 +2199,6 @@ namespace CalamityMod.CalPlayer
|
||||
kamiBoost = false;
|
||||
graxDefense = false;
|
||||
encased = false;
|
||||
sMeleeBoost = false;
|
||||
eScarfBoost = false;
|
||||
tFury = false;
|
||||
cadence = false;
|
||||
omniscience = false;
|
||||
@@ -3612,14 +3608,6 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
meleeSpeedMult += 0.1f;
|
||||
}
|
||||
if (sMeleeBoost)
|
||||
{
|
||||
meleeSpeedMult += 0.05f;
|
||||
}
|
||||
if (eScarfBoost)
|
||||
{
|
||||
meleeSpeedMult += 0.15f;
|
||||
}
|
||||
if (yPower)
|
||||
{
|
||||
meleeSpeedMult += 0.05f;
|
||||
@@ -4050,15 +4038,9 @@ namespace CalamityMod.CalPlayer
|
||||
private void OnDodge()
|
||||
{
|
||||
if (evasionScarf)
|
||||
{
|
||||
player.AddBuff(ModContent.BuffType<EvasionScarfBoost>(), CalamityUtils.SecondsToFrames(9f));
|
||||
player.AddBuff(ModContent.BuffType<EvasionScarfCooldown>(), player.chaosState ? CalamityUtils.SecondsToFrames(20f) : CalamityUtils.SecondsToFrames(13f));
|
||||
}
|
||||
else
|
||||
{
|
||||
player.AddBuff(ModContent.BuffType<ScarfMeleeBoost>(), 540);
|
||||
player.AddBuff(ModContent.BuffType<ScarfCooldown>(), player.chaosState ? 1800 : 900);
|
||||
}
|
||||
|
||||
player.immune = true;
|
||||
player.immuneTime = player.longInvince ? 100 : 60;
|
||||
@@ -4518,24 +4500,6 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Use Time Mult
|
||||
public override float UseTimeMultiplier(Item item)
|
||||
{
|
||||
if (auricSet && godSlayerRanged)
|
||||
{
|
||||
if (item.ranged && item.useTime > 3)
|
||||
return 1.05f;
|
||||
}
|
||||
if (auricSet && godSlayerThrowing)
|
||||
{
|
||||
if (player.statLife > (int)(player.statLifeMax2 * 0.5) &&
|
||||
item.Calamity().rogue && item.useTime > 3)
|
||||
return 1.05f;
|
||||
}
|
||||
return 1f;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Get Heal Life
|
||||
public override void GetHealLife(Item item, bool quickHeal, ref int healValue)
|
||||
{
|
||||
@@ -5210,10 +5174,6 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
#region MultiplierBoosts
|
||||
double damageMult = 1.0;
|
||||
if (auricSet && godSlayerDamage && item.melee)
|
||||
{
|
||||
damageMult += 0.15;
|
||||
}
|
||||
if (item.melee && item.type != ModContent.ItemType<UltimusCleaver>() && item.type != ModContent.ItemType<InfernaCutter>())
|
||||
{
|
||||
damageMult += trueMeleeDamage;
|
||||
@@ -5341,9 +5301,6 @@ namespace CalamityMod.CalPlayer
|
||||
damageMult += 0.05;
|
||||
}
|
||||
|
||||
if (auricSet && godSlayerDamage && isTrueMelee)
|
||||
damageMult += 0.15;
|
||||
|
||||
if (enraged)
|
||||
damageMult += 1.25;
|
||||
|
||||
@@ -5353,12 +5310,6 @@ namespace CalamityMod.CalPlayer
|
||||
if (silvaCountdown <= 0 && hasSilvaEffect && silvaSummon && isSummon)
|
||||
damageMult += 0.1;
|
||||
|
||||
if (proj.type == ModContent.ProjectileType<FrostsparkBulletProj>())
|
||||
{
|
||||
if (target.buffImmune[ModContent.BuffType<GlacialState>()])
|
||||
damageMult += 0.1;
|
||||
}
|
||||
|
||||
else if (proj.type == ProjectileID.InfernoFriendlyBlast)
|
||||
{
|
||||
damageMult += 0.33;
|
||||
|
||||
@@ -1152,6 +1152,8 @@ namespace CalamityMod.CalPlayer
|
||||
modPlayer.gSabatonFall--;
|
||||
if (modPlayer.astralStarRainCooldown > 0)
|
||||
modPlayer.astralStarRainCooldown--;
|
||||
if (modPlayer.tarraRangedCooldown > 0)
|
||||
modPlayer.tarraRangedCooldown--;
|
||||
if (modPlayer.bloodflareMageCooldown > 0)
|
||||
modPlayer.bloodflareMageCooldown--;
|
||||
if (modPlayer.tarraMageHealCooldown > 0)
|
||||
@@ -2524,17 +2526,6 @@ namespace CalamityMod.CalPlayer
|
||||
player.meleeDamage += 0.2f;
|
||||
}
|
||||
|
||||
if (modPlayer.eScarfBoost)
|
||||
{
|
||||
player.allDamage += 0.1f;
|
||||
modPlayer.AllCritBoost(10);
|
||||
}
|
||||
if (modPlayer.sMeleeBoost)
|
||||
{
|
||||
player.allDamage += 0.1f;
|
||||
modPlayer.AllCritBoost(5);
|
||||
}
|
||||
|
||||
if (modPlayer.tFury)
|
||||
{
|
||||
player.meleeDamage += 0.3f;
|
||||
@@ -3690,8 +3681,8 @@ namespace CalamityMod.CalPlayer
|
||||
modPlayer.GetStatBonuses();
|
||||
|
||||
// True melee damage bonuses
|
||||
double damageAdd = (modPlayer.dodgeScarf ? 0.15 : 0) +
|
||||
(modPlayer.evasionScarf ? 0.1 : 0) +
|
||||
double damageAdd = (modPlayer.dodgeScarf ? 0.1 : 0) +
|
||||
(modPlayer.evasionScarf ? 0.05 : 0) +
|
||||
((modPlayer.aBulwarkRare && modPlayer.aBulwarkRareMeleeBoostTimer > 0) ? 0.5 : 0) +
|
||||
(modPlayer.fungalSymbiote ? 0.15 : 0) +
|
||||
((player.head == ArmorIDs.Head.MoltenHelmet && player.body == ArmorIDs.Body.MoltenBreastplate && player.legs == ArmorIDs.Legs.MoltenGreaves) ? 0.2 : 0) +
|
||||
|
||||
@@ -242,21 +242,12 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
}
|
||||
}
|
||||
if (modPlayer.tarraRanged && Main.rand.Next(0, 100) >= 88 && player.ownedProjectileCounts[ProjectileType<TarraEnergy>()] < 5 && (proj.timeLeft <= 2 || proj.penetrate <= 1))
|
||||
{
|
||||
int projAmt = Main.rand.Next(2, 4);
|
||||
for (int projCount = 0; projCount < projAmt; projCount++)
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(100f, 70f, 100f);
|
||||
Projectile.NewProjectile(proj.Center, velocity, ProjectileType<TarraEnergy>(), CalamityUtils.DamageSoftCap(proj.damage * 0.33, 65), 0f, proj.owner);
|
||||
}
|
||||
}
|
||||
if (npcCheck)
|
||||
{
|
||||
if (modPlayer.tarraRanged && crit && proj.ranged)
|
||||
if (modPlayer.tarraRanged && proj.ranged && modPlayer.tarraRangedCooldown <= 0)
|
||||
{
|
||||
int leafAmt = Main.rand.Next(2, 4);
|
||||
for (int l = 0; l < leafAmt; l++)
|
||||
modPlayer.tarraRangedCooldown = 60;
|
||||
for (int l = 0; l < 2; l++)
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(100f, 70f, 100f);
|
||||
int FUCKYOU = Projectile.NewProjectile(position, velocity, ProjectileID.Leaf, CalamityUtils.DamageSoftCap(proj.damage * 0.25, 60), 0f, player.whoAmI);
|
||||
@@ -266,7 +257,15 @@ namespace CalamityMod.CalPlayer
|
||||
Main.projectile[FUCKYOU].netUpdate = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (player.ownedProjectileCounts[ProjectileType<TarraEnergy>()] < 2)
|
||||
{
|
||||
for (int projCount = 0; projCount < 2; projCount++)
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(100f, 70f, 100f);
|
||||
Projectile.NewProjectile(proj.Center, velocity, ProjectileType<TarraEnergy>(), CalamityUtils.DamageSoftCap(proj.damage * 0.33, 65), 0f, proj.owner);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (proj.type == ProjectileType<PolarStar>())
|
||||
{
|
||||
modPlayer.polarisBoostCounter += 1;
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 408 B |
Binary file not shown.
|
Before Width: | Height: | Size: 268 B |
Binary file not shown.
|
Before Width: | Height: | Size: 259 B |
Binary file not shown.
|
Before Width: | Height: | Size: 254 B |
@@ -107,6 +107,7 @@ namespace CalamityMod.ILEditing
|
||||
|
||||
ApplyLifeBytesChanges();
|
||||
AdjustChlorophyteBullets();
|
||||
AdjustCultistCloneFireballDust();
|
||||
RemoveAerialBaneDamageBoost();
|
||||
AdjustDamageVariance();
|
||||
RemoveExpertHardmodeScaling();
|
||||
@@ -155,6 +156,19 @@ namespace CalamityMod.ILEditing
|
||||
};
|
||||
}
|
||||
|
||||
private static void AdjustCultistCloneFireballDust()
|
||||
{
|
||||
// Reduce dust from 10 to 5 and homing range.
|
||||
IL.Terraria.Projectile.AI_001 += (il) =>
|
||||
{
|
||||
var cursor = new ILCursor(il);
|
||||
cursor.GotoNext(MoveType.Before, i => i.MatchLdcI4(468)); // The ID of Cultist Clone Fireballs.
|
||||
cursor.GotoNext(MoveType.Before, i => i.MatchLdcR4(12f)); // The gate value for spawning dust circles.
|
||||
cursor.Remove();
|
||||
cursor.Emit(OpCodes.Ldc_R4, 60f); // Increase to 60f.
|
||||
};
|
||||
}
|
||||
|
||||
private static void RemoveAerialBaneDamageBoost()
|
||||
{
|
||||
IL.Terraria.Projectile.Damage += (il) =>
|
||||
|
||||
@@ -11,9 +11,8 @@ namespace CalamityMod.Items.Accessories
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Counter Scarf");
|
||||
Tooltip.SetDefault("True melee strikes deal 15% more damage\n" +
|
||||
Tooltip.SetDefault("True melee strikes deal 10% more damage\n" +
|
||||
"Grants the ability to dash; dashing into an attack will cause you to dodge it\n" +
|
||||
"After a dodge you will be granted a buff to all damage, melee speed, and all crit chance for a short time\n" +
|
||||
"After a successful dodge you must wait 15 seconds before you can dodge again\n" +
|
||||
"This cooldown will be twice as long if you have Chaos State\n" +
|
||||
"While on cooldown, Chaos State will last twice as long");
|
||||
|
||||
@@ -11,9 +11,8 @@ namespace CalamityMod.Items.Accessories
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Evasion Scarf");
|
||||
Tooltip.SetDefault("True melee strikes deal 25% more damage\n" +
|
||||
Tooltip.SetDefault("True melee strikes deal 15% more damage\n" +
|
||||
"Grants the ability to dash; dashing into an attack will cause you to dodge it\n" +
|
||||
"After a dodge you will be granted a buff to all damage, melee speed, and all crit chance for a short time\n" +
|
||||
"After a successful dodge you must wait 13 seconds before you can dodge again\n" +
|
||||
"This cooldown will be 50 percent longer if you have Chaos State\n" +
|
||||
"While on cooldown, Chaos State will be 50 percent longer");
|
||||
|
||||
@@ -41,8 +41,7 @@ namespace CalamityMod.Items.Armor
|
||||
player.setBonus = "Melee Tarragon, Bloodflare and God Slayer effects\n" +
|
||||
"Enemies are more likely to target you\n" +
|
||||
"All projectiles spawn healing auric orbs on enemy hits\n" +
|
||||
"Max run speed and acceleration boosted by 10%\n" +
|
||||
"Your melee damage is multiplied based on how high your HP is; at full HP this effect is at max";
|
||||
"Max run speed and acceleration boosted by 10%";
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.tarraSet = true;
|
||||
modPlayer.tarraMelee = true;
|
||||
|
||||
@@ -41,7 +41,6 @@ namespace CalamityMod.Items.Armor
|
||||
player.setBonus = "Rogue Tarragon, Bloodflare and God Slayer armor effects\n" +
|
||||
"All projectiles spawn healing auric orbs on enemy hits\n" +
|
||||
"Max run speed and acceleration boosted by 10%\n" +
|
||||
"Rogue weapon critical strikes will do 1.25 times damage while you are above 50% HP\n" +
|
||||
"Rogue stealth builds while not attacking and slower while moving, up to a max of 130\n" +
|
||||
"Once you have built max stealth, you will be able to perform a Stealth Strike\n" +
|
||||
"Rogue stealth only reduces when you attack, it does not reduce while moving\n" +
|
||||
|
||||
@@ -63,8 +63,7 @@ namespace CalamityMod.Items.Armor
|
||||
player.setBonus = "Reduces enemy spawn rates\n" +
|
||||
"Increased heart pickup range\n" +
|
||||
"Enemies have a chance to drop extra hearts on death\n" +
|
||||
"Ranged critical strikes will cause an explosion of leaves\n" +
|
||||
"Ranged projectiles have a chance to split into life energy on death by hitting an enemy";
|
||||
"Ranged projectiles split into homing life energy and leaves on death";
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
|
||||
@@ -21,7 +21,7 @@ namespace CalamityMod.Items.Weapons.Melee
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.width = 64;
|
||||
item.damage = 160;
|
||||
item.damage = 260;
|
||||
item.melee = true;
|
||||
item.useAnimation = 21;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
|
||||
@@ -139,7 +139,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/ChaoticPufferGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/ChaoticPufferGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.Yellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/ChaoticPufferGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -361,7 +361,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/CuttlefishGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/CuttlefishGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.Gold);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/CuttlefishGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -274,7 +274,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/DevilFishGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/DevilFishGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.Red);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/DevilFishGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -274,7 +274,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/DevilFishGlowAlt").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/DevilFishGlowAlt").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.Red);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/DevilFishGlowAlt"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -127,7 +127,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightYellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -127,7 +127,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyAltGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyAltGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightYellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyAltGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -163,7 +163,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2(Main.npcTexture[npc.type].Width / 2, Main.npcTexture[npc.type].Height / 2);
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyAltGlowHuge").Width, ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyAltGlowHuge").Height) * 0.5f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127, 127, 127, 0).MultiplyRGBA(Color.LightYellow) * npc.Opacity;
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyAltGlowHuge"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -163,7 +163,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2(Main.npcTexture[npc.type].Width / 2, Main.npcTexture[npc.type].Height / 2);
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyGlowHuge").Width, ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyGlowHuge").Height) * 0.5f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127, 127, 127, 0).MultiplyRGBA(Color.LightYellow) * npc.Opacity;
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmBodyGlowHuge"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -431,7 +431,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmHeadGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmHeadGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightYellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmHeadGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Items.Materials;
|
||||
using CalamityMod.Items.Placeables;
|
||||
using CalamityMod.Items.Weapons.Magic;
|
||||
@@ -168,6 +169,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Player player = Main.player[npc.target];
|
||||
|
||||
bool targetDownDeep = player.Calamity().ZoneAbyssLayer4;
|
||||
bool targetOnMount = player.mount.Active;
|
||||
|
||||
if (npc.ai[2] > 0f)
|
||||
npc.realLife = (int)npc.ai[2];
|
||||
@@ -213,17 +215,32 @@ namespace CalamityMod.NPCs.Abyss
|
||||
if (player.dead)
|
||||
{
|
||||
npc.TargetClosest(false);
|
||||
|
||||
npc.velocity.Y += 2f;
|
||||
if (npc.position.Y > Main.worldSurface * 16.0)
|
||||
npc.velocity.Y += 2f;
|
||||
|
||||
if (npc.position.Y > Main.rockLayer * 16.0)
|
||||
player = Main.player[npc.target];
|
||||
if (player.dead)
|
||||
{
|
||||
for (int a = 0; a < Main.maxNPCs; a++)
|
||||
npc.ai[3] = 0f;
|
||||
npc.localAI[0] = 0f;
|
||||
npc.localAI[1] = 0f;
|
||||
npc.localAI[2] = 0f;
|
||||
npc.localAI[3] = 0f;
|
||||
AIState = (float)Phase.ChargeOne;
|
||||
calamityGlobalNPC.newAI[1] = 0f;
|
||||
calamityGlobalNPC.newAI[2] = 0f;
|
||||
calamityGlobalNPC.newAI[3] = 1f;
|
||||
chargeVelocityScalar = 0f;
|
||||
rotationDirection = 0;
|
||||
|
||||
npc.velocity.Y += 2f;
|
||||
if (npc.position.Y > Main.worldSurface * 16.0)
|
||||
npc.velocity.Y += 2f;
|
||||
|
||||
if (npc.position.Y > Main.rockLayer * 16.0)
|
||||
{
|
||||
if (Main.npc[a].type == npc.type || Main.npc[a].type == ModContent.NPCType<EidolonWyrmBodyAltHuge>() || Main.npc[a].type == ModContent.NPCType<EidolonWyrmBodyHuge>() || Main.npc[a].type == ModContent.NPCType<EidolonWyrmTailHuge>())
|
||||
Main.npc[a].active = false;
|
||||
for (int a = 0; a < Main.maxNPCs; a++)
|
||||
{
|
||||
if (Main.npc[a].type == npc.type || Main.npc[a].type == ModContent.NPCType<EidolonWyrmBodyAltHuge>() || Main.npc[a].type == ModContent.NPCType<EidolonWyrmBodyHuge>() || Main.npc[a].type == ModContent.NPCType<EidolonWyrmTailHuge>())
|
||||
Main.npc[a].active = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -264,6 +281,20 @@ namespace CalamityMod.NPCs.Abyss
|
||||
float ancientDoomGateValue = 120f;
|
||||
float lightningChargePhaseGateValue = 180f;
|
||||
|
||||
// Adjust slowing debuff immunity
|
||||
bool immuneToSlowingDebuffs = AIState == (float)Phase.FinalPhase || AIState == (float)Phase.ShadowFireballSpin;
|
||||
npc.buffImmune[ModContent.BuffType<ExoFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<GlacialState>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TemporalSadness>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<KamiDebuff>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<SilvaStun>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Eutrophication>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TimeSlow>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TeslaFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Vaporfied>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Slow] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Webbed] = immuneToSlowingDebuffs;
|
||||
|
||||
// Adjust opacity
|
||||
bool invisiblePartOfChargePhase = calamityGlobalNPC.newAI[2] >= chargePhaseGateValue && calamityGlobalNPC.newAI[2] <= chargePhaseGateValue + 1f && (AIState == (float)Phase.ChargeOne || AIState == (float)Phase.ChargeTwo || AIState == (float)Phase.FastCharge);
|
||||
bool invisiblePartOfLightningChargePhase = calamityGlobalNPC.newAI[2] >= lightningChargePhaseGateValue && calamityGlobalNPC.newAI[2] <= lightningChargePhaseGateValue + 1f && AIState == (float)Phase.LightningCharge;
|
||||
@@ -513,7 +544,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
}
|
||||
|
||||
float predictionAmt = targetDownDeep ? 45f : 60f;
|
||||
float lightningVelocity = targetDownDeep ? 6f : 8f;
|
||||
float lightningVelocity = (targetDownDeep && !targetOnMount) ? 6f : 8f;
|
||||
for (int i = 0; i < numProjectiles; i++)
|
||||
{
|
||||
// Predictive bolt
|
||||
@@ -1357,7 +1388,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2(Main.npcTexture[npc.type].Width / 2, Main.npcTexture[npc.type].Height / 2);
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmHeadGlowHuge").Width, ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmHeadGlowHuge").Height) * 0.5f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127, 127, 127, 0).MultiplyRGBA(Color.LightYellow) * npc.Opacity;
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmHeadGlowHuge"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -126,7 +126,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmTailGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmTailGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightYellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmTailGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -139,7 +139,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2(Main.npcTexture[npc.type].Width / 2, Main.npcTexture[npc.type].Height / 2);
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmTailGlowHuge").Width, ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmTailGlowHuge").Height) * 0.5f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127, 127, 127, 0).MultiplyRGBA(Color.LightYellow) * npc.Opacity;
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/EidolonWyrmTailGlowHuge"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -220,7 +220,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/GiantSquidGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GiantSquidGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.Cyan);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GiantSquidGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -127,7 +127,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelBodyGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelBodyGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightYellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelBodyGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -127,7 +127,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelBodyAltGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelBodyAltGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightYellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelBodyAltGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -314,7 +314,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelHeadGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelHeadGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightYellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelHeadGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -127,7 +127,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelTailGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelTailGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightYellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/GulperEelTailGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -90,7 +90,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/LaserfishGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/LaserfishGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.Yellow);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/LaserfishGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -262,7 +262,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/LuminousCorvinaGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/LuminousCorvinaGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightBlue);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/LuminousCorvinaGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -181,7 +181,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/MirageJellyGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/MirageJellyGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.Purple);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/MirageJellyGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -105,7 +105,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/ToxicMinnowGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/ToxicMinnowGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.LightGreen);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/ToxicMinnowGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -88,7 +88,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2));
|
||||
Vector2 vector = center - Main.screenPosition;
|
||||
vector -= new Vector2((float)ModContent.GetTexture("CalamityMod/NPCs/Abyss/ViperfishGlow").Width, (float)(ModContent.GetTexture("CalamityMod/NPCs/Abyss/ViperfishGlow").Height / Main.npcFrameCount[npc.type])) * 1f / 2f;
|
||||
vector += vector11 * 1f + new Vector2(0f, 0f + 4f + npc.gfxOffY);
|
||||
vector += vector11 * 1f + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
Color color = new Color(127 - npc.alpha, 127 - npc.alpha, 127 - npc.alpha, 0).MultiplyRGBA(Microsoft.Xna.Framework.Color.Gold);
|
||||
Main.spriteBatch.Draw(ModContent.GetTexture("CalamityMod/NPCs/Abyss/ViperfishGlow"), vector,
|
||||
new Microsoft.Xna.Framework.Rectangle?(npc.frame), color, npc.rotation, vector11, 1f, spriteEffects, 0f);
|
||||
|
||||
@@ -82,7 +82,7 @@ namespace CalamityMod.NPCs.AquaticScourge
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
Color color = npc.GetAlpha(lightColor);
|
||||
|
||||
if (Main.npc[(int)npc.ai[2]].Calamity().newAI[3] > 480f && (CalamityWorld.revenge || BossRushEvent.BossRushActive || CalamityWorld.malice))
|
||||
|
||||
@@ -81,7 +81,7 @@ namespace CalamityMod.NPCs.AquaticScourge
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
Color color = npc.GetAlpha(lightColor);
|
||||
|
||||
if (Main.npc[(int)npc.ai[2]].Calamity().newAI[3] > 480f && (CalamityWorld.revenge || BossRushEvent.BossRushActive || CalamityWorld.malice))
|
||||
|
||||
@@ -97,7 +97,7 @@ namespace CalamityMod.NPCs.AquaticScourge
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
Color color = npc.GetAlpha(lightColor);
|
||||
|
||||
if (npc.Calamity().newAI[3] > 480f && (CalamityWorld.revenge || BossRushEvent.BossRushActive || CalamityWorld.malice))
|
||||
|
||||
@@ -81,7 +81,7 @@ namespace CalamityMod.NPCs.AquaticScourge
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
Color color = npc.GetAlpha(lightColor);
|
||||
|
||||
if (Main.npc[(int)npc.ai[2]].Calamity().newAI[3] > 480f && (CalamityWorld.revenge || BossRushEvent.BossRushActive || CalamityWorld.malice))
|
||||
|
||||
@@ -221,7 +221,7 @@ namespace CalamityMod.NPCs.Astral
|
||||
Vector2 vector11 = new Vector2((float)(Main.npcTexture[npc.type].Width / 2), (float)(Main.npcTexture[npc.type].Height / 2));
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
|
||||
@@ -243,14 +243,14 @@ namespace CalamityMod.NPCs.AstrumAureus
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/AstrumAureus/AureusSpawnGlow");
|
||||
@@ -265,7 +265,7 @@ namespace CalamityMod.NPCs.AstrumAureus
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -97,14 +97,14 @@ namespace CalamityMod.NPCs.AstrumDeus
|
||||
color38 *= (num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = npc.localAI[3] == 1f ? ModContent.GetTexture("CalamityMod/NPCs/AstrumDeus/AstrumDeusBodyAltGlow") : ModContent.GetTexture("CalamityMod/NPCs/AstrumDeus/AstrumDeusBodyGlow");
|
||||
@@ -121,7 +121,7 @@ namespace CalamityMod.NPCs.AstrumDeus
|
||||
color41 *= (num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
if (npc.localAI[3] != 1f)
|
||||
|
||||
@@ -112,14 +112,14 @@ namespace CalamityMod.NPCs.AstrumDeus
|
||||
color38 *= (num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/AstrumDeus/AstrumDeusHeadGlow");
|
||||
@@ -136,7 +136,7 @@ namespace CalamityMod.NPCs.AstrumDeus
|
||||
color41 *= (num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
Color color43 = color42;
|
||||
|
||||
@@ -96,14 +96,14 @@ namespace CalamityMod.NPCs.AstrumDeus
|
||||
color38 *= (num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/AstrumDeus/AstrumDeusTailGlow");
|
||||
@@ -119,7 +119,7 @@ namespace CalamityMod.NPCs.AstrumDeus
|
||||
color41 *= (num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -264,7 +264,7 @@ namespace CalamityMod.NPCs.Bumblebirb
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
@@ -319,7 +319,7 @@ namespace CalamityMod.NPCs.Bumblebirb
|
||||
color39 *= 1f - num157;
|
||||
Vector2 vector42 = npc.Center + ((float)num160 / (float)num156 * MathHelper.TwoPi + npc.rotation).ToRotationVector2() * scaleFactor9 * num157 - Main.screenPosition;
|
||||
vector42 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector42 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector42 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector42, npc.frame, color39, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
@@ -329,7 +329,7 @@ namespace CalamityMod.NPCs.Bumblebirb
|
||||
color2 = npc.GetAlpha(color2);
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, (phase3 && calamityGlobalNPC.newAI[3] == 1f ? color2 : npc.GetAlpha(lightColor)), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
if (phase2)
|
||||
@@ -360,7 +360,7 @@ namespace CalamityMod.NPCs.Bumblebirb
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
|
||||
@@ -372,7 +372,7 @@ namespace CalamityMod.NPCs.Bumblebirb
|
||||
color42 *= 1f - num157;
|
||||
Vector2 vector45 = npc.Center + ((float)num164 / (float)num156 * MathHelper.TwoPi + npc.rotation).ToRotationVector2() * scaleFactor9 * num157 - Main.screenPosition;
|
||||
vector45 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector45 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector45 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector45, npc.frame, color42, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -344,14 +344,14 @@ namespace CalamityMod.NPCs.Bumblebirb
|
||||
color38 *= (num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
return false;
|
||||
|
||||
@@ -100,14 +100,14 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color38 *= (num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Calamitas/CalamitasGlow");
|
||||
@@ -122,7 +122,7 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color41 *= (num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -98,14 +98,14 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Calamitas/CalamitasRunGlow");
|
||||
@@ -120,7 +120,7 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -98,14 +98,14 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Calamitas/CalamitasRun2Glow");
|
||||
@@ -120,7 +120,7 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -117,14 +117,14 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Calamitas/CalamitasRun3Glow");
|
||||
@@ -139,7 +139,7 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -76,14 +76,14 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture.Width, (float)(texture.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture.Width, (float)(texture.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture = ModContent.GetTexture("CalamityMod/NPCs/Calamitas/LifeSeekerGlow");
|
||||
@@ -98,7 +98,7 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture.Width, (float)(texture.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -173,14 +173,14 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
afterImageColor *= (afterImageAmt - a) / 15f;
|
||||
Vector2 afterimagePos = npc.oldPos[a] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
afterimagePos -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
afterimagePos += origin * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
afterimagePos += origin * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, afterimagePos, npc.frame, afterImageColor, npc.rotation, origin, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 drawPos = npc.Center - Main.screenPosition;
|
||||
drawPos -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
drawPos += origin * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
drawPos += origin * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, drawPos, npc.frame, npc.GetAlpha(lightColor), npc.rotation, origin, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture = ModContent.GetTexture("CalamityMod/NPCs/Calamitas/SoulSeekerGlow");
|
||||
@@ -195,7 +195,7 @@ namespace CalamityMod.NPCs.Calamitas
|
||||
glowColor *= (afterImageAmt - a) / 15f;
|
||||
Vector2 afterimagePos = npc.oldPos[a] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
afterimagePos -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
afterimagePos += origin * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
afterimagePos += origin * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, afterimagePos, npc.frame, glowColor, npc.rotation, origin, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.CalPlayer;
|
||||
using CalamityMod.Dusts;
|
||||
@@ -187,6 +188,20 @@ namespace CalamityMod.NPCs
|
||||
}
|
||||
}
|
||||
|
||||
// Adjust slowing debuff immunity
|
||||
bool immuneToSlowingDebuffs = doSpiral;
|
||||
npc.buffImmune[ModContent.BuffType<ExoFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<GlacialState>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TemporalSadness>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<KamiDebuff>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<SilvaStun>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Eutrophication>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TimeSlow>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TeslaFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Vaporfied>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Slow] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Webbed] = immuneToSlowingDebuffs;
|
||||
|
||||
if (Main.netMode != NetmodeID.MultiplayerClient)
|
||||
{
|
||||
if (head)
|
||||
@@ -4590,6 +4605,20 @@ namespace CalamityMod.NPCs
|
||||
bool death = CalamityWorld.death || malice;
|
||||
Vector2 vector = npc.Center;
|
||||
|
||||
// Adjust slowing debuff immunity
|
||||
bool immuneToSlowingDebuffs = npc.ai[0] == 3f || npc.ai[0] == 3.1f || npc.ai[0] == 3.2f;
|
||||
npc.buffImmune[ModContent.BuffType<ExoFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<GlacialState>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TemporalSadness>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<KamiDebuff>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<SilvaStun>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Eutrophication>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TimeSlow>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TeslaFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Vaporfied>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Slow] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Webbed] = immuneToSlowingDebuffs;
|
||||
|
||||
// If target is outside the jungle for more than 3 seconds, enrage
|
||||
if (!player.ZoneJungle)
|
||||
{
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.NPCs.Abyss;
|
||||
using CalamityMod.NPCs.AcidRain;
|
||||
@@ -2661,6 +2663,20 @@ namespace CalamityMod.NPCs
|
||||
if (Main.player[npc.target].dead)
|
||||
npc.ai[0] = 5f;
|
||||
|
||||
// Adjust slowing debuff immunity
|
||||
bool immuneToSlowingDebuffs = npc.ai[0] == 0f;
|
||||
npc.buffImmune[ModContent.BuffType<ExoFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<GlacialState>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TemporalSadness>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<KamiDebuff>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<SilvaStun>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Eutrophication>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TimeSlow>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TeslaFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Vaporfied>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Slow] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Webbed] = immuneToSlowingDebuffs;
|
||||
|
||||
if (npc.ai[0] == 5f)
|
||||
{
|
||||
npc.velocity.Y *= 0.98f;
|
||||
@@ -7199,8 +7215,22 @@ namespace CalamityMod.NPCs
|
||||
Main.PlaySound(SoundID.Roar, (int)npc.position.X, (int)npc.position.Y, 0, 1f, 0f);
|
||||
}
|
||||
|
||||
// Float near player
|
||||
if (npc.ai[1] == 0f || npc.ai[1] == 4f)
|
||||
// Adjust slowing debuff immunity
|
||||
bool immuneToSlowingDebuffs = npc.ai[1] == 5f;
|
||||
npc.buffImmune[ModContent.BuffType<ExoFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<GlacialState>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TemporalSadness>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<KamiDebuff>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<SilvaStun>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Eutrophication>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TimeSlow>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TeslaFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Vaporfied>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Slow] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Webbed] = immuneToSlowingDebuffs;
|
||||
|
||||
// Float near player
|
||||
if (npc.ai[1] == 0f || npc.ai[1] == 4f)
|
||||
{
|
||||
// Start other phases if arms are dead, start with spinning phase
|
||||
if (allArmsDead)
|
||||
|
||||
@@ -120,14 +120,14 @@ namespace CalamityMod.NPCs.CeaselessVoid
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/CeaselessVoid/CeaselessVoidGlow");
|
||||
@@ -142,7 +142,7 @@ namespace CalamityMod.NPCs.CeaselessVoid
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -199,7 +199,7 @@ namespace CalamityMod.NPCs.CeaselessVoid
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
|
||||
if (CalamityConfig.Instance.Afterimages)
|
||||
{
|
||||
@@ -211,7 +211,7 @@ namespace CalamityMod.NPCs.CeaselessVoid
|
||||
color38 *= (num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
@@ -232,7 +232,7 @@ namespace CalamityMod.NPCs.CeaselessVoid
|
||||
color41 *= (num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
Color color43 = color42;
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace CalamityMod.NPCs.Crabulon
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Crabulon/CrabShroomGlow");
|
||||
|
||||
@@ -625,7 +625,7 @@ namespace CalamityMod.NPCs.Crabulon
|
||||
Vector2 vector11 = new Vector2(Main.npcTexture[npc.type].Width / 2, Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2);
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(Main.npcTexture[npc.type].Width, Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
Color color37 = Color.Lerp(Color.White, Color.Cyan, 0.5f);
|
||||
|
||||
if (npc.ai[0] > 2f)
|
||||
@@ -633,7 +633,7 @@ namespace CalamityMod.NPCs.Crabulon
|
||||
vector11 = new Vector2(textureAttack.Width / 2, textureAttack.Height / 2);
|
||||
vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(textureAttack.Width, textureAttack.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
|
||||
spriteBatch.Draw(textureAttack, vector43, npc.frame, npc.GetAlpha(drawColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
@@ -644,7 +644,7 @@ namespace CalamityMod.NPCs.Crabulon
|
||||
vector11 = new Vector2(texture.Width / 2, texture.Height / 2);
|
||||
vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
|
||||
spriteBatch.Draw(texture, vector43, npc.frame, npc.GetAlpha(drawColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
|
||||
@@ -241,14 +241,14 @@ namespace CalamityMod.NPCs.Crags
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture.Width, (float)(texture.Height)) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture.Width, (float)(texture.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture = ModContent.GetTexture("CalamityMod/NPCs/Crags/SoulSlurperGlow");
|
||||
@@ -263,7 +263,7 @@ namespace CalamityMod.NPCs.Crags
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture.Width, (float)(texture.Height)) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, npc.spriteDirection == 1 ? SpriteEffects.None : SpriteEffects.FlipHorizontally, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1009,7 +1009,7 @@ namespace CalamityMod.NPCs.Cryogen
|
||||
Vector2 origin = new Vector2(Main.npcTexture[npc.type].Width / 2, Main.npcTexture[npc.type].Height / Main.npcFrameCount[npc.type] / 2);
|
||||
Vector2 drawPos = npc.Center - Main.screenPosition;
|
||||
drawPos -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
drawPos += origin * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
drawPos += origin * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, drawPos, npc.frame, npc.GetAlpha(drawColor), npc.rotation, origin, npc.scale, spriteEffects, 0f);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -180,7 +180,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/DevourerofGods/DevourerofGodsBodyGlow");
|
||||
|
||||
@@ -154,7 +154,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/DevourerofGods/DevourerofGodsBody2Glow");
|
||||
|
||||
@@ -200,7 +200,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
if (!npc.dontTakeDamage)
|
||||
|
||||
@@ -877,7 +877,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/DevourerofGods/DevourerofGodsHeadGlow");
|
||||
|
||||
@@ -320,7 +320,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/DevourerofGods/DevourerofGodsHead2Glow");
|
||||
|
||||
@@ -1173,7 +1173,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
if (!npc.dontTakeDamage)
|
||||
|
||||
@@ -163,7 +163,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/DevourerofGods/DevourerofGodsTailGlow");
|
||||
|
||||
@@ -151,7 +151,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/DevourerofGods/DevourerofGodsTail2Glow");
|
||||
|
||||
@@ -196,7 +196,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
if (!npc.dontTakeDamage)
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Particles;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
@@ -17,6 +18,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
{
|
||||
// Whether the body is venting heat or not, it is vulnerable to damage during venting
|
||||
private bool vulnerable = false;
|
||||
public ThanatosSmokeParticleSet SmokeDrawer = new ThanatosSmokeParticleSet(-1, 4, 0f, 16f, 1.5f);
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
@@ -29,8 +31,8 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
npc.Calamity().canBreakPlayerDefense = true;
|
||||
npc.npcSlots = 5f;
|
||||
npc.GetNPCDamage();
|
||||
npc.width = 148;
|
||||
npc.height = 98;
|
||||
npc.width = 88;
|
||||
npc.height = 88;
|
||||
npc.defense = 100;
|
||||
npc.DR_NERD(0.99f);
|
||||
npc.Calamity().unbreakableDR = true;
|
||||
@@ -323,25 +325,28 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
npc.Calamity().unbreakableDR = !vulnerable;
|
||||
|
||||
// Vent noise and steam
|
||||
SmokeDrawer.ParticleSpawnRate = 9999999;
|
||||
if (vulnerable)
|
||||
{
|
||||
// Noise
|
||||
float volume = calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.Charge ? 0.25f : 1f;
|
||||
if (npc.localAI[0] == 0f)
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/ThanatosVent"), npc.Center);
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/ThanatosVent").WithVolume(volume), npc.Center);
|
||||
|
||||
// Steam
|
||||
float maxSteamTime = 180f;
|
||||
int maxGores = 4;
|
||||
npc.localAI[0] += 1f;
|
||||
if (npc.localAI[0] < maxSteamTime)
|
||||
{
|
||||
npc.localAI[0] += 1f;
|
||||
int goreAmt = maxGores - (int)Math.Round(npc.localAI[0] / 60f);
|
||||
CalamityUtils.ExplosionGores(npc.Center, goreAmt, true, npc.velocity);
|
||||
SmokeDrawer.BaseMoveRotation = npc.rotation - MathHelper.PiOver2;
|
||||
SmokeDrawer.ParticleSpawnRate = 3;
|
||||
}
|
||||
}
|
||||
else
|
||||
npc.localAI[0] = 0f;
|
||||
|
||||
SmokeDrawer.Update();
|
||||
|
||||
Vector2 vector18 = new Vector2(npc.position.X + npc.width * 0.5f, npc.position.Y + npc.height * 0.5f);
|
||||
float num191 = Main.player[npc.target].position.X + (Main.player[npc.target].width / 2);
|
||||
float num192 = Main.player[npc.target].position.Y + (Main.player[npc.target].height / 2);
|
||||
@@ -413,22 +418,22 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
// Swap between venting and non-venting frames
|
||||
CalamityGlobalNPC calamityGlobalNPC_Head = Main.npc[(int)npc.ai[2]].Calamity();
|
||||
bool shootTrackingLasers = (calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.Charge || calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.UndergroundLaserBarrage) && calamityGlobalNPC_Head.newAI[2] > 0f;
|
||||
npc.frameCounter += 1D;
|
||||
if (shootTrackingLasers)
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.Calamity().newAI[1] == 0f)
|
||||
if (npc.Calamity().newAI[1] == 0f && npc.Calamity().newAI[0] > 0f)
|
||||
{
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y += frameHeight;
|
||||
npc.frameCounter = 0D;
|
||||
}
|
||||
if (npc.frame.Y >= frameHeight * Main.npcFrameCount[npc.type])
|
||||
npc.frame.Y = frameHeight * Main.npcFrameCount[npc.type];
|
||||
int finalFrame = Main.npcFrameCount[npc.type] - 1;
|
||||
if (npc.frame.Y > frameHeight * finalFrame)
|
||||
npc.frame.Y = frameHeight * finalFrame;
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y -= frameHeight;
|
||||
@@ -440,7 +445,6 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y -= frameHeight;
|
||||
@@ -451,7 +455,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
}
|
||||
}
|
||||
|
||||
public override void PostDraw(SpriteBatch spriteBatch, Color drawColor)
|
||||
public override bool PreDraw(SpriteBatch spriteBatch, Color drawColor)
|
||||
{
|
||||
SpriteEffects spriteEffects = SpriteEffects.None;
|
||||
if (npc.spriteDirection == 1)
|
||||
@@ -462,11 +466,14 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
|
||||
Vector2 center = npc.Center - Main.screenPosition;
|
||||
center -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
center += vector * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
center += vector * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, center, npc.frame, npc.GetAlpha(drawColor), npc.rotation, vector, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture = ModContent.GetTexture("CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosBody1Glow");
|
||||
spriteBatch.Draw(texture, center, npc.frame, Color.White * npc.Opacity, npc.rotation, vector, npc.scale, spriteEffects, 0f);
|
||||
SmokeDrawer.DrawSet(npc.Center);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override bool CheckActive() => false;
|
||||
@@ -514,7 +521,6 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
int duration = vulnerable ? 120 : 60;
|
||||
player.AddBuff(BuffID.Ichor, duration);
|
||||
player.AddBuff(BuffID.CursedInferno, duration);
|
||||
player.AddBuff(ModContent.BuffType<ExoFreeze>(), duration / 4);
|
||||
player.AddBuff(ModContent.BuffType<BrimstoneFlames>(), duration);
|
||||
player.AddBuff(ModContent.BuffType<Plague>(), duration);
|
||||
player.AddBuff(ModContent.BuffType<HolyFlames>(), duration);
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Particles;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
@@ -17,6 +18,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
{
|
||||
// Whether the body is venting heat or not, it is vulnerable to damage during venting
|
||||
private bool vulnerable = false;
|
||||
public ThanatosSmokeParticleSet SmokeDrawer = new ThanatosSmokeParticleSet(-1, 4, 0f, 16f, 1.5f);
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
@@ -29,8 +31,8 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
npc.Calamity().canBreakPlayerDefense = true;
|
||||
npc.npcSlots = 5f;
|
||||
npc.GetNPCDamage();
|
||||
npc.width = 136;
|
||||
npc.height = 100;
|
||||
npc.width = 90;
|
||||
npc.height = 90;
|
||||
npc.defense = 100;
|
||||
npc.DR_NERD(0.99f);
|
||||
npc.Calamity().unbreakableDR = true;
|
||||
@@ -323,25 +325,28 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
npc.Calamity().unbreakableDR = !vulnerable;
|
||||
|
||||
// Vent noise and steam
|
||||
SmokeDrawer.ParticleSpawnRate = 9999999;
|
||||
if (vulnerable)
|
||||
{
|
||||
// Noise
|
||||
float volume = calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.Charge ? 0.25f : 1f;
|
||||
if (npc.localAI[0] == 0f)
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/ThanatosVent"), npc.Center);
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/ThanatosVent").WithVolume(volume), npc.Center);
|
||||
|
||||
// Steam
|
||||
float maxSteamTime = 180f;
|
||||
int maxGores = 4;
|
||||
npc.localAI[0] += 1f;
|
||||
if (npc.localAI[0] < maxSteamTime)
|
||||
{
|
||||
npc.localAI[0] += 1f;
|
||||
int goreAmt = maxGores - (int)Math.Round(npc.localAI[0] / 60f);
|
||||
CalamityUtils.ExplosionGores(npc.Center, goreAmt, true, npc.velocity);
|
||||
SmokeDrawer.BaseMoveRotation = npc.rotation - MathHelper.PiOver2;
|
||||
SmokeDrawer.ParticleSpawnRate = 3;
|
||||
}
|
||||
}
|
||||
else
|
||||
npc.localAI[0] = 0f;
|
||||
|
||||
SmokeDrawer.Update();
|
||||
|
||||
Vector2 vector18 = new Vector2(npc.position.X + npc.width * 0.5f, npc.position.Y + npc.height * 0.5f);
|
||||
float num191 = Main.player[npc.target].position.X + (Main.player[npc.target].width / 2);
|
||||
float num192 = Main.player[npc.target].position.Y + (Main.player[npc.target].height / 2);
|
||||
@@ -413,22 +418,22 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
// Swap between venting and non-venting frames
|
||||
CalamityGlobalNPC calamityGlobalNPC_Head = Main.npc[(int)npc.ai[2]].Calamity();
|
||||
bool shootTrackingLasers = (calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.Charge || calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.UndergroundLaserBarrage) && calamityGlobalNPC_Head.newAI[2] > 0f;
|
||||
npc.frameCounter += 1D;
|
||||
if (shootTrackingLasers)
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.Calamity().newAI[1] == 0f)
|
||||
if (npc.Calamity().newAI[1] == 0f && npc.Calamity().newAI[0] > 0f)
|
||||
{
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y += frameHeight;
|
||||
npc.frameCounter = 0D;
|
||||
}
|
||||
if (npc.frame.Y >= frameHeight * Main.npcFrameCount[npc.type])
|
||||
npc.frame.Y = frameHeight * Main.npcFrameCount[npc.type];
|
||||
int finalFrame = Main.npcFrameCount[npc.type] - 1;
|
||||
if (npc.frame.Y > frameHeight * finalFrame)
|
||||
npc.frame.Y = frameHeight * finalFrame;
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y -= frameHeight;
|
||||
@@ -440,7 +445,6 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y -= frameHeight;
|
||||
@@ -451,7 +455,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
}
|
||||
}
|
||||
|
||||
public override void PostDraw(SpriteBatch spriteBatch, Color drawColor)
|
||||
public override bool PreDraw(SpriteBatch spriteBatch, Color drawColor)
|
||||
{
|
||||
SpriteEffects spriteEffects = SpriteEffects.None;
|
||||
if (npc.spriteDirection == 1)
|
||||
@@ -462,11 +466,14 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
|
||||
Vector2 center = npc.Center - Main.screenPosition;
|
||||
center -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
center += vector * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
center += vector * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, center, npc.frame, npc.GetAlpha(drawColor), npc.rotation, vector, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture = ModContent.GetTexture("CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosBody2Glow");
|
||||
spriteBatch.Draw(texture, center, npc.frame, Color.White * npc.Opacity, npc.rotation, vector, npc.scale, spriteEffects, 0f);
|
||||
SmokeDrawer.DrawSet(npc.Center);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override bool CheckActive() => false;
|
||||
@@ -514,7 +521,6 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
int duration = vulnerable ? 120 : 60;
|
||||
player.AddBuff(BuffID.Ichor, duration);
|
||||
player.AddBuff(BuffID.CursedInferno, duration);
|
||||
player.AddBuff(ModContent.BuffType<ExoFreeze>(), duration / 4);
|
||||
player.AddBuff(ModContent.BuffType<BrimstoneFlames>(), duration);
|
||||
player.AddBuff(ModContent.BuffType<Plague>(), duration);
|
||||
player.AddBuff(ModContent.BuffType<HolyFlames>(), duration);
|
||||
|
||||
@@ -84,8 +84,8 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
npc.Calamity().canBreakPlayerDefense = true;
|
||||
npc.npcSlots = 5f;
|
||||
npc.GetNPCDamage();
|
||||
npc.width = 104;
|
||||
npc.height = 174;
|
||||
npc.width = 164;
|
||||
npc.height = 164;
|
||||
npc.defense = 80;
|
||||
npc.DR_NERD(0.99f);
|
||||
npc.Calamity().unbreakableDR = true;
|
||||
@@ -312,7 +312,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
|
||||
// Phase gate values
|
||||
float velocityAdjustTime = 20f;
|
||||
float speedUpTime = 300f;
|
||||
float speedUpTime = 480f;
|
||||
float slowDownTime = 120f;
|
||||
float chargePhaseGateValue = speedUpTime + slowDownTime;
|
||||
|
||||
@@ -353,18 +353,19 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
float laserBarrageLocationDistance = turnDistance * 5f;
|
||||
|
||||
// Velocity and turn speed values
|
||||
float baseVelocity = malice ? 12f : death ? 11f : revenge ? 10.5f : expertMode ? 10f : 9f;
|
||||
float turnDegrees = malice ? 1.33f : death ? 1.22f : revenge ? 1.17f : expertMode ? 1.11f : 1f;
|
||||
float baseVelocityMult = malice ? 1.3f : death ? 1.2f : revenge ? 1.15f : expertMode ? 1.1f : 1f;
|
||||
float baseVelocity = 7f * baseVelocityMult;
|
||||
float turnDegrees = baseVelocity * 0.11f;
|
||||
if (berserk)
|
||||
{
|
||||
baseVelocity *= 1.2f;
|
||||
turnDegrees *= 1.2f;
|
||||
}
|
||||
float turnSpeed = MathHelper.ToRadians(turnDegrees);
|
||||
float chargeVelocityMult = MathHelper.Lerp(1f, 2f, chargeVelocityScalar);
|
||||
float chargeTurnSpeedMult = MathHelper.Lerp(1f, 2f, chargeVelocityScalar);
|
||||
float laserBarragePhaseVelocityMult = MathHelper.Lerp(1f, 2f, chargeVelocityScalar);
|
||||
float laserBarragePhaseTurnSpeedMult = MathHelper.Lerp(1f, 8f, chargeVelocityScalar);
|
||||
float chargeVelocityMult = MathHelper.Lerp(1f, 1.5f, chargeVelocityScalar);
|
||||
float chargeTurnSpeedMult = MathHelper.Lerp(1f, 1.5f, chargeVelocityScalar);
|
||||
float laserBarragePhaseVelocityMult = MathHelper.Lerp(1f, 1.5f, chargeVelocityScalar);
|
||||
float laserBarragePhaseTurnSpeedMult = MathHelper.Lerp(1f, 3f, chargeVelocityScalar);
|
||||
float deathrayVelocityMult = MathHelper.Lerp(1f, 4f, chargeVelocityScalar);
|
||||
float deathrayTurnSpeedMult = MathHelper.Lerp(1f, 4f, chargeVelocityScalar);
|
||||
|
||||
@@ -372,6 +373,9 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
float chargeVelocityScalarIncrement = 1f / speedUpTime;
|
||||
float chargeVelocityScalarDecrement = 1f / slowDownTime;
|
||||
|
||||
// Scalar to use during deathray phase
|
||||
float deathrayVelocityScalarIncrement = 1f / deathrayDuration;
|
||||
|
||||
// Scalar to use during laser barrage, passive and immune phases
|
||||
float laserBarrageVelocityScalarIncrement = 0.01f;
|
||||
float laserBarrageVelocityScalarDecrement = 1f / velocityAdjustTime;
|
||||
@@ -567,7 +571,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
// Use a lerp to smoothly scale up velocity and turn speed
|
||||
if (calamityGlobalNPC.newAI[3] == 0f)
|
||||
{
|
||||
chargeVelocityScalar += chargeVelocityScalarIncrement;
|
||||
chargeVelocityScalar += deathrayVelocityScalarIncrement;
|
||||
if (chargeVelocityScalar >= 1f)
|
||||
{
|
||||
chargeVelocityScalar = 1f;
|
||||
@@ -579,7 +583,8 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
}
|
||||
else
|
||||
{
|
||||
chargeVelocityScalar -= chargeVelocityScalarDecrement;
|
||||
// Reduce velocity scalar very quickly
|
||||
chargeVelocityScalar -= deathrayVelocityScalarIncrement * 5f;
|
||||
if (chargeVelocityScalar < 0f)
|
||||
chargeVelocityScalar = 0f;
|
||||
}
|
||||
@@ -665,10 +670,10 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
// Steam
|
||||
float maxSteamTime = 180f;
|
||||
int maxGores = 4;
|
||||
if (npc.localAI[1] < maxSteamTime)
|
||||
npc.localAI[0] += 1f;
|
||||
if (npc.localAI[0] < maxSteamTime && npc.localAI[0] % 18f == 0f)
|
||||
{
|
||||
npc.localAI[1] += 1f;
|
||||
int goreAmt = maxGores - (int)Math.Round(npc.localAI[1] / 60f);
|
||||
int goreAmt = maxGores - (int)Math.Round(npc.localAI[0] / 60f);
|
||||
CalamityUtils.ExplosionGores(npc.Center, goreAmt, true, npc.velocity);
|
||||
}
|
||||
}
|
||||
@@ -732,9 +737,9 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
public override void FindFrame(int frameHeight) // 5 total frames
|
||||
{
|
||||
// Swap between venting and non-venting frames
|
||||
npc.frameCounter += 1D;
|
||||
if (AIState == (float)Phase.Charge || AIState == (float)Phase.UndergroundLaserBarrage)
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y -= frameHeight;
|
||||
@@ -745,14 +750,14 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y += frameHeight;
|
||||
npc.frameCounter = 0D;
|
||||
}
|
||||
if (npc.frame.Y >= frameHeight * Main.npcFrameCount[npc.type])
|
||||
npc.frame.Y = frameHeight * Main.npcFrameCount[npc.type];
|
||||
int finalFrame = Main.npcFrameCount[npc.type] - 1;
|
||||
if (npc.frame.Y >= frameHeight * finalFrame)
|
||||
npc.frame.Y = frameHeight * finalFrame;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -767,7 +772,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
|
||||
Vector2 center = npc.Center - Main.screenPosition;
|
||||
center -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
center += vector * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
center += vector * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, center, npc.frame, npc.GetAlpha(drawColor), npc.rotation, vector, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture = ModContent.GetTexture("CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosHeadGlow");
|
||||
|
||||
@@ -29,8 +29,8 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
npc.Calamity().canBreakPlayerDefense = true;
|
||||
npc.npcSlots = 5f;
|
||||
npc.GetNPCDamage();
|
||||
npc.width = 84;
|
||||
npc.height = 118;
|
||||
npc.width = 76;
|
||||
npc.height = 110;
|
||||
npc.defense = 120;
|
||||
npc.DR_NERD(0.99f);
|
||||
npc.Calamity().unbreakableDR = true;
|
||||
@@ -326,15 +326,16 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
if (vulnerable)
|
||||
{
|
||||
// Noise
|
||||
float volume = calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.Charge ? 0.25f : 1f;
|
||||
if (npc.localAI[0] == 0f)
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/ThanatosVent"), npc.Center);
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/ThanatosVent").WithVolume(volume), npc.Center);
|
||||
|
||||
// Steam
|
||||
float maxSteamTime = 180f;
|
||||
int maxGores = 4;
|
||||
if (npc.localAI[0] < maxSteamTime)
|
||||
npc.localAI[0] += 1f;
|
||||
if (npc.localAI[0] < maxSteamTime && npc.localAI[0] % 18f == 0f)
|
||||
{
|
||||
npc.localAI[0] += 1f;
|
||||
int goreAmt = maxGores - (int)Math.Round(npc.localAI[0] / 60f);
|
||||
CalamityUtils.ExplosionGores(npc.Center, goreAmt, true, npc.velocity);
|
||||
}
|
||||
@@ -413,22 +414,22 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
// Swap between venting and non-venting frames
|
||||
CalamityGlobalNPC calamityGlobalNPC_Head = Main.npc[(int)npc.ai[2]].Calamity();
|
||||
bool shootTrackingLasers = (calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.Charge || calamityGlobalNPC_Head.newAI[0] == (float)ThanatosHead.Phase.UndergroundLaserBarrage) && calamityGlobalNPC_Head.newAI[2] > 0f;
|
||||
npc.frameCounter += 1D;
|
||||
if (shootTrackingLasers)
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.Calamity().newAI[1] == 0f)
|
||||
if (npc.Calamity().newAI[1] == 0f && npc.Calamity().newAI[0] > 0f)
|
||||
{
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y += frameHeight;
|
||||
npc.frameCounter = 0D;
|
||||
}
|
||||
if (npc.frame.Y >= frameHeight * Main.npcFrameCount[npc.type])
|
||||
npc.frame.Y = frameHeight * Main.npcFrameCount[npc.type];
|
||||
int finalFrame = Main.npcFrameCount[npc.type] - 1;
|
||||
if (npc.frame.Y > frameHeight * finalFrame)
|
||||
npc.frame.Y = frameHeight * finalFrame;
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y -= frameHeight;
|
||||
@@ -440,7 +441,6 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.frameCounter += 1D;
|
||||
if (npc.frameCounter >= 12D)
|
||||
{
|
||||
npc.frame.Y -= frameHeight;
|
||||
@@ -451,7 +451,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
}
|
||||
}
|
||||
|
||||
public override void PostDraw(SpriteBatch spriteBatch, Color drawColor)
|
||||
public override bool PreDraw(SpriteBatch spriteBatch, Color drawColor)
|
||||
{
|
||||
SpriteEffects spriteEffects = SpriteEffects.None;
|
||||
if (npc.spriteDirection == 1)
|
||||
@@ -462,11 +462,13 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
|
||||
Vector2 center = npc.Center - Main.screenPosition;
|
||||
center -= new Vector2(texture.Width, texture.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
center += vector * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
center += vector * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture, center, npc.frame, npc.GetAlpha(drawColor), npc.rotation, vector, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture = ModContent.GetTexture("CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosTailGlow");
|
||||
spriteBatch.Draw(texture, center, npc.frame, Color.White * npc.Opacity, npc.rotation, vector, npc.scale, spriteEffects, 0f);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override bool CheckActive() => false;
|
||||
@@ -515,7 +517,6 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
int duration = vulnerable ? 60 : 30;
|
||||
player.AddBuff(BuffID.Ichor, duration);
|
||||
player.AddBuff(BuffID.CursedInferno, duration);
|
||||
player.AddBuff(ModContent.BuffType<ExoFreeze>(), duration / 4);
|
||||
player.AddBuff(ModContent.BuffType<BrimstoneFlames>(), duration);
|
||||
player.AddBuff(ModContent.BuffType<Plague>(), duration);
|
||||
player.AddBuff(ModContent.BuffType<HolyFlames>(), duration);
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Accessories;
|
||||
using CalamityMod.Items.Armor.Vanity;
|
||||
using CalamityMod.Items.LoreItems;
|
||||
@@ -169,7 +171,21 @@ namespace CalamityMod.NPCs.Leviathan
|
||||
|
||||
npc.dontTakeDamage = spawnAnimation;
|
||||
|
||||
if (!player.active || player.dead || Vector2.Distance(player.Center, vector) > 5600f)
|
||||
// Adjust slowing debuff immunity
|
||||
bool immuneToSlowingDebuffs = npc.ai[0] == 2f;
|
||||
npc.buffImmune[ModContent.BuffType<ExoFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<GlacialState>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TemporalSadness>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<KamiDebuff>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<SilvaStun>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Eutrophication>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TimeSlow>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TeslaFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Vaporfied>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Slow] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Webbed] = immuneToSlowingDebuffs;
|
||||
|
||||
if (!player.active || player.dead || Vector2.Distance(player.Center, vector) > 5600f)
|
||||
{
|
||||
npc.TargetClosest(false);
|
||||
player = Main.player[npc.target];
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace CalamityMod.NPCs.Leviathan
|
||||
|
||||
Vector2 drawPos = npc.Center - Main.screenPosition;
|
||||
drawPos -= new Vector2(drawTex.Width, drawTex.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
drawPos += origin * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
drawPos += origin * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(drawTex, drawPos, npc.frame, npc.GetAlpha(lightColor), npc.rotation, origin, npc.scale, spriteEffects, 0f);
|
||||
|
||||
drawTex = ModContent.GetTexture("CalamityMod/NPCs/Leviathan/LeviathanStartGlow");
|
||||
|
||||
@@ -62,14 +62,14 @@ namespace CalamityMod.NPCs.NormalNPCs
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/NormalNPCs/PlagueBeeGlow");
|
||||
@@ -84,7 +84,7 @@ namespace CalamityMod.NPCs.NormalNPCs
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -61,14 +61,14 @@ namespace CalamityMod.NPCs.NormalNPCs
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/NormalNPCs/PlagueBeeGlow");
|
||||
@@ -83,7 +83,7 @@ namespace CalamityMod.NPCs.NormalNPCs
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -232,7 +232,7 @@ namespace CalamityMod.NPCs.OldDuke
|
||||
color38 *= (num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
@@ -285,7 +285,7 @@ namespace CalamityMod.NPCs.OldDuke
|
||||
color39 *= 1f - num157;
|
||||
Vector2 vector42 = npc.Center + (num160 / (float)num156 * MathHelper.TwoPi + npc.rotation).ToRotationVector2() * scaleFactor9 * num157 - Main.screenPosition;
|
||||
vector42 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector42 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector42 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector42, npc.frame, color39, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
@@ -295,7 +295,7 @@ namespace CalamityMod.NPCs.OldDuke
|
||||
color2 = npc.GetAlpha(color2);
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, (npc.ai[0] > 9f ? color2 : npc.GetAlpha(lightColor)), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
if (npc.ai[0] >= 4f && npc.Calamity().newAI[1] != 1f)
|
||||
@@ -340,7 +340,7 @@ namespace CalamityMod.NPCs.OldDuke
|
||||
color41 *= (num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
|
||||
@@ -352,7 +352,7 @@ namespace CalamityMod.NPCs.OldDuke
|
||||
color42 *= 1f - num157;
|
||||
Vector2 vector45 = npc.Center + (num164 / (float)num156 * MathHelper.TwoPi + npc.rotation).ToRotationVector2() * scaleFactor9 * num157 - Main.screenPosition;
|
||||
vector45 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector45 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector45 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector45, npc.frame, color42, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -183,14 +183,14 @@ namespace CalamityMod.NPCs.OldDuke
|
||||
color38 *= (num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2(npc.width, npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
return false;
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = npc.localAI[3] == 1f ? ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorBodyLargeAltGlow") : ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorBodyLargeGlow");
|
||||
|
||||
@@ -171,7 +171,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorBodyMediumGlow");
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorBodySmallGlow");
|
||||
|
||||
@@ -50,7 +50,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorCystGlow");
|
||||
|
||||
@@ -502,7 +502,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorHeadLargeGlow");
|
||||
|
||||
@@ -383,7 +383,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorHeadMediumGlow");
|
||||
|
||||
@@ -437,7 +437,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorHeadSmallGlow");
|
||||
|
||||
@@ -413,7 +413,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorHiveGlow");
|
||||
|
||||
@@ -81,7 +81,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorTailLargeGlow");
|
||||
|
||||
@@ -138,7 +138,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorTailMediumGlow");
|
||||
|
||||
@@ -82,7 +82,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height)) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/Perforator/PerforatorTailSmallGlow");
|
||||
|
||||
@@ -219,14 +219,14 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/NormalNPCs/PlagueBeeGlow");
|
||||
@@ -241,7 +241,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -112,14 +112,14 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/NormalNPCs/PlagueBeeGlow");
|
||||
@@ -134,7 +134,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -151,14 +151,14 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
|
||||
color38 *= (float)(num153 - num155) / 15f;
|
||||
Vector2 vector41 = npc.oldPos[num155] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector41 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector41 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector41, npc.frame, color38, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
texture2D15 = ModContent.GetTexture("CalamityMod/NPCs/PlaguebringerGoliath/PlagueHomingMissileGlow");
|
||||
@@ -173,7 +173,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
|
||||
color41 *= (float)(num153 - num163) / 15f;
|
||||
Vector2 vector44 = npc.oldPos[num163] + new Vector2((float)npc.width, (float)npc.height) / 2f - Main.screenPosition;
|
||||
vector44 -= new Vector2((float)texture2D15.Width, (float)(texture2D15.Height / Main.npcFrameCount[npc.type])) * npc.scale / 2f;
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector44 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
spriteBatch.Draw(texture2D15, vector44, npc.frame, color41, npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -143,7 +143,7 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
|
||||
Vector2 vector11 = new Vector2(Main.npcTexture[npc.type].Width / 2, Main.npcTexture[npc.type].Height / 2);
|
||||
Vector2 vector43 = npc.Center - Main.screenPosition;
|
||||
vector43 -= new Vector2(texture2D15.Width, texture2D15.Height / Main.npcFrameCount[npc.type]) * npc.scale / 2f;
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, 4f + npc.gfxOffY);
|
||||
vector43 += vector11 * npc.scale + new Vector2(0f, npc.gfxOffY);
|
||||
|
||||
spriteBatch.Draw(texture2D15, vector43, npc.frame, npc.GetAlpha(lightColor), npc.rotation, vector11, npc.scale, spriteEffects, 0f);
|
||||
|
||||
|
||||
@@ -127,8 +127,22 @@ namespace CalamityMod.NPCs.PlaguebringerGoliath
|
||||
bool revenge = CalamityWorld.revenge || malice;
|
||||
bool expertMode = Main.expertMode || malice;
|
||||
|
||||
// Light
|
||||
Lighting.AddLight((int)((npc.position.X + (npc.width / 2)) / 16f), (int)((npc.position.Y + (npc.height / 2)) / 16f), 0.3f, 0.7f, 0f);
|
||||
// Adjust slowing debuff immunity
|
||||
bool immuneToSlowingDebuffs = npc.ai[0] == 0f || npc.ai[0] == 4f;
|
||||
npc.buffImmune[ModContent.BuffType<ExoFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<GlacialState>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TemporalSadness>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<KamiDebuff>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<SilvaStun>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Eutrophication>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TimeSlow>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<TeslaFreeze>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[ModContent.BuffType<Vaporfied>()] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Slow] = immuneToSlowingDebuffs;
|
||||
npc.buffImmune[BuffID.Webbed] = immuneToSlowingDebuffs;
|
||||
|
||||
// Light
|
||||
Lighting.AddLight((int)((npc.position.X + (npc.width / 2)) / 16f), (int)((npc.position.Y + (npc.height / 2)) / 16f), 0.3f, 0.7f, 0f);
|
||||
|
||||
// Show message
|
||||
if (!halfLife && phase3 && expertMode)
|
||||
|
||||
Loaded 100 of 143 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user