Merge branch 'master' into draedon-summoner
This commit is contained in:
commit
555a92c38b
56 files changed
+577
-372
No files matched your search
@@ -73,19 +73,7 @@ namespace CalamityMod.Items.Weapons.Magic
|
||||
num80 = num72 / num80;
|
||||
}
|
||||
|
||||
int num130 = 7;
|
||||
if (Main.rand.NextBool(6))
|
||||
{
|
||||
num130++;
|
||||
}
|
||||
if (Main.rand.NextBool(7))
|
||||
{
|
||||
num130++;
|
||||
}
|
||||
if (Main.rand.NextBool(8))
|
||||
{
|
||||
num130++;
|
||||
}
|
||||
int num130 = 4;
|
||||
for (int num131 = 0; num131 < num130; num131++)
|
||||
{
|
||||
vector2 = new Vector2(player.position.X + (float)player.width * 0.5f + (float)(Main.rand.Next(201) * -(float)player.direction) + ((float)Main.mouseX + Main.screenPosition.X - player.position.X), player.MountedCenter.Y);
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.mana = 50;
|
||||
item.mana = 10;
|
||||
item.damage = Damage;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
item.width = 32;
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 5;
|
||||
item.mana = 9;
|
||||
item.mana = 10;
|
||||
item.width = 40;
|
||||
item.height = 40;
|
||||
item.useTime = item.useAnimation = 35;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 35;
|
||||
item.mana = 15;
|
||||
item.mana = 10;
|
||||
item.width = 48;
|
||||
item.height = 56;
|
||||
item.useTime = item.useAnimation = 20;
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 384;
|
||||
item.mana = 32;
|
||||
item.mana = 10;
|
||||
item.summon = true;
|
||||
item.sentry = true;
|
||||
item.width = 54;
|
||||
|
||||
@@ -24,7 +24,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 60;
|
||||
item.mana = 20;
|
||||
item.mana = 10;
|
||||
item.width = 52;
|
||||
item.height = 50;
|
||||
item.useTime = item.useAnimation = 25;
|
||||
|
||||
@@ -24,7 +24,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.noMelee = true;
|
||||
item.UseSound = SoundID.DD2_BetsyFlyingCircleAttack;
|
||||
item.summon = true;
|
||||
item.mana = 11;
|
||||
item.mana = 10;
|
||||
item.damage = 97;
|
||||
item.knockBack = 2f;
|
||||
item.autoReuse = true;
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.mana = 100;
|
||||
item.mana = 10;
|
||||
item.damage = 560;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
item.width = 74;
|
||||
|
||||
@@ -19,7 +19,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 70;
|
||||
item.mana = 12;
|
||||
item.mana = 10;
|
||||
item.width = item.height = 32;
|
||||
item.useTime = item.useAnimation = 25;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.noMelee = true;
|
||||
item.UseSound = SoundID.DD2_DarkMageHealImpact;
|
||||
item.summon = true;
|
||||
item.mana = 12;
|
||||
item.mana = 10;
|
||||
item.damage = 56;
|
||||
item.knockBack = 2f;
|
||||
item.autoReuse = true;
|
||||
|
||||
@@ -21,7 +21,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 42;
|
||||
item.mana = 12;
|
||||
item.mana = 10;
|
||||
item.width = item.height = 32;
|
||||
item.useTime = item.useAnimation = 25;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 160;
|
||||
item.mana = 30;
|
||||
item.mana = 10;
|
||||
item.width = 64;
|
||||
item.height = 62;
|
||||
item.useTime = item.useAnimation = 15;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.damage = 128;
|
||||
item.summon = true;
|
||||
item.sentry = true;
|
||||
item.mana = 25;
|
||||
item.mana = 10;
|
||||
item.width = 66;
|
||||
item.height = 68;
|
||||
item.useTime = item.useAnimation = 15;
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.mana = 100;
|
||||
item.mana = 10;
|
||||
item.damage = 1666;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
item.width = 58;
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.autoReuse = true;
|
||||
|
||||
item.knockBack = 4f;
|
||||
item.mana = 15;
|
||||
item.mana = 10;
|
||||
item.damage = 28;
|
||||
item.useTime = item.useAnimation = 25;
|
||||
item.shoot = ModContent.ProjectileType<ApexShark>();
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.noMelee = true;
|
||||
item.UseSound = SoundID.Item42;
|
||||
item.summon = true;
|
||||
item.mana = 16;
|
||||
item.mana = 10;
|
||||
item.damage = 173;
|
||||
item.knockBack = 3f;
|
||||
item.autoReuse = true;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 34;
|
||||
item.mana = 19;
|
||||
item.mana = 10;
|
||||
item.width = 52;
|
||||
item.height = 50;
|
||||
item.useTime = item.useAnimation = 25;
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 91;
|
||||
item.mana = 12;
|
||||
item.mana = 10;
|
||||
item.width = item.height = 32;
|
||||
item.useTime = item.useAnimation = 10;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 444;
|
||||
item.mana = 25;
|
||||
item.mana = 10;
|
||||
item.width = item.height = 56;
|
||||
item.useTime = item.useAnimation = 42;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
|
||||
@@ -29,7 +29,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.UseSound = SoundID.DD2_BetsyFlameBreath;
|
||||
|
||||
item.summon = true;
|
||||
item.mana = 100;
|
||||
item.mana = 10;
|
||||
item.damage = 145;
|
||||
item.knockBack = 4f;
|
||||
item.useTime = item.useAnimation = 10;
|
||||
|
||||
@@ -29,7 +29,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.UseSound = SoundID.Item44;
|
||||
|
||||
item.summon = true;
|
||||
item.mana = 60;
|
||||
item.mana = 10;
|
||||
item.damage = 160;
|
||||
item.knockBack = 3f;
|
||||
item.useTime = item.useAnimation = 10;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 26;
|
||||
item.mana = 13;
|
||||
item.mana = 10;
|
||||
item.width = 48;
|
||||
item.height = 56;
|
||||
item.useTime = item.useAnimation = 24;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = BaseDamage;
|
||||
item.mana = 15;
|
||||
item.mana = 10;
|
||||
item.width = 58;
|
||||
item.height = 58;
|
||||
item.useTime = 12;
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 666;
|
||||
item.mana = 15;
|
||||
item.mana = 10;
|
||||
item.width = 58;
|
||||
item.height = 58;
|
||||
item.useTime = item.useAnimation = 12;
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 333;
|
||||
item.mana = 12;
|
||||
item.mana = 10;
|
||||
item.width = item.height = 32;
|
||||
item.useTime = item.useAnimation = 10;
|
||||
item.useStyle = ItemUseStyleID.SwingThrow;
|
||||
|
||||
@@ -21,7 +21,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.damage = 156;
|
||||
item.summon = true;
|
||||
item.sentry = true;
|
||||
item.mana = 25;
|
||||
item.mana = 10;
|
||||
item.width = 26;
|
||||
item.height = 36;
|
||||
item.useTime = item.useAnimation = 15;
|
||||
|
||||
@@ -29,7 +29,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
item.UseSound = SoundID.DD2_EtherianPortalOpen;
|
||||
item.summon = true;
|
||||
|
||||
item.mana = 100;
|
||||
item.mana = 10;
|
||||
item.damage = 150;
|
||||
item.knockBack = 4f;
|
||||
item.useTime = item.useAnimation = 10;
|
||||
|
||||
+5
-6
@@ -5568,17 +5568,16 @@ namespace CalamityMod.NPCs
|
||||
if (npc.ai[0] == 8f || npc.ai[0] == 13f)
|
||||
rateOfRotation = 0.05f;
|
||||
|
||||
Vector2 playerCenter = player.Center;
|
||||
Vector2 rotationVector = player.Center - vector;
|
||||
if (calamityGlobalNPC.newAI[1] != 1f && !player.dead)
|
||||
{
|
||||
// Rotate to show direction of predictive charge
|
||||
Vector2 distanceVector = player.Center + player.velocity * 20f - vector;
|
||||
if (npc.ai[0] == 0f && !phase2)
|
||||
{
|
||||
if (npc.ai[3] < 6f)
|
||||
{
|
||||
rateOfRotation = 0.1f;
|
||||
playerCenter += Vector2.Normalize(distanceVector) * chargeVelocity;
|
||||
rotationVector = Vector2.Normalize(player.Center + player.velocity * 20f - vector) * chargeVelocity;
|
||||
}
|
||||
}
|
||||
else if (npc.ai[0] == 5f && !phase3)
|
||||
@@ -5586,7 +5585,7 @@ namespace CalamityMod.NPCs
|
||||
if (npc.ai[3] < 4f)
|
||||
{
|
||||
rateOfRotation = 0.1f;
|
||||
playerCenter += Vector2.Normalize(distanceVector) * chargeVelocity;
|
||||
rotationVector = Vector2.Normalize(player.Center + player.velocity * 20f - vector) * chargeVelocity;
|
||||
}
|
||||
}
|
||||
else if (npc.ai[0] == 10f)
|
||||
@@ -5594,12 +5593,12 @@ namespace CalamityMod.NPCs
|
||||
if (npc.ai[3] < 8f && npc.ai[3] != 1f && npc.ai[3] != 4f)
|
||||
{
|
||||
rateOfRotation = 0.1f;
|
||||
playerCenter += Vector2.Normalize(distanceVector) * chargeVelocity;
|
||||
rotationVector = Vector2.Normalize(player.Center + player.velocity * 20f - vector) * chargeVelocity;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
float num17 = (float)Math.Atan2(playerCenter.Y - vector.Y, playerCenter.X - vector.X);
|
||||
float num17 = (float)Math.Atan2(rotationVector.Y, rotationVector.X);
|
||||
if (npc.spriteDirection == 1)
|
||||
num17 += pie;
|
||||
if (num17 < 0f)
|
||||
|
||||
@@ -1100,7 +1100,7 @@ namespace CalamityMod.NPCs
|
||||
npc.buffImmune[BuffType<SulphuricPoisoning>()] = false;
|
||||
|
||||
// Sets certain vanilla NPCs and all town NPCs to be immune to most debuffs.
|
||||
if (DestroyerIDs.Contains(npc.type) || npc.type == NPCID.SkeletronHead || (EaterofWorldsIDs.Contains(npc.type) && BossRushEvent.BossRushActive) || npc.type == NPCID.DD2EterniaCrystal || npc.townNPC || npc.type == NPCID.SpikeBall || npc.type == NPCID.BlazingWheel)
|
||||
if (DestroyerIDs.Contains(npc.type) || npc.type == NPCID.SkeletronHead || (EaterofWorldsIDs.Contains(npc.type) && (BossRushEvent.BossRushActive || CalamityWorld.malice)) || npc.type == NPCID.DD2EterniaCrystal || npc.townNPC || npc.type == NPCID.SpikeBall || npc.type == NPCID.BlazingWheel)
|
||||
{
|
||||
for (int k = 0; k < npc.buffImmune.Length; k++)
|
||||
{
|
||||
|
||||
@@ -1,14 +1,10 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Potions;
|
||||
using CalamityMod.NPCs.ExoMechs.Thanatos;
|
||||
using CalamityMod.Particles;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System;
|
||||
using System.IO;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
@@ -52,9 +48,6 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
private int frameX = 0;
|
||||
private int frameY = 0;
|
||||
|
||||
// The exact frame the animation is currently on
|
||||
private int exactFrame = 0;
|
||||
|
||||
// Frame limit per animation, these are the specific frames where each animation ends
|
||||
private const int normalFrameLimit = 11;
|
||||
private const int firstStageDeathrayChargeFrameLimit = 23;
|
||||
@@ -330,7 +323,8 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
npc.rotation = npc.velocity.X * 0.003f;
|
||||
|
||||
// Light
|
||||
Lighting.AddLight(npc.Center, Main.DiscoR / 255f, Main.DiscoG / 255f, Main.DiscoB / 255f);
|
||||
float lightScale = 765f;
|
||||
Lighting.AddLight(npc.Center, Main.DiscoR / lightScale, Main.DiscoG / lightScale, Main.DiscoB / lightScale);
|
||||
|
||||
// Default vector to fly to
|
||||
Vector2 destination = SecondaryAIState == (float)SecondaryPhase.PassiveAndImmune ? new Vector2(player.Center.X, player.Center.Y - 800f) : AIState != (float)Phase.Deathrays ? new Vector2(player.Center.X, player.Center.Y - 450f) : player.Center;
|
||||
@@ -349,6 +343,10 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
// Distance from target
|
||||
float distanceFromTarget = Vector2.Distance(npc.Center, player.Center);
|
||||
|
||||
// Whether Ares should move to its spot or not
|
||||
float movementDistanceGateValue = 32f;
|
||||
bool moveToLocation = Vector2.Distance(npc.Center, destination) > movementDistanceGateValue;
|
||||
|
||||
// Gate values
|
||||
float deathrayPhaseGateValue = 900f;
|
||||
float deathrayDistanceGateValue = 480f;
|
||||
@@ -454,7 +452,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
// Fly above the target
|
||||
case (int)Phase.Normal:
|
||||
|
||||
if (!targetDead)
|
||||
if (!targetDead && moveToLocation)
|
||||
npc.SimpleFlyMovement(desiredVelocity, baseAcceleration);
|
||||
|
||||
if (berserk)
|
||||
@@ -495,11 +493,15 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
// Fire deathray telegraph beams
|
||||
if (calamityGlobalNPC.newAI[2] == 1f)
|
||||
{
|
||||
// Set frames to deathray charge up frames
|
||||
// Set frames to deathray charge up frames, which begin on frame 12
|
||||
// Reset the frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// X = 1 sets to frame 8
|
||||
frameX = 1;
|
||||
frameY = 5;
|
||||
exactFrame = 12;
|
||||
|
||||
// Y = 4 sets to frame 12
|
||||
frameY = 4;
|
||||
|
||||
if (Main.netMode != NetmodeID.MultiplayerClient)
|
||||
{
|
||||
@@ -562,36 +564,44 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 8
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > normalFrameLimit)
|
||||
frameX = frameY = exactFrame = 0;
|
||||
|
||||
// Reset the frames to frame 0
|
||||
if ((frameX * maxFramesY) + frameY > normalFrameLimit)
|
||||
frameX = frameY = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 8
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > finalStageDeathrayChargeFrameLimit)
|
||||
{
|
||||
frameX = 4;
|
||||
frameY = 5;
|
||||
exactFrame = secondStageDeathrayChargeFrameLimit + 1;
|
||||
}
|
||||
|
||||
// Reset the frames to frame 36, the start of the deathray firing animation loop
|
||||
if ((frameX * maxFramesY) + frameY > finalStageDeathrayChargeFrameLimit)
|
||||
frameX = frameY = 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Potions;
|
||||
using CalamityMod.NPCs.ExoMechs.Thanatos;
|
||||
using CalamityMod.Particles;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
@@ -40,9 +35,6 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
private int frameX = 0;
|
||||
private int frameY = 0;
|
||||
|
||||
// The exact frame the animation is currently on
|
||||
private int exactFrame = 0;
|
||||
|
||||
// Frame limit per animation, these are the specific frames where each animation ends
|
||||
private const int normalFrameLimit = 11;
|
||||
private const int firstStageGaussNukeChargeFrameLimit = 23;
|
||||
@@ -232,10 +224,11 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
Vector2 predictionVector = player.velocity * predictionAmt;
|
||||
Vector2 rotationVector = player.Center + predictionVector - npc.Center;
|
||||
|
||||
float projectileVelocity = 12f;
|
||||
float rateOfRotation = AIState == (int)Phase.GaussNuke ? 0.08f : 0.04f;
|
||||
Vector2 lookAt = player.Center + Vector2.Normalize(rotationVector);
|
||||
Vector2 lookAt = Vector2.Normalize(rotationVector) * projectileVelocity;
|
||||
|
||||
float rotation = (float)Math.Atan2(lookAt.Y - npc.Center.Y, lookAt.X - npc.Center.X);
|
||||
float rotation = (float)Math.Atan2(lookAt.Y, lookAt.X);
|
||||
if (npc.spriteDirection == 1)
|
||||
rotation += MathHelper.Pi;
|
||||
if (rotation < 0f)
|
||||
@@ -243,29 +236,22 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
if (rotation > MathHelper.TwoPi)
|
||||
rotation -= MathHelper.TwoPi;
|
||||
|
||||
if (npc.rotation < rotation)
|
||||
{
|
||||
if (rotation - npc.rotation > MathHelper.Pi)
|
||||
npc.rotation -= rateOfRotation;
|
||||
else
|
||||
npc.rotation += rateOfRotation;
|
||||
}
|
||||
if (npc.rotation > rotation)
|
||||
{
|
||||
if (npc.rotation - rotation > MathHelper.Pi)
|
||||
npc.rotation += rateOfRotation;
|
||||
else
|
||||
npc.rotation -= rateOfRotation;
|
||||
}
|
||||
npc.rotation = npc.rotation.AngleTowards(rotation, rateOfRotation);
|
||||
|
||||
if (npc.rotation > rotation - rateOfRotation && npc.rotation < rotation + rateOfRotation)
|
||||
npc.rotation = rotation;
|
||||
if (npc.rotation < 0f)
|
||||
npc.rotation += MathHelper.TwoPi;
|
||||
if (npc.rotation > MathHelper.TwoPi)
|
||||
npc.rotation -= MathHelper.TwoPi;
|
||||
if (npc.rotation > rotation - rateOfRotation && npc.rotation < rotation + rateOfRotation)
|
||||
npc.rotation = rotation;
|
||||
// Direction
|
||||
int direction = Math.Sign(player.Center.X - npc.Center.X);
|
||||
if (direction != 0)
|
||||
{
|
||||
if (calamityGlobalNPC.newAI[1] == 0f && calamityGlobalNPC.newAI[2] == 0f && direction != npc.direction)
|
||||
npc.rotation += MathHelper.Pi;
|
||||
|
||||
npc.direction = direction;
|
||||
|
||||
if (npc.spriteDirection != -npc.direction)
|
||||
npc.rotation += MathHelper.Pi;
|
||||
|
||||
npc.spriteDirection = -npc.direction;
|
||||
}
|
||||
|
||||
// Light
|
||||
Lighting.AddLight(npc.Center, 0.2f, 0.25f, 0.05f);
|
||||
@@ -284,8 +270,9 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
Vector2 desiredVelocity = Vector2.Normalize(destination - npc.Center) * baseVelocity;
|
||||
|
||||
// Distance from target
|
||||
float distanceFromTarget = Vector2.Distance(npc.Center, player.Center);
|
||||
// Whether Ares Nuke Arm should move to its spot or not
|
||||
float movementDistanceGateValue = 32f;
|
||||
bool moveToLocation = Vector2.Distance(npc.Center, destination) > movementDistanceGateValue;
|
||||
|
||||
// Gate values
|
||||
float gaussNukePhaseGateValue = 600f;
|
||||
@@ -322,29 +309,32 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
calamityGlobalNPC.newAI[2] += 1f;
|
||||
if (calamityGlobalNPC.newAI[2] < gaussNukeTelegraphDuration)
|
||||
{
|
||||
// Set frames to gauss nuke charge up frames, which begin on frame 12
|
||||
if (calamityGlobalNPC.newAI[2] == 1f)
|
||||
{
|
||||
// Set frames to gauss nuke charge up frames
|
||||
// Reset the frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// X = 1 sets to frame 12
|
||||
frameX = 1;
|
||||
|
||||
// Y = 0 sets to frame 12
|
||||
frameY = 0;
|
||||
exactFrame = 12;
|
||||
}
|
||||
|
||||
// Fire gauss nuke on frame 41
|
||||
if (exactFrame == 41 && calamityGlobalNPC.newAI[1] == 0f)
|
||||
if ((frameX * maxFramesY) + frameY == 41 && calamityGlobalNPC.newAI[1] == 0f)
|
||||
{
|
||||
calamityGlobalNPC.newAI[1] = 1f;
|
||||
|
||||
if (Main.netMode != NetmodeID.MultiplayerClient)
|
||||
{
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Item, "Sounds/Item/LargeWeaponFire"), npc.Center);
|
||||
float projectileVelocity = 12f;
|
||||
Vector2 gaussNukeVelocity = Vector2.Normalize(rotationVector) * projectileVelocity;
|
||||
int type = ModContent.ProjectileType<AresGaussNukeProjectile>();
|
||||
int damage = npc.GetProjectileDamage(type);
|
||||
float offset = 40f;
|
||||
Projectile.NewProjectile(npc.Center + Vector2.Normalize(gaussNukeVelocity) * offset, gaussNukeVelocity, type, damage, 0f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(npc.Center + Vector2.Normalize(gaussNukeVelocity) * offset, gaussNukeVelocity, type, damage, 0f, Main.myPlayer, 0f, player.Center.Y);
|
||||
|
||||
// Recoil
|
||||
npc.velocity -= gaussNukeVelocity;
|
||||
@@ -353,15 +343,19 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
else
|
||||
{
|
||||
// Set frames to gauss nuke reload frames, which begin on frame 48
|
||||
AIState = (float)Phase.Reload;
|
||||
calamityGlobalNPC.newAI[1] = 0f;
|
||||
calamityGlobalNPC.newAI[2] = 0f;
|
||||
|
||||
// Set frames to gauss nuke reload frames
|
||||
// Reset the frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// X = 1 sets to frame 48
|
||||
frameX = 4;
|
||||
|
||||
// Y = 0 sets to frame 48
|
||||
frameY = 0;
|
||||
exactFrame = 48;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -381,7 +375,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
|
||||
// Movement
|
||||
if (!targetDead)
|
||||
if (!targetDead && moveToLocation)
|
||||
npc.SimpleFlyMovement(desiredVelocity, baseAcceleration);
|
||||
}
|
||||
|
||||
@@ -397,32 +391,44 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 12
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > normalFrameLimit)
|
||||
frameX = frameY = exactFrame = 0;
|
||||
|
||||
// Reset the frames
|
||||
if ((frameX * maxFramesY) + frameY > normalFrameLimit)
|
||||
frameX = frameY = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 12
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > reloadFrameLimit)
|
||||
frameX = frameY = exactFrame = 0;
|
||||
|
||||
// Reset the frames to frame 0
|
||||
if ((frameX * maxFramesY) + frameY > reloadFrameLimit)
|
||||
frameX = frameY = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Potions;
|
||||
using CalamityMod.NPCs.ExoMechs.Thanatos;
|
||||
using CalamityMod.Particles;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
@@ -39,9 +34,6 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
private int frameX = 0;
|
||||
private int frameY = 0;
|
||||
|
||||
// The exact frame the animation is currently on
|
||||
private int exactFrame = 0;
|
||||
|
||||
// Frame limit per animation, these are the specific frames where each animation ends
|
||||
private const int normalFrameLimit = 11;
|
||||
private const int firstStageDeathrayChargeFrameLimit = 23;
|
||||
@@ -228,8 +220,9 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
// Rotate the cannon to look at the target while not firing the beam
|
||||
// Rotate the cannon to look in the direction it will fire only while it's charging or while it's firing
|
||||
// Rotation
|
||||
bool horizontalLaserSweep = calamityGlobalNPC.newAI[3] == 0f;
|
||||
float rateOfRotation = AIState == (int)Phase.Deathray ? 0.08f : 0.04f;
|
||||
Vector2 lookAt = AIState == (int)Phase.Deathray ? (calamityGlobalNPC.newAI[3] == 0f ? new Vector2(0f, npc.Center.Y + 1000f) : new Vector2(npc.Center.X + 1000f, 0f)) : player.Center;
|
||||
Vector2 lookAt = AIState == (int)Phase.Deathray ? (horizontalLaserSweep ? new Vector2(npc.Center.X, npc.Center.Y + 1000f) : new Vector2(npc.Center.X + 1000f, npc.Center.Y)) : player.Center;
|
||||
|
||||
float rotation = (float)Math.Atan2(lookAt.Y - npc.Center.Y, lookAt.X - npc.Center.X);
|
||||
if (npc.spriteDirection == 1)
|
||||
@@ -239,29 +232,22 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
if (rotation > MathHelper.TwoPi)
|
||||
rotation -= MathHelper.TwoPi;
|
||||
|
||||
if (npc.rotation < rotation)
|
||||
{
|
||||
if (rotation - npc.rotation > MathHelper.Pi)
|
||||
npc.rotation -= rateOfRotation;
|
||||
else
|
||||
npc.rotation += rateOfRotation;
|
||||
}
|
||||
if (npc.rotation > rotation)
|
||||
{
|
||||
if (npc.rotation - rotation > MathHelper.Pi)
|
||||
npc.rotation += rateOfRotation;
|
||||
else
|
||||
npc.rotation -= rateOfRotation;
|
||||
}
|
||||
npc.rotation = npc.rotation.AngleTowards(rotation, rateOfRotation);
|
||||
|
||||
if (npc.rotation > rotation - rateOfRotation && npc.rotation < rotation + rateOfRotation)
|
||||
npc.rotation = rotation;
|
||||
if (npc.rotation < 0f)
|
||||
npc.rotation += MathHelper.TwoPi;
|
||||
if (npc.rotation > MathHelper.TwoPi)
|
||||
npc.rotation -= MathHelper.TwoPi;
|
||||
if (npc.rotation > rotation - rateOfRotation && npc.rotation < rotation + rateOfRotation)
|
||||
npc.rotation = rotation;
|
||||
// Direction
|
||||
int direction = Math.Sign(player.Center.X - npc.Center.X);
|
||||
if (direction != 0)
|
||||
{
|
||||
if (calamityGlobalNPC.newAI[1] == 0f && calamityGlobalNPC.newAI[2] == 0f && direction != npc.direction)
|
||||
npc.rotation += MathHelper.Pi;
|
||||
|
||||
npc.direction = direction;
|
||||
|
||||
if (npc.spriteDirection != -npc.direction)
|
||||
npc.rotation += MathHelper.Pi;
|
||||
|
||||
npc.spriteDirection = -npc.direction;
|
||||
}
|
||||
|
||||
// Light
|
||||
Lighting.AddLight(npc.Center, 0.25f, 0.1f, 0.1f);
|
||||
@@ -280,13 +266,12 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
Vector2 desiredVelocity = Vector2.Normalize(destination - npc.Center) * baseVelocity;
|
||||
|
||||
// Distance from target
|
||||
float distanceFromTarget = Vector2.Distance(npc.Center, player.Center);
|
||||
// Whether Ares Laser Arm should move to its spot or not
|
||||
float movementDistanceGateValue = 32f;
|
||||
bool moveToLocation = Vector2.Distance(npc.Center, destination) > movementDistanceGateValue;
|
||||
|
||||
// Gate values
|
||||
float deathrayPhaseGateValue = 420f;
|
||||
float deathrayPhaseVelocityMult = 0.95f;
|
||||
float deathrayDecelerationTime = 15f;
|
||||
float deathrayPhaseVelocity = 15f;
|
||||
|
||||
// Variable to disable deathray firing
|
||||
@@ -304,7 +289,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
// Do nothing, rotate to aim at the target and fly in place
|
||||
case (int)Phase.Nothing:
|
||||
|
||||
if (!targetDead)
|
||||
if (!targetDead && moveToLocation)
|
||||
npc.SimpleFlyMovement(desiredVelocity, baseAcceleration);
|
||||
|
||||
calamityGlobalNPC.newAI[1] += 1f;
|
||||
@@ -324,31 +309,39 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
calamityGlobalNPC.newAI[2] += 1f;
|
||||
if (calamityGlobalNPC.newAI[2] < deathrayTelegraphDuration)
|
||||
{
|
||||
// Reduce velocity for 15 frames once charging is nearly complete
|
||||
if (calamityGlobalNPC.newAI[2] >= deathrayTelegraphDuration - deathrayDecelerationTime)
|
||||
npc.velocity *= deathrayPhaseVelocityMult;
|
||||
// Fly in place
|
||||
if (moveToLocation)
|
||||
npc.SimpleFlyMovement(desiredVelocity, baseAcceleration);
|
||||
|
||||
// Set frames to deathray charge up frames, which begin on frame 12
|
||||
if (calamityGlobalNPC.newAI[2] == 1f)
|
||||
{
|
||||
// Set frames to deathray charge up frames
|
||||
// Reset the frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// X = 1 sets to frame 8
|
||||
frameX = 1;
|
||||
frameY = 5;
|
||||
exactFrame = 12;
|
||||
|
||||
// Y = 4 sets to frame 12
|
||||
frameY = 4;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Two possible variants: 1 - Horizontal, 2 - Vertical
|
||||
|
||||
// Movement while firing deathray
|
||||
if (horizontalLaserSweep)
|
||||
desiredVelocity.X = 0f;
|
||||
else
|
||||
desiredVelocity.Y = 0f;
|
||||
|
||||
npc.SimpleFlyMovement(desiredVelocity, baseAcceleration);
|
||||
npc.velocity = horizontalLaserSweep ? new Vector2(deathrayPhaseVelocity, npc.velocity.Y) : new Vector2(npc.velocity.X, deathrayPhaseVelocity);
|
||||
|
||||
// Fire deathray
|
||||
if (calamityGlobalNPC.newAI[2] == deathrayTelegraphDuration)
|
||||
{
|
||||
// Two possible variants: 1 - Left to right, 2 - Top to bottom
|
||||
npc.velocity = calamityGlobalNPC.newAI[3] == 0f ? new Vector2(deathrayPhaseVelocity, 0f) : new Vector2(0f, deathrayPhaseVelocity);
|
||||
|
||||
calamityGlobalNPC.newAI[3] += 1f;
|
||||
if (calamityGlobalNPC.newAI[3] > 1f)
|
||||
calamityGlobalNPC.newAI[3] = 0f;
|
||||
|
||||
if (Main.netMode != NetmodeID.MultiplayerClient)
|
||||
{
|
||||
int type = ModContent.ProjectileType<AresLaserBeamStart>();
|
||||
@@ -367,8 +360,15 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
|
||||
if (calamityGlobalNPC.newAI[2] >= deathrayTelegraphDuration + deathrayDuration)
|
||||
{
|
||||
// Reset
|
||||
AIState = (float)Phase.Nothing;
|
||||
calamityGlobalNPC.newAI[2] = 0f;
|
||||
|
||||
// Change deathray sweep type for next deathray phase
|
||||
calamityGlobalNPC.newAI[3] += 1f;
|
||||
if (calamityGlobalNPC.newAI[3] > 1f)
|
||||
calamityGlobalNPC.newAI[3] = 0f;
|
||||
|
||||
npc.TargetClosest();
|
||||
}
|
||||
}
|
||||
@@ -389,36 +389,44 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 8
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > normalFrameLimit)
|
||||
frameX = frameY = exactFrame = 0;
|
||||
|
||||
// Reset the frames
|
||||
if ((frameX * maxFramesY) + frameY > normalFrameLimit)
|
||||
frameX = frameY = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 8
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > finalStageDeathrayChargeFrameLimit)
|
||||
{
|
||||
frameX = 4;
|
||||
frameY = 5;
|
||||
exactFrame = secondStageDeathrayChargeFrameLimit + 1;
|
||||
}
|
||||
|
||||
// Reset the frames to frame 36, the start of the deathray firing animation loop
|
||||
if ((frameX * maxFramesY) + frameY > finalStageDeathrayChargeFrameLimit)
|
||||
frameX = frameY = 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Potions;
|
||||
using CalamityMod.NPCs.ExoMechs.Thanatos;
|
||||
using CalamityMod.Particles;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
@@ -39,9 +34,6 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
private int frameX = 0;
|
||||
private int frameY = 0;
|
||||
|
||||
// The exact frame the animation is currently on
|
||||
private int exactFrame = 0;
|
||||
|
||||
// Frame limit per animation, these are the specific frames where each animation ends
|
||||
private const int normalFrameLimit = 11;
|
||||
private const int firstStagePlasmaBoltChargeFrameLimit = 23;
|
||||
@@ -230,10 +222,11 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
Vector2 predictionVector = player.velocity * predictionAmt;
|
||||
Vector2 rotationVector = player.Center + predictionVector - npc.Center;
|
||||
|
||||
float projectileVelocity = 12f;
|
||||
float rateOfRotation = AIState == (int)Phase.PlasmaBolts ? 0.08f : 0.04f;
|
||||
Vector2 lookAt = player.Center + Vector2.Normalize(rotationVector);
|
||||
Vector2 lookAt = Vector2.Normalize(rotationVector) * projectileVelocity;
|
||||
|
||||
float rotation = (float)Math.Atan2(lookAt.Y - npc.Center.Y, lookAt.X - npc.Center.X);
|
||||
float rotation = (float)Math.Atan2(lookAt.Y, lookAt.X);
|
||||
if (npc.spriteDirection == 1)
|
||||
rotation += MathHelper.Pi;
|
||||
if (rotation < 0f)
|
||||
@@ -241,29 +234,22 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
if (rotation > MathHelper.TwoPi)
|
||||
rotation -= MathHelper.TwoPi;
|
||||
|
||||
if (npc.rotation < rotation)
|
||||
{
|
||||
if (rotation - npc.rotation > MathHelper.Pi)
|
||||
npc.rotation -= rateOfRotation;
|
||||
else
|
||||
npc.rotation += rateOfRotation;
|
||||
}
|
||||
if (npc.rotation > rotation)
|
||||
{
|
||||
if (npc.rotation - rotation > MathHelper.Pi)
|
||||
npc.rotation += rateOfRotation;
|
||||
else
|
||||
npc.rotation -= rateOfRotation;
|
||||
}
|
||||
npc.rotation = npc.rotation.AngleTowards(rotation, rateOfRotation);
|
||||
|
||||
if (npc.rotation > rotation - rateOfRotation && npc.rotation < rotation + rateOfRotation)
|
||||
npc.rotation = rotation;
|
||||
if (npc.rotation < 0f)
|
||||
npc.rotation += MathHelper.TwoPi;
|
||||
if (npc.rotation > MathHelper.TwoPi)
|
||||
npc.rotation -= MathHelper.TwoPi;
|
||||
if (npc.rotation > rotation - rateOfRotation && npc.rotation < rotation + rateOfRotation)
|
||||
npc.rotation = rotation;
|
||||
// Direction
|
||||
int direction = Math.Sign(player.Center.X - npc.Center.X);
|
||||
if (direction != 0)
|
||||
{
|
||||
if (calamityGlobalNPC.newAI[1] == 0f && calamityGlobalNPC.newAI[2] == 0f && direction != npc.direction)
|
||||
npc.rotation += MathHelper.Pi;
|
||||
|
||||
npc.direction = direction;
|
||||
|
||||
if (npc.spriteDirection != -npc.direction)
|
||||
npc.rotation += MathHelper.Pi;
|
||||
|
||||
npc.spriteDirection = -npc.direction;
|
||||
}
|
||||
|
||||
// Light
|
||||
Lighting.AddLight(npc.Center, 0.1f, 0.25f, 0.05f);
|
||||
@@ -282,8 +268,9 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
Vector2 desiredVelocity = Vector2.Normalize(destination - npc.Center) * baseVelocity;
|
||||
|
||||
// Distance from target
|
||||
float distanceFromTarget = Vector2.Distance(npc.Center, player.Center);
|
||||
// Whether Ares Plasma Arm should move to its spot or not
|
||||
float movementDistanceGateValue = 32f;
|
||||
bool moveToLocation = Vector2.Distance(npc.Center, destination) > movementDistanceGateValue;
|
||||
|
||||
// Gate values
|
||||
bool fireMoreBolts = calamityGlobalNPC_Body.newAI[0] == (float)AresBody.Phase.Deathrays;
|
||||
@@ -321,13 +308,17 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
calamityGlobalNPC.newAI[2] += 1f;
|
||||
if (calamityGlobalNPC.newAI[2] < plasmaBoltTelegraphDuration)
|
||||
{
|
||||
// Set frames to plasma orb charge up frames, which begin on frame 12
|
||||
if (calamityGlobalNPC.newAI[2] == 1f)
|
||||
{
|
||||
// Set frames to plasma bolt charge up frames
|
||||
// Reset the frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// X = 1 sets to frame 8
|
||||
frameX = 1;
|
||||
frameY = 5;
|
||||
exactFrame = 12;
|
||||
|
||||
// Y = 4 sets to frame 12
|
||||
frameY = 4;
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -341,7 +332,6 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
if (Main.netMode != NetmodeID.MultiplayerClient)
|
||||
{
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Item, "Sounds/Item/PlasmaCasterFire"), npc.Center);
|
||||
float projectileVelocity = 12f;
|
||||
Vector2 plasmaBoltVelocity = Vector2.Normalize(rotationVector) * projectileVelocity;
|
||||
int type = ModContent.ProjectileType<AresPlasmaFireball>();
|
||||
int damage = npc.GetProjectileDamage(type);
|
||||
@@ -363,7 +353,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
|
||||
// Movement
|
||||
if (!targetDead)
|
||||
if (!targetDead && moveToLocation)
|
||||
npc.SimpleFlyMovement(desiredVelocity, baseAcceleration);
|
||||
}
|
||||
|
||||
@@ -379,36 +369,44 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 8
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > normalFrameLimit)
|
||||
frameX = frameY = exactFrame = 0;
|
||||
|
||||
// Reset the frames
|
||||
if ((frameX * maxFramesY) + frameY > normalFrameLimit)
|
||||
frameX = frameY = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 8
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > finalStagePlasmaBoltChargeFrameLimit)
|
||||
{
|
||||
frameX = 4;
|
||||
frameY = 5;
|
||||
exactFrame = secondStagePlasmaBoltChargeFrameLimit + 1;
|
||||
}
|
||||
|
||||
// Reset the frames to frame 36, the start of the plasma bolt firing animation loop
|
||||
if ((frameX * maxFramesY) + frameY > finalStagePlasmaBoltChargeFrameLimit)
|
||||
frameX = frameY = 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Buffs.StatDebuffs;
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Potions;
|
||||
using CalamityMod.NPCs.ExoMechs.Thanatos;
|
||||
using CalamityMod.Particles;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
@@ -39,9 +34,6 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
private int frameX = 0;
|
||||
private int frameY = 0;
|
||||
|
||||
// The exact frame the animation is currently on
|
||||
private int exactFrame = 0;
|
||||
|
||||
// Frame limit per animation, these are the specific frames where each animation ends
|
||||
private const int normalFrameLimit = 11;
|
||||
private const int firstStageTeslaOrbChargeFrameLimit = 23;
|
||||
@@ -226,14 +218,15 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
|
||||
// Predictiveness
|
||||
float predictionAmt = malice ? 30f : death ? 25f : revenge ? 20f : expertMode ? 15f : 5f;
|
||||
float predictionAmt = malice ? 60f : death ? 50f : revenge ? 40f : expertMode ? 30f : 15f;
|
||||
Vector2 predictionVector = player.velocity * predictionAmt;
|
||||
Vector2 rotationVector = player.Center + predictionVector - npc.Center;
|
||||
|
||||
float projectileVelocity = 6f;
|
||||
float rateOfRotation = AIState == (int)Phase.TeslaOrbs ? 0.08f : 0.04f;
|
||||
Vector2 lookAt = player.Center + Vector2.Normalize(rotationVector);
|
||||
Vector2 lookAt = Vector2.Normalize(rotationVector) * projectileVelocity;
|
||||
|
||||
float rotation = (float)Math.Atan2(lookAt.Y - npc.Center.Y, lookAt.X - npc.Center.X);
|
||||
float rotation = (float)Math.Atan2(lookAt.Y, lookAt.X);
|
||||
if (npc.spriteDirection == 1)
|
||||
rotation += MathHelper.Pi;
|
||||
if (rotation < 0f)
|
||||
@@ -241,29 +234,22 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
if (rotation > MathHelper.TwoPi)
|
||||
rotation -= MathHelper.TwoPi;
|
||||
|
||||
if (npc.rotation < rotation)
|
||||
{
|
||||
if (rotation - npc.rotation > MathHelper.Pi)
|
||||
npc.rotation -= rateOfRotation;
|
||||
else
|
||||
npc.rotation += rateOfRotation;
|
||||
}
|
||||
if (npc.rotation > rotation)
|
||||
{
|
||||
if (npc.rotation - rotation > MathHelper.Pi)
|
||||
npc.rotation += rateOfRotation;
|
||||
else
|
||||
npc.rotation -= rateOfRotation;
|
||||
}
|
||||
npc.rotation = npc.rotation.AngleTowards(rotation, rateOfRotation);
|
||||
|
||||
if (npc.rotation > rotation - rateOfRotation && npc.rotation < rotation + rateOfRotation)
|
||||
npc.rotation = rotation;
|
||||
if (npc.rotation < 0f)
|
||||
npc.rotation += MathHelper.TwoPi;
|
||||
if (npc.rotation > MathHelper.TwoPi)
|
||||
npc.rotation -= MathHelper.TwoPi;
|
||||
if (npc.rotation > rotation - rateOfRotation && npc.rotation < rotation + rateOfRotation)
|
||||
npc.rotation = rotation;
|
||||
// Direction
|
||||
int direction = Math.Sign(player.Center.X - npc.Center.X);
|
||||
if (direction != 0)
|
||||
{
|
||||
if (calamityGlobalNPC.newAI[1] == 0f && calamityGlobalNPC.newAI[2] == 0f && direction != npc.direction)
|
||||
npc.rotation += MathHelper.Pi;
|
||||
|
||||
npc.direction = direction;
|
||||
|
||||
if (npc.spriteDirection != -npc.direction)
|
||||
npc.rotation += MathHelper.Pi;
|
||||
|
||||
npc.spriteDirection = -npc.direction;
|
||||
}
|
||||
|
||||
// Light
|
||||
Lighting.AddLight(npc.Center, 0.1f, 0.25f, 0.25f);
|
||||
@@ -282,8 +268,9 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
Vector2 desiredVelocity = Vector2.Normalize(destination - npc.Center) * baseVelocity;
|
||||
|
||||
// Distance from target
|
||||
float distanceFromTarget = Vector2.Distance(npc.Center, player.Center);
|
||||
// Whether Ares Tesla Arm should move to its spot or not
|
||||
float movementDistanceGateValue = 32f;
|
||||
bool moveToLocation = Vector2.Distance(npc.Center, destination) > movementDistanceGateValue;
|
||||
|
||||
// Gate values
|
||||
bool fireMoreOrbs = calamityGlobalNPC_Body.newAI[0] == (float)AresBody.Phase.Deathrays;
|
||||
@@ -321,13 +308,17 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
calamityGlobalNPC.newAI[2] += 1f;
|
||||
if (calamityGlobalNPC.newAI[2] < teslaOrbTelegraphDuration)
|
||||
{
|
||||
// Set frames to tesla orb charge up frames, which begin on frame 12
|
||||
if (calamityGlobalNPC.newAI[2] == 1f)
|
||||
{
|
||||
// Set frames to tesla orb charge up frames
|
||||
// Reset the frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// X = 1 sets to frame 8
|
||||
frameX = 1;
|
||||
frameY = 5;
|
||||
exactFrame = 12;
|
||||
|
||||
// Y = 4 sets to frame 12
|
||||
frameY = 4;
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -340,10 +331,12 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
{
|
||||
if (Main.netMode != NetmodeID.MultiplayerClient)
|
||||
{
|
||||
float projectileVelocity = 12f;
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Item, "Sounds/Item/PlasmaBolt"), npc.Center);
|
||||
Vector2 teslaOrbVelocity = Vector2.Normalize(rotationVector) * projectileVelocity;
|
||||
/*int type = ModContent.ProjectileType<AresTeslaOrb>();
|
||||
int damage = npc.GetProjectileDamage(type);*/
|
||||
int type = ModContent.ProjectileType<AresTeslaOrb>();
|
||||
int damage = npc.GetProjectileDamage(type);
|
||||
float offset = 40f;
|
||||
Projectile.NewProjectile(npc.Center + Vector2.Normalize(teslaOrbVelocity) * offset, teslaOrbVelocity, type, damage, 0f, Main.myPlayer, player.Center.X, player.Center.Y);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -360,7 +353,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
}
|
||||
|
||||
// Movement
|
||||
if (!targetDead)
|
||||
if (!targetDead && moveToLocation)
|
||||
npc.SimpleFlyMovement(desiredVelocity, baseAcceleration);
|
||||
}
|
||||
|
||||
@@ -376,36 +369,44 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 8
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > normalFrameLimit)
|
||||
frameX = frameY = exactFrame = 0;
|
||||
|
||||
// Reset the frames
|
||||
if ((frameX * maxFramesY) + frameY > normalFrameLimit)
|
||||
frameX = frameY = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (npc.frameCounter >= 10D)
|
||||
{
|
||||
// Reset frame counter
|
||||
npc.frameCounter = 0D;
|
||||
|
||||
// Increment the Y frame
|
||||
frameY++;
|
||||
exactFrame++;
|
||||
|
||||
// Reset the Y frame if greater than 8
|
||||
if (frameY == maxFramesY)
|
||||
{
|
||||
frameX++;
|
||||
frameY = 0;
|
||||
}
|
||||
if (exactFrame > finalStageTeslaOrbChargeFrameLimit)
|
||||
{
|
||||
frameX = 4;
|
||||
frameY = 5;
|
||||
exactFrame = secondStageTeslaOrbChargeFrameLimit + 1;
|
||||
}
|
||||
|
||||
// Reset the frames to frame 36, the start of the tesla orb firing animation loop
|
||||
if ((frameX * maxFramesY) + frameY > finalStageTeslaOrbChargeFrameLimit)
|
||||
frameX = frameY = 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -256,7 +256,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
if (blobVelocity.Y < 2f)
|
||||
blobVelocity.Y = 2f + sporeVelocityYAdd;
|
||||
|
||||
Projectile.NewProjectile(npc.Center, blobVelocity, type, damage, 0f, Main.myPlayer);
|
||||
Projectile.NewProjectile(npc.Center, blobVelocity, type, damage, 0f, Main.myPlayer, 0f, player.Center.Y);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -322,7 +322,7 @@ namespace CalamityMod.NPCs.Perforator
|
||||
Vector2 velocity = destination + Vector2.UnitY * -maxVelocity;
|
||||
for (int i = 0; i < totalProjectiles + 1; i++)
|
||||
{
|
||||
Projectile.NewProjectile(start, velocity, type, damage, 0f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(start, velocity, type, damage, 0f, Main.myPlayer, 0f, player.Center.Y);
|
||||
velocity.X += velocityAdjustment * npc.direction;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System;
|
||||
using System.IO;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
@@ -28,14 +29,27 @@ namespace CalamityMod.Projectiles.Boss
|
||||
projectile.tileCollide = false;
|
||||
projectile.penetrate = -1;
|
||||
cooldownSlot = 1;
|
||||
projectile.timeLeft = 480;
|
||||
projectile.timeLeft = 180;
|
||||
projectile.Calamity().affectedByMaliceModeVelocityMultiplier = true;
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(projectile.localAI[0]);
|
||||
}
|
||||
|
||||
public override void ReceiveExtraAI(BinaryReader reader)
|
||||
{
|
||||
projectile.localAI[0] = reader.ReadSingle();
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
if (projectile.position.Y > projectile.ai[1])
|
||||
projectile.tileCollide = true;
|
||||
|
||||
// Animation
|
||||
projectile.frameCounter++;
|
||||
projectile.frameCounter++;
|
||||
if (projectile.frameCounter >= 10)
|
||||
{
|
||||
projectile.frame++;
|
||||
@@ -47,11 +61,10 @@ namespace CalamityMod.Projectiles.Boss
|
||||
// Rotation
|
||||
projectile.rotation = (float)Math.Atan2(projectile.velocity.Y, projectile.velocity.X) - MathHelper.PiOver2;
|
||||
|
||||
Vector2 dustOffset = Vector2.One * 50f;
|
||||
|
||||
if (projectile.ai[1] == 0f)
|
||||
// Spawn effects
|
||||
if (projectile.localAI[0] == 0f)
|
||||
{
|
||||
projectile.ai[1] = 1f;
|
||||
projectile.localAI[0] = 1f;
|
||||
for (int i = 0; i < 25; i++)
|
||||
{
|
||||
// Choose a random speed and angle
|
||||
@@ -65,18 +78,26 @@ namespace CalamityMod.Projectiles.Boss
|
||||
float scale = Main.rand.NextFloat(0.5f, 1.6f);
|
||||
|
||||
// Spawn dust
|
||||
Dust dust = Dust.NewDustPerfect(projectile.Center + dustOffset, 107, -dustVel, 0, default, scale);
|
||||
Dust dust = Dust.NewDustPerfect(projectile.Center, 107, -dustVel, 0, default, scale);
|
||||
dust.noGravity = true;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Generate dust behind the nuke
|
||||
for (int i = 0; i < 2; i++)
|
||||
|
||||
// Gauss sparks
|
||||
if (Main.myPlayer == projectile.owner)
|
||||
{
|
||||
Dust dust = Dust.NewDustPerfect(projectile.Center + dustOffset, 107);
|
||||
dust.velocity = -projectile.velocity * 0.5f;
|
||||
dust.noGravity = true;
|
||||
int totalProjectiles = CalamityWorld.malice ? 18 : 12;
|
||||
float radians = MathHelper.TwoPi / totalProjectiles;
|
||||
int type = ModContent.ProjectileType<AresGaussNukeProjectileSpark>();
|
||||
float velocity = 12f;
|
||||
double angleA = radians * 0.5;
|
||||
double angleB = MathHelper.ToRadians(90f) - angleA;
|
||||
float velocityX2 = (float)(velocity * Math.Sin(angleA) / Math.Sin(angleB));
|
||||
Vector2 spinningPoint = Main.rand.NextBool() ? new Vector2(0f, -velocity) : new Vector2(-velocityX2, -velocity);
|
||||
for (int k = 0; k < totalProjectiles; k++)
|
||||
{
|
||||
Vector2 velocity2 = spinningPoint.RotatedBy(radians * k);
|
||||
Projectile.NewProjectile(projectile.Center, velocity2 + Vector2.Normalize(projectile.velocity) * -6f, type, (int)(projectile.damage * 0.6), 0f, Main.myPlayer);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -115,9 +136,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
Rectangle frame = new Rectangle(0, projectile.frame * Main.projectileTexture[projectile.type].Height, Main.projectileTexture[projectile.type].Width, Main.projectileTexture[projectile.type].Height / Main.projFrames[projectile.type]);
|
||||
|
||||
Color color = Color.Lerp(Color.White, Color.GreenYellow, 0.5f);
|
||||
|
||||
spriteBatch.Draw(ModContent.GetTexture("CalamityMod/Projectiles/Boss/AresGaussNukeProjectileGlow"), projectile.Center - Main.screenPosition, frame, color, projectile.rotation, projectile.Size / 2, 1f, SpriteEffects.None, 0f);
|
||||
spriteBatch.Draw(ModContent.GetTexture("CalamityMod/Projectiles/Boss/AresGaussNukeProjectileGlow"), projectile.Center - Main.screenPosition, frame, Color.White, projectile.rotation, projectile.Size / 2, 1f, SpriteEffects.None, 0f);
|
||||
|
||||
return false;
|
||||
}
|
||||
@@ -153,21 +172,6 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
if (Main.myPlayer == projectile.owner)
|
||||
{
|
||||
// Gauss sparks
|
||||
int totalProjectiles = CalamityWorld.malice ? 18 : 12;
|
||||
float radians = MathHelper.TwoPi / totalProjectiles;
|
||||
int type = ModContent.ProjectileType<AresGaussNukeProjectileSpark>();
|
||||
float velocity = 12f;
|
||||
double angleA = radians * 0.5;
|
||||
double angleB = MathHelper.ToRadians(90f) - angleA;
|
||||
float velocityX2 = (float)(velocity * Math.Sin(angleA) / Math.Sin(angleB));
|
||||
Vector2 spinningPoint = Main.rand.NextBool() ? new Vector2(0f, -velocity) : new Vector2(-velocityX2, -velocity);
|
||||
for (int k = 0; k < totalProjectiles; k++)
|
||||
{
|
||||
Vector2 velocity2 = spinningPoint.RotatedBy(radians * k);
|
||||
Projectile.NewProjectile(projectile.Center, velocity2, type, (int)(projectile.damage * 0.6), 0f, Main.myPlayer);
|
||||
}
|
||||
|
||||
// Explosion waves
|
||||
for (int i = 0; i < 7; i++)
|
||||
{
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System;
|
||||
using System.IO;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
@@ -31,12 +32,32 @@ namespace CalamityMod.Projectiles.Boss
|
||||
projectile.Calamity().affectedByMaliceModeVelocityMultiplier = true;
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(projectile.localAI[0]);
|
||||
}
|
||||
|
||||
public override void ReceiveExtraAI(BinaryReader reader)
|
||||
{
|
||||
projectile.localAI[0] = reader.ReadSingle();
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
projectile.localAI[0] += 1f;
|
||||
if (projectile.localAI[0] >= 15f)
|
||||
{
|
||||
projectile.localAI[0] = 15f;
|
||||
projectile.velocity.Y += 0.1f;
|
||||
}
|
||||
|
||||
if (projectile.velocity.Y > 16f)
|
||||
projectile.velocity.Y = 16f;
|
||||
|
||||
if (projectile.timeLeft < 15)
|
||||
projectile.Opacity = MathHelper.Clamp(projectile.timeLeft / 15f, 0f, 1f);
|
||||
else
|
||||
projectile.Opacity = MathHelper.Clamp(1f - ((projectile.timeLeft - 595) / 5f), 0f, 1f);
|
||||
projectile.Opacity = MathHelper.Clamp(1f - ((projectile.timeLeft - 597) / 3f), 0f, 1f);
|
||||
|
||||
Lighting.AddLight(projectile.Center, 0.1f * projectile.Opacity, 0.125f * projectile.Opacity, 0.025f * projectile.Opacity);
|
||||
|
||||
@@ -64,7 +85,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
public override Color? GetAlpha(Color lightColor)
|
||||
{
|
||||
return new Color(255 * projectile.Opacity, 255 * projectile.Opacity, 255 * projectile.Opacity, projectile.alpha);
|
||||
return new Color(255 * projectile.Opacity, 255 * projectile.Opacity, 255 * projectile.Opacity);
|
||||
}
|
||||
|
||||
public override bool PreDraw(SpriteBatch spriteBatch, Color lightColor)
|
||||
|
||||
@@ -37,7 +37,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
if (projectile.timeLeft < 15)
|
||||
projectile.Opacity = MathHelper.Clamp(projectile.timeLeft / 15f, 0f, 1f);
|
||||
else
|
||||
projectile.Opacity = MathHelper.Clamp(1f - ((projectile.timeLeft - 595) / 5f), 0f, 1f);
|
||||
projectile.Opacity = MathHelper.Clamp(1f - ((projectile.timeLeft - 597) / 3f), 0f, 1f);
|
||||
|
||||
Lighting.AddLight(projectile.Center, 0f, 0.4f * projectile.Opacity, 0f);
|
||||
|
||||
@@ -66,7 +66,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
public override Color? GetAlpha(Color lightColor)
|
||||
{
|
||||
return new Color(255 * projectile.Opacity, 255 * projectile.Opacity, 255 * projectile.Opacity, projectile.alpha);
|
||||
return new Color(255 * projectile.Opacity, 255 * projectile.Opacity, 255 * projectile.Opacity);
|
||||
}
|
||||
|
||||
public override bool PreDraw(SpriteBatch spriteBatch, Color lightColor)
|
||||
|
||||
@@ -2,6 +2,7 @@ using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System;
|
||||
using System.IO;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
@@ -29,17 +30,27 @@ namespace CalamityMod.Projectiles.Boss
|
||||
projectile.penetrate = -1;
|
||||
projectile.Opacity = 0f;
|
||||
cooldownSlot = 1;
|
||||
projectile.timeLeft = 480;
|
||||
projectile.timeLeft = 240;
|
||||
projectile.Calamity().affectedByMaliceModeVelocityMultiplier = true;
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(projectile.localAI[0]);
|
||||
}
|
||||
|
||||
public override void ReceiveExtraAI(BinaryReader reader)
|
||||
{
|
||||
projectile.localAI[0] = reader.ReadSingle();
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
Vector2 targetLocation = new Vector2(projectile.ai[0], projectile.ai[1]);
|
||||
if (Vector2.Distance(targetLocation, projectile.Center) < 80f)
|
||||
projectile.tileCollide = true;
|
||||
|
||||
projectile.Opacity = MathHelper.Clamp(1f - ((projectile.timeLeft - 475) / 5f), 0f, 1f);
|
||||
projectile.Opacity = MathHelper.Clamp(1f - ((projectile.timeLeft - 237) / 3f), 0f, 1f);
|
||||
|
||||
Lighting.AddLight(projectile.Center, 0f, 0.6f * projectile.Opacity, 0f);
|
||||
|
||||
@@ -122,7 +133,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
public override Color? GetAlpha(Color lightColor)
|
||||
{
|
||||
return new Color(255 * projectile.Opacity, 255 * projectile.Opacity, 255 * projectile.Opacity, projectile.alpha);
|
||||
return new Color(255 * projectile.Opacity, 255 * projectile.Opacity, 255 * projectile.Opacity);
|
||||
}
|
||||
|
||||
public override bool PreDraw(SpriteBatch spriteBatch, Color lightColor)
|
||||
|
||||
@@ -0,0 +1,156 @@
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System;
|
||||
using System.IO;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.Projectiles.Boss
|
||||
{
|
||||
public class AresTeslaOrb : ModProjectile
|
||||
{
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Tesla Orb");
|
||||
Main.projFrames[projectile.type] = 4;
|
||||
ProjectileID.Sets.TrailCacheLength[projectile.type] = 4;
|
||||
ProjectileID.Sets.TrailingMode[projectile.type] = 0;
|
||||
}
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
projectile.width = 32;
|
||||
projectile.height = 32;
|
||||
projectile.hostile = true;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.penetrate = -1;
|
||||
projectile.Opacity = 0f;
|
||||
cooldownSlot = 1;
|
||||
projectile.timeLeft = 480;
|
||||
projectile.Calamity().affectedByMaliceModeVelocityMultiplier = true;
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(projectile.localAI[0]);
|
||||
}
|
||||
|
||||
public override void ReceiveExtraAI(BinaryReader reader)
|
||||
{
|
||||
projectile.localAI[0] = reader.ReadSingle();
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
if (projectile.timeLeft < 15)
|
||||
projectile.Opacity = MathHelper.Clamp(projectile.timeLeft / 15f, 0f, 1f);
|
||||
else
|
||||
projectile.Opacity = MathHelper.Clamp(1f - ((projectile.timeLeft - 477) / 3f), 0f, 1f);
|
||||
|
||||
Lighting.AddLight(projectile.Center, 0.1f * projectile.Opacity, 0.25f * projectile.Opacity, 0.25f * projectile.Opacity);
|
||||
|
||||
projectile.frameCounter++;
|
||||
if (projectile.frameCounter > 4)
|
||||
{
|
||||
projectile.frame++;
|
||||
projectile.frameCounter = 0;
|
||||
}
|
||||
if (projectile.frame > 3)
|
||||
projectile.frame = 0;
|
||||
|
||||
if (projectile.localAI[0] == 0f)
|
||||
{
|
||||
projectile.localAI[0] = 1f;
|
||||
|
||||
float speed1 = 1.8f;
|
||||
float speed2 = 2.8f;
|
||||
float angleRandom = 0.35f;
|
||||
|
||||
for (int num53 = 0; num53 < 40; num53++)
|
||||
{
|
||||
float dustSpeed = Main.rand.NextFloat(speed1, speed2);
|
||||
Vector2 dustVel = new Vector2(dustSpeed, 0.0f).RotatedBy(projectile.velocity.ToRotation());
|
||||
dustVel = dustVel.RotatedBy(-angleRandom);
|
||||
dustVel = dustVel.RotatedByRandom(2f * angleRandom);
|
||||
int randomDustType = Main.rand.Next(2) == 0 ? 206 : 229;
|
||||
float scale = randomDustType == 206 ? 1.5f : 1f;
|
||||
|
||||
int num54 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, randomDustType, dustVel.X, dustVel.Y, 200, default, 2.5f * scale);
|
||||
Main.dust[num54].position = projectile.Center + Vector2.UnitY.RotatedByRandom(MathHelper.Pi) * (float)Main.rand.NextDouble() * projectile.width / 2f;
|
||||
Main.dust[num54].noGravity = true;
|
||||
|
||||
Dust dust = Main.dust[num54];
|
||||
dust.velocity *= 3f;
|
||||
dust = Main.dust[num54];
|
||||
|
||||
num54 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, randomDustType, dustVel.X, dustVel.Y, 100, default, 1.5f * scale);
|
||||
Main.dust[num54].position = projectile.Center + Vector2.UnitY.RotatedByRandom(MathHelper.Pi) * (float)Main.rand.NextDouble() * projectile.width / 2f;
|
||||
|
||||
dust = Main.dust[num54];
|
||||
dust.velocity *= 2f;
|
||||
|
||||
Main.dust[num54].noGravity = true;
|
||||
Main.dust[num54].fadeIn = 1f;
|
||||
Main.dust[num54].color = Color.Cyan * 0.5f;
|
||||
|
||||
dust = Main.dust[num54];
|
||||
}
|
||||
for (int num55 = 0; num55 < 20; num55++)
|
||||
{
|
||||
float dustSpeed = Main.rand.NextFloat(speed1, speed2);
|
||||
Vector2 dustVel = new Vector2(dustSpeed, 0f).RotatedBy(projectile.velocity.ToRotation());
|
||||
dustVel = dustVel.RotatedBy(-angleRandom);
|
||||
dustVel = dustVel.RotatedByRandom(2f * angleRandom);
|
||||
int randomDustType = Main.rand.Next(2) == 0 ? 206 : 229;
|
||||
float scale = randomDustType == 206 ? 1.5f : 1f;
|
||||
|
||||
int num56 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, randomDustType, dustVel.X, dustVel.Y, 0, default, 3f * scale);
|
||||
Main.dust[num56].position = projectile.Center + Vector2.UnitX.RotatedByRandom(MathHelper.Pi).RotatedBy(projectile.velocity.ToRotation()) * projectile.width / 3f;
|
||||
Main.dust[num56].noGravity = true;
|
||||
|
||||
Dust dust = Main.dust[num56];
|
||||
dust.velocity *= 0.5f;
|
||||
dust = Main.dust[num56];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override bool OnTileCollide(Vector2 oldVelocity)
|
||||
{
|
||||
projectile.velocity = oldVelocity;
|
||||
|
||||
if (projectile.timeLeft > 15)
|
||||
projectile.timeLeft = 15;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public override bool CanHitPlayer(Player target) => projectile.Opacity == 1f;
|
||||
|
||||
public override void OnHitPlayer(Player target, int damage, bool crit)
|
||||
{
|
||||
if (projectile.Opacity != 1f)
|
||||
return;
|
||||
|
||||
target.AddBuff(BuffID.Electrified, 240);
|
||||
}
|
||||
|
||||
public override Color? GetAlpha(Color lightColor)
|
||||
{
|
||||
return new Color(255 * projectile.Opacity, 255 * projectile.Opacity, 255 * projectile.Opacity);
|
||||
}
|
||||
|
||||
public override bool PreDraw(SpriteBatch spriteBatch, Color lightColor)
|
||||
{
|
||||
CalamityUtils.DrawAfterimagesCentered(projectile, ProjectileID.Sets.TrailingMode[projectile.type], lightColor, 1);
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void ModifyHitPlayer(Player target, ref int damage, ref bool crit)
|
||||
{
|
||||
target.Calamity().lastProjectileHit = projectile;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -25,10 +25,10 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
if (projectile.timeLeft < 300)
|
||||
projectile.tileCollide = true;
|
||||
if (projectile.position.Y > projectile.ai[1])
|
||||
projectile.tileCollide = true;
|
||||
|
||||
projectile.rotation = (float)Math.Atan2(projectile.velocity.Y, projectile.velocity.X) + MathHelper.PiOver2;
|
||||
projectile.rotation = (float)Math.Atan2(projectile.velocity.Y, projectile.velocity.X) + MathHelper.PiOver2;
|
||||
|
||||
int num469 = Dust.NewDust(new Vector2(projectile.position.X, projectile.position.Y), projectile.width, projectile.height, DustID.Blood, 0f, 0f, 100, default, 0.5f);
|
||||
Main.dust[num469].noGravity = true;
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.NPCs.Calamitas;
|
||||
using CalamityMod.NPCs.SupremeCalamitas;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
@@ -64,7 +65,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
projectile.localAI[0] = 1f;
|
||||
|
||||
if (projectile.ai[0] == 0f)
|
||||
projectile.damage = projectile.GetProjectileDamage(ModContent.NPCType<SupremeCalamitas>());
|
||||
projectile.damage = NPC.AnyNPCs(ModContent.NPCType<SupremeCalamitas>()) ? projectile.GetProjectileDamage(ModContent.NPCType<SupremeCalamitas>()) : projectile.GetProjectileDamage(ModContent.NPCType<CalamitasRun3>());
|
||||
}
|
||||
|
||||
Lighting.AddLight(projectile.Center, 0.75f * projectile.Opacity, 0f, 0f);
|
||||
|
||||
@@ -37,7 +37,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
if (projectile.ai[0] == 2f && Main.expertMode && projectile.timeLeft < 1260)
|
||||
{
|
||||
if (projectile.velocity.Length() < (CalamityWorld.malice ? 10f : 8f))
|
||||
projectile.velocity *= 1.02f;
|
||||
projectile.velocity *= 1.01f;
|
||||
}
|
||||
|
||||
projectile.frameCounter++;
|
||||
|
||||
@@ -32,7 +32,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
//Animation
|
||||
// Animation
|
||||
projectile.frameCounter++;
|
||||
if (projectile.frameCounter > 9)
|
||||
{
|
||||
@@ -42,7 +42,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
if (projectile.frame >= 6)
|
||||
projectile.frame = 0;
|
||||
|
||||
//Fade in
|
||||
// Fade in
|
||||
if (projectile.alpha > 5)
|
||||
projectile.alpha -= 15;
|
||||
if (projectile.alpha < 5)
|
||||
@@ -64,7 +64,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
projectile.Kill();
|
||||
}
|
||||
|
||||
//Rotation
|
||||
// Rotation
|
||||
projectile.spriteDirection = projectile.direction = (projectile.velocity.X > 0).ToDirectionInt();
|
||||
projectile.rotation = projectile.velocity.ToRotation() + (projectile.spriteDirection == 1 ? 0f : MathHelper.Pi) - MathHelper.ToRadians(90f) * projectile.direction;
|
||||
|
||||
|
||||
@@ -20,8 +20,8 @@ namespace CalamityMod.Projectiles.Boss
|
||||
public override void SetDefaults()
|
||||
{
|
||||
projectile.Calamity().canBreakPlayerDefense = true;
|
||||
projectile.width = 30;
|
||||
projectile.height = 30;
|
||||
projectile.width = 34;
|
||||
projectile.height = 34;
|
||||
projectile.hostile = true;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.tileCollide = false;
|
||||
|
||||
@@ -20,10 +20,11 @@ namespace CalamityMod.Projectiles.Boss
|
||||
public override void SetDefaults()
|
||||
{
|
||||
projectile.Calamity().canBreakPlayerDefense = true;
|
||||
projectile.width = 14;
|
||||
projectile.height = 14;
|
||||
projectile.width = 22;
|
||||
projectile.height = 22;
|
||||
projectile.hostile = true;
|
||||
projectile.tileCollide = false;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.penetrate = 1;
|
||||
projectile.Calamity().affectedByMaliceModeVelocityMultiplier = true;
|
||||
}
|
||||
|
||||
@@ -24,6 +24,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
projectile.height = 56;
|
||||
projectile.hostile = true;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.tileCollide = false;
|
||||
projectile.penetrate = -1;
|
||||
projectile.Calamity().affectedByMaliceModeVelocityMultiplier = true;
|
||||
}
|
||||
@@ -31,18 +32,23 @@ namespace CalamityMod.Projectiles.Boss
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(projectile.localAI[0]);
|
||||
}
|
||||
writer.Write(projectile.localAI[1]);
|
||||
}
|
||||
|
||||
public override void ReceiveExtraAI(BinaryReader reader)
|
||||
{
|
||||
projectile.localAI[0] = reader.ReadSingle();
|
||||
}
|
||||
projectile.localAI[1] = reader.ReadSingle();
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
if (projectile.position.Y > projectile.ai[1] - 32f)
|
||||
projectile.tileCollide = true;
|
||||
|
||||
// Deal no damage and increment the variable used to kill the projectile after 15 seconds
|
||||
projectile.ai[1] += 1f;
|
||||
if (projectile.ai[1] > 900f)
|
||||
projectile.localAI[1] += 1f;
|
||||
if (projectile.localAI[1] > 900f)
|
||||
{
|
||||
projectile.localAI[0] += 10f;
|
||||
projectile.damage = 0;
|
||||
@@ -183,14 +189,14 @@ namespace CalamityMod.Projectiles.Boss
|
||||
if (dist4 < minDist)
|
||||
minDist = dist4;
|
||||
|
||||
return minDist <= 16f && projectile.ai[1] <= 900f && projectile.ai[1] > 120f;
|
||||
return minDist <= 16f && projectile.localAI[1] <= 900f && projectile.localAI[1] > 120f;
|
||||
}
|
||||
|
||||
public override Color? GetAlpha(Color lightColor)
|
||||
{
|
||||
if (projectile.ai[1] > 900f)
|
||||
if (projectile.localAI[1] > 900f)
|
||||
{
|
||||
byte b2 = (byte)((26f - (projectile.ai[1] - 900f)) * 10f);
|
||||
byte b2 = (byte)((26f - (projectile.localAI[1] - 900f)) * 10f);
|
||||
byte a2 = (byte)(projectile.alpha * (b2 / 255f));
|
||||
return new Color(b2, b2, b2, a2);
|
||||
}
|
||||
@@ -205,7 +211,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
public override void OnHitPlayer(Player target, int damage, bool crit)
|
||||
{
|
||||
if (projectile.ai[1] <= 900f && projectile.ai[1] > 120f)
|
||||
if (projectile.localAI[1] <= 900f && projectile.localAI[1] > 120f)
|
||||
target.AddBuff(BuffID.Ichor, 240);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,19 +26,17 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
if (projectile.timeLeft < 300)
|
||||
projectile.tileCollide = true;
|
||||
if (projectile.position.Y > projectile.ai[1])
|
||||
projectile.tileCollide = true;
|
||||
|
||||
projectile.frameCounter++;
|
||||
projectile.frameCounter++;
|
||||
if (projectile.frameCounter > 4)
|
||||
{
|
||||
projectile.frame++;
|
||||
projectile.frameCounter = 0;
|
||||
}
|
||||
if (projectile.frame > 5)
|
||||
{
|
||||
projectile.frame = 0;
|
||||
}
|
||||
|
||||
projectile.rotation = (float)Math.Atan2(projectile.velocity.Y, projectile.velocity.X) + MathHelper.PiOver2;
|
||||
|
||||
|
||||
@@ -20,8 +20,8 @@ namespace CalamityMod.Projectiles.Boss
|
||||
public override void SetDefaults()
|
||||
{
|
||||
projectile.Calamity().canBreakPlayerDefense = true;
|
||||
projectile.width = 38;
|
||||
projectile.height = 38;
|
||||
projectile.width = 32;
|
||||
projectile.height = 32;
|
||||
projectile.hostile = true;
|
||||
projectile.tileCollide = false;
|
||||
projectile.penetrate = -1;
|
||||
@@ -93,7 +93,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
{
|
||||
target.AddBuff(ModContent.BuffType<HolyFlames>(), 180);
|
||||
}
|
||||
|
||||
|
||||
public override void ModifyHitPlayer(Player target, ref int damage, ref bool crit)
|
||||
{
|
||||
target.Calamity().lastProjectileHit = projectile;
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 451 B After Width: | Height: | Size: 501 B |
@@ -24,6 +24,7 @@ namespace CalamityMod.Projectiles.Boss
|
||||
projectile.alpha = 255;
|
||||
projectile.penetrate = 1;
|
||||
projectile.tileCollide = false;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.timeLeft = 600;
|
||||
cooldownSlot = 1;
|
||||
}
|
||||
|
||||
@@ -21,8 +21,8 @@ namespace CalamityMod.Projectiles.Boss
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
projectile.width = 12;
|
||||
projectile.height = 12;
|
||||
projectile.width = 16;
|
||||
projectile.height = 16;
|
||||
projectile.hostile = true;
|
||||
projectile.tileCollide = false;
|
||||
projectile.penetrate = -1;
|
||||
|
||||
@@ -24,8 +24,8 @@ namespace CalamityMod.Projectiles.Boss
|
||||
public override void SetDefaults()
|
||||
{
|
||||
projectile.Calamity().canBreakPlayerDefense = true;
|
||||
projectile.width = 30;
|
||||
projectile.height = 30;
|
||||
projectile.width = 34;
|
||||
projectile.height = 34;
|
||||
projectile.hostile = true;
|
||||
projectile.alpha = 255;
|
||||
projectile.penetrate = -1;
|
||||
|
||||
@@ -23,8 +23,8 @@ namespace CalamityMod.Projectiles.Boss
|
||||
public override void SetDefaults()
|
||||
{
|
||||
projectile.Calamity().canBreakPlayerDefense = true;
|
||||
projectile.width = 30;
|
||||
projectile.height = 30;
|
||||
projectile.width = 34;
|
||||
projectile.height = 34;
|
||||
projectile.hostile = true;
|
||||
projectile.alpha = 255;
|
||||
projectile.penetrate = -1;
|
||||
@@ -36,13 +36,11 @@ namespace CalamityMod.Projectiles.Boss
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(projectile.localAI[0]);
|
||||
writer.Write(projectile.localAI[1]);
|
||||
}
|
||||
|
||||
public override void ReceiveExtraAI(BinaryReader reader)
|
||||
{
|
||||
projectile.localAI[0] = reader.ReadSingle();
|
||||
projectile.localAI[1] = reader.ReadSingle();
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
@@ -54,41 +52,38 @@ namespace CalamityMod.Projectiles.Boss
|
||||
projectile.frameCounter = 0;
|
||||
}
|
||||
if (projectile.frame >= Main.projFrames[projectile.type])
|
||||
{
|
||||
projectile.frame = 0;
|
||||
}
|
||||
if (projectile.velocity.Y < 0f)
|
||||
|
||||
if (projectile.velocity.Y < -1f)
|
||||
{
|
||||
// 129 frames to get from -50 to -1
|
||||
projectile.velocity.Y *= 0.97f;
|
||||
}
|
||||
else
|
||||
{
|
||||
projectile.velocity.Y *= 1.03f;
|
||||
if (projectile.velocity.Y > 16f)
|
||||
{
|
||||
// 85 frames to get from -1 to 16
|
||||
projectile.velocity.Y += 0.2f;
|
||||
if (projectile.velocity.Y > 16f)
|
||||
projectile.velocity.Y = 16f;
|
||||
}
|
||||
}
|
||||
if (projectile.velocity.Y > -1f && projectile.localAI[1] == 0f)
|
||||
{
|
||||
projectile.localAI[1] = 1f;
|
||||
projectile.velocity.Y = 1f;
|
||||
}
|
||||
|
||||
projectile.velocity.X *= 0.995f;
|
||||
|
||||
projectile.rotation = projectile.velocity.ToRotation() - MathHelper.PiOver2;
|
||||
|
||||
if (projectile.localAI[0] == 0f)
|
||||
{
|
||||
projectile.localAI[0] = 1f;
|
||||
Main.PlayTrackedSound(SoundID.DD2_BetsyFireballShot, projectile.Center);
|
||||
}
|
||||
|
||||
if (projectile.ai[0] >= 2f)
|
||||
{
|
||||
projectile.alpha -= 25;
|
||||
if (projectile.alpha < 0)
|
||||
{
|
||||
projectile.alpha = 0;
|
||||
}
|
||||
}
|
||||
|
||||
if (Main.rand.NextBool(16))
|
||||
{
|
||||
Dust dust = Dust.NewDustDirect(projectile.position, projectile.width, projectile.height, 55, 0f, 0f, 200, default, 1f);
|
||||
|
||||
Binary file not shown.
@@ -660,6 +660,7 @@ namespace CalamityMod
|
||||
{ new Tuple<int, int>(ModContent.NPCType<CalamitasRun3>(), ModContent.ProjectileType<BrimstoneHellfireball>()), new int[] { 84, 136, 156, 168, 234 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<CalamitasRun3>(), ModContent.ProjectileType<BrimstoneHellblast2>()), new int[] { 84, 136, 156, 168, 234 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<CalamitasRun3>(), ModContent.ProjectileType<BrimstoneGigaBlast>()), new int[] { 84, 136, 156, 168, 234 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<CalamitasRun3>(), ModContent.ProjectileType<BrimstoneBarrage>()), new int[] { 70, 112, 128, 140, 192 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<CalamitasRun>(), ModContent.ProjectileType<BrimstoneFire>()), new int[] { 76, 120, 140, 152, 210 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<CalamitasRun2>(), ModContent.ProjectileType<BrimstoneBall>()), new int[] { 72, 116, 136, 144, 204 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<SoulSeeker>(), ModContent.ProjectileType<BrimstoneBarrage>()), new int[] { 60, 100, 108, 116, 162 } },
|
||||
@@ -814,7 +815,7 @@ namespace CalamityMod
|
||||
//{ new Tuple<int, int>(ModContent.NPCType<AresBody>(), ModContent.ProjectileType<AresDeathBeamStart>()), new int[] { 500, 752, 788, 808, 1182 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<AresLaserCannon>(), ModContent.ProjectileType<AresLaserBeamStart>()), new int[] { 450, 676, 712, 732, 1068 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<AresPlasmaFlamethrower>(), ModContent.ProjectileType<AresPlasmaFireball>()), new int[] { 400, 600, 632, 648, 948 } },
|
||||
//{ new Tuple<int, int>(ModContent.NPCType<AresTeslaCannon>(), ModContent.ProjectileType<AresTeslaOrb>()), new int[] { 350, 528, 556, 572, 834 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<AresTeslaCannon>(), ModContent.ProjectileType<AresTeslaOrb>()), new int[] { 350, 528, 556, 572, 834 } },
|
||||
{ new Tuple<int, int>(ModContent.NPCType<AresGaussNuke>(), ModContent.ProjectileType<AresGaussNukeProjectile>()), new int[] { 500, 752, 788, 808, 1182 } },
|
||||
|
||||
{ new Tuple<int, int>(ModContent.NPCType<EidolonWyrmHeadHuge>(), ProjectileID.CultistBossIceMist), new int[] { 400, 600, 632, 648, 948 } },
|
||||
|
||||
Reference in new issue
Block a user