This commit is contained in:
Andrew Marheine committed 2021-11-12 21:56:28 -06:00
commit 480f87c4fe
109 files changed
+228 -106

No files matched your search

+17 -4
View File
@@ -11,6 +11,9 @@ namespace CalamityMod.Buffs.DamageOverTime
// This is the exact DPS dealt by Vulnerability Hex to NPCs.
public const int DPS = TickNumber * 5; // 3330 DPS
public const int CalamityDuration = 24;
public const int AflameDuration = 120;
public override void SetDefaults()
{
@@ -27,10 +30,20 @@ namespace CalamityMod.Buffs.DamageOverTime
public override void Update(NPC npc, ref int buffIndex)
{
if (npc.Calamity().vulnerabilityHex < npc.buffTime[buffIndex])
npc.Calamity().vulnerabilityHex = npc.buffTime[buffIndex];
if ((CalamityLists.enemyImmunityList.Contains(npc.type) || npc.boss) && npc.Calamity().debuffResistanceTimer <= 0)
npc.Calamity().debuffResistanceTimer = CalamityGlobalNPC.slowingDebuffResistanceMin + npc.Calamity().vulnerabilityHex;
CalamityGlobalNPC cgn = npc.Calamity();
if (cgn.vulnerabilityHex < npc.buffTime[buffIndex])
{
cgn.vulnerabilityHex = npc.buffTime[buffIndex];
// Set the remaining time of the fire drawer to be exactly right.
if (cgn.VulnerabilityHexFireDrawer != null)
cgn.VulnerabilityHexFireDrawer.SetLifetime = cgn.VulnerabilityHexFireDrawer.LocalTimer + cgn.vulnerabilityHex;
}
// Apply immunity timer.
if ((CalamityLists.enemyImmunityList.Contains(npc.type) || npc.boss) && cgn.debuffResistanceTimer <= 0)
cgn.debuffResistanceTimer = CalamityGlobalNPC.slowingDebuffResistanceMin + cgn.vulnerabilityHex;
// Destroy the vanilla buff, we don't use it.
npc.DelBuff(buffIndex);
buffIndex--;
}
+1
View File
@@ -32,6 +32,7 @@ namespace CalamityMod.Buffs.StatBuffs
// Otherwise, Rage Mode ends instantly.
else
{
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/RageEnd"), player.position);
player.DelBuff(buffIndex--); // TML documentation requires you to decrement buffIndex if deleting the buff during Update.
mp.rageModeActive = false;
mp.rage = 0f;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 704 B

After

Width:  |  Height:  |  Size: 459 B

+19 -11
View File
@@ -1208,7 +1208,13 @@ namespace CalamityMod.CalPlayer
boost.AddWithCondition("GivenBrimstoneLocus", GivenBrimstoneLocus);
// Calculate the new total time of all sessions at the instant of this player save.
TimeSpan newSessionTotal = previousSessionTotal.Add(CalamityMod.SpeedrunTimer.Elapsed);
TimeSpan newSessionTotal;
long totalTicks = 0L;
if (previousSessionTotal != null)
{
newSessionTotal = previousSessionTotal.Add(CalamityMod.SpeedrunTimer.Elapsed);
totalTicks = newSessionTotal.Ticks;
}
return new TagCompound
{
@@ -1237,7 +1243,7 @@ namespace CalamityMod.CalPlayer
{ "moveSpeedStat", moveSpeedStat },
{ "defenseDamage", defenseDamage },
{ "disableAllDodges", disableAllDodges },
{ "totalSpeedrunTicks", newSessionTotal.Ticks },
{ "totalSpeedrunTicks", totalTicks },
{ "lastSplitType", lastSplitType },
{ "lastSplitTicks", lastSplit.Ticks },
};
@@ -3153,8 +3159,8 @@ namespace CalamityMod.CalPlayer
// Rage duration isn't calculated here because the buff keeps itself alive automatically as long as the player has Rage left.
player.AddBuff(ModContent.BuffType<RageMode>(), 2);
// Moon Lord deathray sound. Should probably be replaced some day
Main.PlaySound(SoundID.Zombie, (int)player.position.X, (int)player.position.Y, 104);
// Play Rage Activation sound
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/RageActivate"), player.position);
// TODO -- improve Rage activation visuals
for (int num502 = 0; num502 < 64; num502++)
@@ -3184,8 +3190,8 @@ namespace CalamityMod.CalPlayer
{
player.AddBuff(ModContent.BuffType<AdrenalineMode>(), AdrenalineDuration);
// Moon Lord deathray sound. Should probably be replaced some day
Main.PlaySound(SoundID.Zombie, (int)player.position.X, (int)player.position.Y, 104);
// Play Adrenaline Activation sound
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/AdrenalineActivate"), player.position);
// TODO -- improve Adrenaline activation visuals
for (int num502 = 0; num502 < 64; num502++)
@@ -4816,7 +4822,7 @@ namespace CalamityMod.CalPlayer
witheringDamageDone += (int)(damage * (crit ? 2D : 1D));
if (flamingItemEnchant)
target.AddBuff(ModContent.BuffType<VulnerabilityHex>(), 120);
target.AddBuff(ModContent.BuffType<VulnerabilityHex>(), VulnerabilityHex.AflameDuration);
switch (item.type)
{
@@ -7064,8 +7070,11 @@ namespace CalamityMod.CalPlayer
bool falling = player.gravDir == -1 ? player.velocity.Y < 0.05f : player.velocity.Y > 0.05f;
if (player.controlJump && falling)
{
player.velocity.Y *= 0.9f;
player.wingFrame = 3;
if (!player.mount.Active)
{
player.velocity.Y *= 0.9f;
player.wingFrame = 3;
}
player.noFallDmg = true;
player.fallStart = (int)(player.position.Y / 16f);
}
@@ -10523,9 +10532,8 @@ namespace CalamityMod.CalPlayer
// Enabling the config while a player is loaded will show the timer immediately.
// But it won't start running until you save and quit and re-enter a world.
CalamityMod.SpeedrunTimer = new Stopwatch();
if (CalamityConfig.Instance.SpeedrunTimer)
CalamityMod.SpeedrunTimer.Start();
CalamityMod.SpeedrunTimer.Restart();
}
/// <summary>
+5 -2
View File
@@ -150,9 +150,12 @@ namespace CalamityMod.CalPlayer
}
}
// After everything, reset ranged crit if necessary.
// After everything else, if Daawnlight Spirit Origin is equipped, set ranged crit to the base 4%.
// Store all the crit so it can be used in damage calculations.
if (modPlayer.spiritOrigin)
{
// player.rangedCrit already contains the crit stat of the held item, no need to grab it separately.
// Don't store the base 4% because you're not removing it.
modPlayer.spiritOriginConvertedCrit = player.rangedCrit - 4;
player.rangedCrit = 4;
}
@@ -442,7 +445,7 @@ namespace CalamityMod.CalPlayer
Projectile.NewProjectileDirect(target.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), sigilDamage, 0f, player.whoAmI, i);
// Incinerate the target with Vulnerability Hex.
target.AddBuff(ModContent.BuffType<VulnerabilityHex>(), 20);
target.AddBuff(ModContent.BuffType<VulnerabilityHex>(), VulnerabilityHex.CalamityDuration);
// Make some fancy dust to indicate damage is being done.
for (int j = 0; j < 12; j++)
+8 -1
View File
@@ -119,7 +119,7 @@ namespace CalamityMod
public const int lifeStealCap = 10;
// Speedrun timer
internal static Stopwatch SpeedrunTimer = null;
internal static Stopwatch SpeedrunTimer = new Stopwatch();
// Debuff immunities, these are used in the NPCDebuffs file
public static int[] slimeEnemyImmunities = new int[1] { BuffID.Poisoned };
@@ -983,6 +983,13 @@ namespace CalamityMod
return true;
}, InterfaceScaleType.None));
// Enchantment meters
layers.Insert(mouseIndex, new LegacyGameInterfaceLayer("Enchantment Meters", () =>
{
EnchantmentMetersUI.Draw(Main.spriteBatch, Main.LocalPlayer);
return true;
}, InterfaceScaleType.None));
// Calamitas Enchantment UI
layers.Insert(mouseIndex, new LegacyGameInterfaceLayer("Calamitas Enchantment", () =>
{
Binary file not shown.

Before

Width:  |  Height:  |  Size: 223 B

After

Width:  |  Height:  |  Size: 195 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 821 B

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 8.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 225 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 231 B

After

Width:  |  Height:  |  Size: 201 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 855 B

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 6.1 KiB

@@ -21,6 +21,10 @@ namespace CalamityMod.Items.Accessories
private const float MaxSlowBonusUseTime = 72f;
private const float MaxSlowWeaponBonus = 0.33f; // Up to +33% more damage to crits for slower weapons.
// These were very carefully calculated, please don't change them.
internal const float RegularEnemyBullseyeRadius = 8f;
internal const float BossBullseyeRadius = 18f;
internal static float GetDamageMultiplier(Player p, CalamityPlayer mp, bool hitBullseye)
{
float baseCritMult = 2f; // In vanilla Terraria, crits do +100% damage.
+1
View File
@@ -5,6 +5,7 @@ using Terraria.ID;
namespace CalamityMod.Items.Accessories
{
[AutoloadEquip(EquipType.Back)]
public class GiantShell : ModItem
{
public override void SetStaticDefaults()
Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

+1
View File
@@ -6,6 +6,7 @@ using Terraria.ModLoader;
namespace CalamityMod.Items.Accessories
{
[AutoloadEquip(EquipType.Balloon)]
public class SamuraiBadge : ModItem
{
public override void SetStaticDefaults()
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 522 B

After

Width:  |  Height:  |  Size: 780 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 444 B

After

Width:  |  Height:  |  Size: 448 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 444 B

After

Width:  |  Height:  |  Size: 545 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 447 B

After

Width:  |  Height:  |  Size: 369 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 441 B

After

Width:  |  Height:  |  Size: 717 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 255 B

After

Width:  |  Height:  |  Size: 400 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 351 B

After

Width:  |  Height:  |  Size: 480 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 387 B

After

Width:  |  Height:  |  Size: 851 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 468 B

After

Width:  |  Height:  |  Size: 615 B

@@ -11,8 +11,8 @@ namespace CalamityMod.Items.Placeables.FurnitureStatigel
public override void SetDefaults()
{
item.width = 26;
item.height = 22;
item.width = 18;
item.height = 46;
item.maxStack = 99;
item.useTurn = true;
item.autoReuse = true;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 348 B

After

Width:  |  Height:  |  Size: 650 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 534 B

After

Width:  |  Height:  |  Size: 436 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 459 B

After

Width:  |  Height:  |  Size: 588 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 306 B

After

Width:  |  Height:  |  Size: 482 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 342 B

After

Width:  |  Height:  |  Size: 491 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 444 B

After

Width:  |  Height:  |  Size: 513 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 288 B

After

Width:  |  Height:  |  Size: 311 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 420 B

After

Width:  |  Height:  |  Size: 714 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 534 B

After

Width:  |  Height:  |  Size: 565 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 408 B

After

Width:  |  Height:  |  Size: 501 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 363 B

After

Width:  |  Height:  |  Size: 446 B

+3 -3
View File
@@ -24,11 +24,11 @@ namespace CalamityMod.Items.Weapons.Magic
item.width = 112;
item.height = 112;
item.magic = true;
item.damage = 2838;
item.damage = 2727;
item.knockBack = 9.5f;
item.mana = 26;
item.useAnimation = 37;
item.useTime = 37;
item.useAnimation = 40;
item.useTime = 40;
item.autoReuse = true;
item.noMelee = true;
+1 -1
View File
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Magic
public override void SetDefaults()
{
item.damage = 171;
item.damage = 247;
item.magic = true;
item.mana = 8;
item.width = 94;
+2 -2
View File
@@ -25,8 +25,8 @@ namespace CalamityMod.Items.Weapons.Summon
item.mana = 10;
item.damage = 1666;
item.useStyle = ItemUseStyleID.SwingThrow;
item.width = 58;
item.height = 64;
item.width = 86;
item.height = 92;
item.useTime = item.useAnimation = 30; // 29 because of useStyle 1
item.autoReuse = true;
item.noMelee = true;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 477 B

After

Width:  |  Height:  |  Size: 855 B

+2 -2
View File
@@ -25,8 +25,8 @@ namespace CalamityMod.Items.Weapons.Summon
{
item.damage = 666;
item.mana = 10;
item.width = 58;
item.height = 58;
item.width = 66;
item.height = 78;
item.useTime = item.useAnimation = 10; // 9 because of useStyle 1
item.useStyle = ItemUseStyleID.SwingThrow;
item.noMelee = true;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 906 B

@@ -83,7 +83,7 @@ namespace CalamityMod.Items.Weapons.Summon
{
player.Calamity().andromedaCripple = CrippleTime;
player.AddBuff(ModContent.BuffType<AndromedaCripple>(), player.Calamity().andromedaCripple);
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/AdrenalineBurnout1"), position);
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Custom, "Sounds/Custom/AndromedaCripple"), position);
}
return false;
}
+25 -25
View File
@@ -256,7 +256,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("DesertScourge", out float order);
List<int> segments = new List<int>() { NPCType<DesertScourgeHead>(), NPCType<DesertScourgeBody>(), NPCType<DesertScourgeTail>() };
int summon = ItemType<DriedSeafood>();
List<int> loot = new List<int>() { ItemType<DesertScourgeBag>(), ItemID.SandBlock, ItemType<VictoryShard>(), ItemID.Coral, ItemID.Seashell, ItemID.Starfish, ItemType<AquaticDischarge>(), ItemType<Barinade>(), ItemType<StormSpray>(), ItemType<SeaboundStaff>(), ItemType<ScourgeoftheDesert>(), ItemType<DuneHopper>(), ItemType<AeroStone>(), ItemType<SandCloak>(), ItemType<DeepDiver>(), ItemType<OceanCrest>(), ItemType<SandyAnglingKit>(), ItemID.LesserHealingPotion };
List<int> loot = new List<int>() { ItemType<DesertScourgeBag>(), ItemID.SandBlock, ItemType<VictoryShard>(), ItemID.Coral, ItemID.Seashell, ItemID.Starfish, ItemType<AquaticDischarge>(), ItemType<Barinade>(), ItemType<StormSpray>(), ItemType<SeaboundStaff>(), ItemType<ScourgeoftheDesert>(), ItemType<DuneHopper>(), ItemType<AeroStone>(), ItemType<SandCloak>(), ItemType<OceanCrest>(), ItemType<SandyAnglingKit>(), ItemID.LesserHealingPotion };
List<int> collection = new List<int>() { ItemType<DesertScourgeTrophy>(), ItemType<DesertScourgeMask>(), ItemType<KnowledgeDesertScourge>() };
string instructions = $"Use a [i:{summon}] in the Desert Biome";
string despawn = CalamityUtils.ColorMessage("The scourge of the desert delved back into the sand.", new Color(0xEE, 0xE8, 0xAA));
@@ -279,7 +279,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("Crabulon", out float order);
int type = NPCType<CrabulonIdle>();
int summon = ItemType<DecapoditaSprout>();
List<int> loot = new List<int>() { ItemType<CrabulonBag>(), ItemID.GlowingMushroom, ItemID.MushroomGrassSeeds, ItemType<MycelialClaws>(), ItemType<Fungicide>(), ItemType<HyphaeRod>(), ItemType<Mycoroot>(), ItemType<Shroomerang>(), ItemType<FungalClump>(), ItemType<MushroomPlasmaRoot>(), ItemID.LesserHealingPotion };
List<int> loot = new List<int>() { ItemType<CrabulonBag>(), ItemID.GlowingMushroom, ItemID.MushroomGrassSeeds, ItemType<MycelialClaws>(), ItemType<Fungicide>(), ItemType<HyphaeRod>(), ItemType<Mycoroot>(), ItemType<Shroomerang>(), ItemType<FungalClump>(), ItemType<TheTransformer>(), ItemType<MushroomPlasmaRoot>(), ItemID.LesserHealingPotion };
List<int> collection = new List<int>() { ItemType<CrabulonTrophy>(), ItemType<CrabulonMask>(), ItemType<KnowledgeCrabulon>() };
string instructions = $"Use a [i:{summon}] in the Mushroom Biome";
string despawn = CalamityUtils.ColorMessage("The mycleium crab has lost interest.", new Color(0x64, 0x95, 0xED));
@@ -291,7 +291,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("HiveMind", out float order);
int type = NPCType<HiveMind>();
int summon = ItemType<Teratoma>();
List<int> loot = new List<int>() { ItemType<HiveMindBag>(), ItemType<TrueShadowScale>(), ItemID.DemoniteBar, ItemID.RottenChunk, ItemID.CursedFlame, ItemType<PerfectDark>(), ItemType<LeechingDagger>(), ItemType<Shadethrower>(), ItemType<ShadowdropStaff>(), ItemType<ShaderainStaff>(), ItemType<DankStaff>(), ItemType<RotBall>(), ItemType<FilthyGlove>(), ItemType<RottenBrain>(), ItemID.LesserHealingPotion };
List<int> loot = new List<int>() { ItemType<HiveMindBag>(), ItemType<TrueShadowScale>(), ItemID.DemoniteBar, ItemID.RottenChunk, ItemID.CursedFlame, ItemType<PerfectDark>(), ItemType<LeechingDagger>(), ItemType<Shadethrower>(), ItemType<ShadowdropStaff>(), ItemType<ShaderainStaff>(), ItemType<DankStaff>(), ItemType<RotBall>(), ItemType<FilthyGlove>(), ItemType<RottenBrain>(), ItemType<Carnage>(), ItemID.LesserHealingPotion };
List<int> collection = new List<int>() { ItemType<HiveMindTrophy>(), ItemType<HiveMindMask>(), ItemType<KnowledgeHiveMind>(), ItemType<RottingEyeball>() };
string instructions = $"Kill a Cyst in the Corruption or use a [i:{summon}] in the Corruption";
string despawn = CalamityUtils.ColorMessage("The corrupted colony began searching for a new breeding ground.", new Color(0x94, 0x00, 0xD3));
@@ -303,7 +303,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("Perforators", out float order);
int type = NPCType<PerforatorHive>();
int summon = ItemType<BloodyWormFood>();
List<int> loot = new List<int>() { ItemType<PerforatorBag>(), ItemType<BloodSample>(), ItemID.CrimtaneBar, ItemID.Vertebrae, ItemID.Ichor, ItemType<VeinBurster>(), ItemType<BloodyRupture>(), ItemType<SausageMaker>(), ItemType<Aorta>(), ItemType<Eviscerator>(), ItemType<BloodBath>(), ItemType<BloodClotStaff>(), ItemType<ToothBall>(), ItemType<BloodstainedGlove>(), ItemType<BloodyWormTooth>(), ItemID.LesserHealingPotion };
List<int> loot = new List<int>() { ItemType<PerforatorBag>(), ItemType<BloodSample>(), ItemID.CrimtaneBar, ItemID.Vertebrae, ItemID.Ichor, ItemType<VeinBurster>(), ItemType<BloodyRupture>(), ItemType<SausageMaker>(), ItemType<Aorta>(), ItemType<Eviscerator>(), ItemType<BloodBath>(), ItemType<BloodClotStaff>(), ItemType<ToothBall>(), ItemType<BloodstainedGlove>(), ItemType<BloodyWormTooth>(), ItemType<Carnage>(), ItemID.LesserHealingPotion };
List<int> collection = new List<int>() { ItemType<PerforatorTrophy>(), ItemType<PerforatorMask>(), ItemType<KnowledgePerforators>(), ItemType<BloodyVein>() };
string instructions = $"Kill a Cyst in the Crimson or use a [i:{summon}] in the Crimson";
string despawn = CalamityUtils.ColorMessage("The parasitic hive began searching for a new host.", new Color(0xDC, 0x14, 0x3C));
@@ -327,7 +327,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("Cryogen", out float order);
int type = NPCType<Cryogen>();
int summon = ItemType<CryoKey>();
List<int> loot = new List<int>() { ItemType<CryogenBag>(), ItemType<EssenceofEleum>(), ItemID.FrostCore, ItemType<Avalanche>(), ItemType<GlacialCrusher>(), ItemType<EffluviumBow>(), ItemType<BittercoldStaff>(), ItemType<SnowstormStaff>(), ItemType<Icebreaker>(), ItemType<IceStar>(), ItemType<ColdDivinity>(), ItemType<CryoStone>(), ItemType<Regenator>(), ItemType<SoulofCryogen>(), ItemType<FrostFlare>(), ItemID.FrozenKey, ItemID.GreaterHealingPotion };
List<int> loot = new List<int>() { ItemType<CryogenBag>(), ItemType<EssenceofEleum>(), ItemType<Avalanche>(), ItemType<GlacialCrusher>(), ItemType<EffluviumBow>(), ItemType<BittercoldStaff>(), ItemType<SnowstormStaff>(), ItemType<Icebreaker>(), ItemType<IceStar>(), ItemType<ColdDivinity>(), ItemType<CryoStone>(), ItemType<SoulofCryogen>(), ItemType<FrostFlare>(), ItemType<Cryophobia>(), ItemID.FrozenKey, ItemID.GreaterHealingPotion };
List<int> collection = new List<int>() { ItemType<CryogenTrophy>(), ItemType<CryogenMask>(), ItemType<KnowledgeCryogen>() };
string instructions = $"Use a [i:{summon}] in the Snow Biome";
string despawn = CalamityUtils.ColorMessage("Cryogen drifts away, carried on a freezing wind.", new Color(0x00, 0xFF, 0xFF));
@@ -340,7 +340,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("AquaticScourge", out float order);
List<int> segments = new List<int>() { NPCType<AquaticScourgeHead>(), NPCType<AquaticScourgeBody>(), NPCType<AquaticScourgeBodyAlt>(), NPCType<AquaticScourgeTail>() };
int summon = ItemType<Seafood>();
List<int> loot = new List<int>() { ItemType<AquaticScourgeBag>(), ItemType<SulphurousSand>(), ItemType<SubmarineShocker>(), ItemType<Barinautical>(), ItemType<Downpour>(), ItemType<DeepseaStaff>(), ItemType<ScourgeoftheSeas>(), ItemType<SeasSearing>(), ItemType<AeroStone>(), ItemType<AquaticEmblem>(), ItemType<CorrosiveSpine>(), ItemType<BleachedAnglingKit>(), ItemID.GreaterHealingPotion };
List<int> loot = new List<int>() { ItemType<AquaticScourgeBag>(), ItemType<SulphurousSand>(), ItemType<SubmarineShocker>(), ItemType<Barinautical>(), ItemType<Downpour>(), ItemType<DeepseaStaff>(), ItemType<ScourgeoftheSeas>(), ItemType<SeasSearing>(), ItemType<AquaticEmblem>(), ItemType<CorrosiveSpine>(), ItemType<DeepDiver>(), ItemType<BleachedAnglingKit>(), ItemID.GreaterHealingPotion };
List<int> collection = new List<int>() { ItemType<AquaticScourgeTrophy>(), ItemType<AquaticScourgeMask>(), ItemType<KnowledgeAquaticScourge>(), ItemType<KnowledgeSulphurSea>() };
string instructions = $"Use a [i:{summon}] in the Sulphuric Sea or wait for it to spawn in the Sulphuric Sea";
string despawn = CalamityUtils.ColorMessage("The Aquatic Scourge swam back into the open ocean.", new Color(0xF0, 0xE6, 0x8C));
@@ -353,7 +353,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("BrimstoneElemental", out float order);
int type = NPCType<BrimstoneElemental>();
int summon = ItemType<CharredIdol>();
List<int> loot = new List<int>() { ItemType<BrimstoneWaifuBag>(), ItemType<EssenceofChaos>(), ItemType<Bloodstone>(), ItemType<Brimlance>(), ItemType<DormantBrimseeker>(), ItemType<SeethingDischarge>(), ItemType<Abaddon>(), ItemType<RoseStone>(), ItemType<Gehenna>(), ItemType<Brimrose>(), ItemID.GreaterHealingPotion };
List<int> loot = new List<int>() { ItemType<BrimstoneWaifuBag>(), ItemType<EssenceofChaos>(), ItemType<Bloodstone>(), ItemType<Brimlance>(), ItemType<DormantBrimseeker>(), ItemType<SeethingDischarge>(), ItemType<Abaddon>(), ItemType<RoseStone>(), ItemType<Gehenna>(), ItemType<Brimrose>(), ItemType<Hellborn>(), ItemType<FabledTortoiseShell>(), ItemID.GreaterHealingPotion };
List<int> collection = new List<int>() { ItemType<BrimstoneElementalTrophy>(), ItemType<BrimstoneWaifuMask>(), ItemType<KnowledgeBrimstoneCrag>(), ItemType<KnowledgeBrimstoneElemental>(), ItemType<CharredRelic>() };
string instructions = $"Use a [i:{summon}] in the Brimstone Crag";
string despawn = CalamityUtils.ColorMessage("Brimstone Elemental withdraws to the ruins of her shrine.", new Color(0xDC, 0x14, 0x3C));
@@ -365,7 +365,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("Calamitas", out float order);
int type = NPCType<CalamitasRun3>();
int summon = ItemType<BlightedEyeball>();
List<int> loot = new List<int>() { ItemType<CalamitasBag>(), ItemType<EssenceofChaos>(), ItemType<CalamityDust>(), ItemType<BlightedLens>(), ItemType<Bloodstone>(), ItemType<CalamitasInferno>(), ItemType<TheEyeofCalamitas>(), ItemType<BlightedEyeStaff>(), ItemType<Animosity>(), ItemType<BrimstoneFlamesprayer>(), ItemType<BrimstoneFlameblaster>(), ItemType<CrushsawCrasher>(), ItemType<ChaosStone>(), ItemType<CalamityRing>(), ItemID.BrokenHeroSword, ItemID.GreaterHealingPotion };
List<int> loot = new List<int>() { ItemType<CalamitasBag>(), ItemType<EssenceofChaos>(), ItemType<CalamityDust>(), ItemType<BlightedLens>(), ItemType<Bloodstone>(), ItemType<CalamitasInferno>(), ItemType<TheEyeofCalamitas>(), ItemType<BlightedEyeStaff>(), ItemType<Animosity>(), ItemType<BrimstoneFlamesprayer>(), ItemType<BrimstoneFlameblaster>(), ItemType<CrushsawCrasher>(), ItemType<ChaosStone>(), ItemType<CalamityRing>(), ItemType<Regenator>(), ItemID.BrokenHeroSword, ItemID.GreaterHealingPotion };
List<int> collection = new List<int>() { ItemType<CalamitasTrophy>(), ItemType<CataclysmTrophy>(), ItemType<CatastropheTrophy>(), ItemType<CalamitasMask>(), ItemType<KnowledgeCalamitasClone>() };
string instructions = $"Use an [i:{summon}] at Night";
string despawn = CalamityUtils.ColorMessage("If you wanted a fight, you should've came more prepared.", new Color(0xFF, 0xA5, 0x00));
@@ -427,7 +427,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("Ravager", out float order);
List<int> segments = new List<int>() { NPCType<RavagerBody>(), NPCType<RavagerClawLeft>(), NPCType<RavagerClawRight>(), NPCType<RavagerHead>(), NPCType<RavagerLegLeft>(), NPCType<RavagerLegRight>() };
int summon = ItemType<AncientMedallion>();
List<int> loot = new List<int>() { ItemType<RavagerBag>(), ItemType<FleshyGeodeT1>(), ItemType<FleshyGeodeT2>(), ItemType<UltimusCleaver>(), ItemType<RealmRavager>(), ItemType<Hematemesis>(), ItemType<SpikecragStaff>(), ItemType<CraniumSmasher>(), ItemType<CorpusAvertor>(), ItemType<BloodPact>(), ItemType<FleshTotem>(), ItemType<BloodflareCore>(), ItemType<InfernalBlood>(), ItemID.GreaterHealingPotion };
List<int> loot = new List<int>() { ItemType<RavagerBag>(), ItemType<FleshyGeodeT1>(), ItemType<FleshyGeodeT2>(), ItemType<UltimusCleaver>(), ItemType<RealmRavager>(), ItemType<Hematemesis>(), ItemType<SpikecragStaff>(), ItemType<CraniumSmasher>(), ItemType<CorpusAvertor>(), ItemType<BloodPact>(), ItemType<FleshTotem>(), ItemType<BloodflareCore>(), ItemType<Vesuvius>(), ItemType<InfernalBlood>(), ItemID.GreaterHealingPotion };
List<int> collection = new List<int>() { ItemType<RavagerTrophy>(), ItemType<RavagerMask>(), ItemType<KnowledgeRavager>() };
string instructions = $"Use a [i:{summon}]";
string despawn = CalamityUtils.ColorMessage("The automaton of misshapen victims went looking for the true perpetrator.", new Color(0xB2, 0x22, 0x22));
@@ -443,7 +443,7 @@ namespace CalamityMod
int summon2 = ItemType<Starcore>();
int altar = ItemType<AstralBeaconItem>();
List<int> summons = new List<int>() { summon1, summon2 };
List<int> loot = new List<int>() { ItemType<AstrumDeusBag>(), ItemType<Stardust>(), ItemID.FallenStar, ItemType<TheMicrowave>(), ItemType<StarSputter>(), ItemType<Starfall>(), ItemType<GodspawnHelixStaff>(), ItemType<RegulusRiot>(), ItemType<Quasar>(), ItemType<AstralBulwark>(), ItemType<HideofAstrumDeus>(), ItemID.FragmentSolar, ItemID.FragmentVortex, ItemID.FragmentNebula, ItemID.FragmentStardust, ItemID.GreaterHealingPotion };
List<int> loot = new List<int>() { ItemType<AstrumDeusBag>(), ItemType<Stardust>(), ItemID.FallenStar, ItemType<TheMicrowave>(), ItemType<StarSputter>(), ItemType<Starfall>(), ItemType<GodspawnHelixStaff>(), ItemType<RegulusRiot>(), ItemType<Quasar>(), ItemType<AstralBulwark>(), ItemType<HideofAstrumDeus>(), ItemType<TrueConferenceCall>(), ItemID.FragmentSolar, ItemID.FragmentVortex, ItemID.FragmentNebula, ItemID.FragmentStardust, ItemID.GreaterHealingPotion };
List<int> collection = new List<int>() { ItemType<AstrumDeusTrophy>(), ItemType<AstrumDeusMask>(), ItemType<KnowledgeAstrumDeus>(), ItemType<KnowledgeAstralInfection>(), ItemType<ChromaticOrb>() };
string instructions = $"Use a [i:{summon1}] or [i:{summon2}] as offering at an [i:{altar}]";
string despawn = CalamityUtils.ColorMessage("The infected deity retreats to the heavens.", new Color(0xFF, 0xD7, 0x00));
@@ -531,7 +531,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("Polterghast", out float order);
List<int> bosses = new List<int>() { NPCType<Polterghast>(), NPCType<PolterPhantom>() };
int summon = ItemType<NecroplasmicBeacon>();
List<int> loot = new List<int>() { ItemType<PolterghastBag>(), ItemType<RuinousSoul>(), ItemType<Phantoplasm>(), ItemType<TerrorBlade>(), ItemType<BansheeHook>(), ItemType<DaemonsFlame>(), ItemType<FatesReveal>(), ItemType<GhastlyVisage>(), ItemType<EtherealSubjugator>(), ItemType<GhoulishGouger>(), ItemType<Affliction>(), ItemType<Ectoheart>(), ItemType<SupremeHealingPotion>() };
List<int> loot = new List<int>() { ItemType<PolterghastBag>(), ItemType<RuinousSoul>(), ItemType<Phantoplasm>(), ItemType<TerrorBlade>(), ItemType<BansheeHook>(), ItemType<DaemonsFlame>(), ItemType<FatesReveal>(), ItemType<GhastlyVisage>(), ItemType<EtherealSubjugator>(), ItemType<GhoulishGouger>(), ItemType<Affliction>(), ItemType<PearlGod>(), ItemType<Ectoheart>(), ItemType<SupremeHealingPotion>() };
List<int> collection = new List<int>() { ItemType<PolterghastTrophy>(), ItemType<PolterghastMask>(), ItemType<KnowledgePolterghast>() };
string instructions = $"Kill 30 phantom spirits or use a [i:{summon}] in the Dungeon";
string despawn = CalamityUtils.ColorMessage("The volatile spirits disperse throughout the depths of the dungeon.", new Color(0xB0, 0xE0, 0xE6));
@@ -543,7 +543,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("OldDuke", out float order);
List<int> bosses = new List<int>() { NPCType<OldDuke>() };
int summon = ItemType<BloodwormItem>();
List<int> loot = new List<int>() { ItemType<OldDukeBag>(), ItemType<InsidiousImpaler>(), ItemType<SepticSkewer>(), ItemType<FetidEmesis>(), ItemType<VitriolicViper>(), ItemType<CadaverousCarrion>(), ItemType<ToxicantTwister>(), ItemType<DukeScales>(), ItemType<MutatedTruffle>(), ItemType<SupremeHealingPotion>() };
List<int> loot = new List<int>() { ItemType<OldDukeBag>(), ItemType<InsidiousImpaler>(), ItemType<SepticSkewer>(), ItemType<FetidEmesis>(), ItemType<VitriolicViper>(), ItemType<CadaverousCarrion>(), ItemType<ToxicantTwister>(), ItemType<DukeScales>(), ItemType<MutatedTruffle>(), ItemType<TheReaper>(), ItemType<SupremeHealingPotion>() };
List<int> collection = new List<int>() { ItemType<OldDukeTrophy>(), ItemType<OldDukeMask>(), ItemType<KnowledgeOldDuke>() };
string instructions = $"Defeat the Acid Rain event post-Polterghast or fish using a [i:{summon}] in the Sulphurous Sea";
string despawn = CalamityUtils.ColorMessage("The old duke disappears amidst the acidic downpour.", new Color(0xF0, 0xE6, 0x8C));
@@ -597,7 +597,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("SupremeCalamitas", out float order);
int type = NPCType<SupremeCalamitas>();
int summon = ItemType<EyeofExtinction>();
List<int> loot = new List<int>() { ItemType<SCalBag>(), ItemType<CalamitousEssence>(), ItemType<Vehemenc>(), ItemType<Heresy>(), ItemType<Perdition>(), ItemType<Vigilance>(), ItemType<Sacrifice>(), ItemType<Violence>(), ItemType<OmegaHealingPotion>() };
List<int> loot = new List<int>() { ItemType<SCalBag>(), ItemType<CalamitousEssence>(), ItemType<Vehemenc>(), ItemType<Heresy>(), ItemType<Perdition>(), ItemType<Vigilance>(), ItemType<Sacrifice>(), ItemType<Violence>(), ItemType<GaelsGreatsword>(), ItemType<OmegaHealingPotion>() };
List<int> collection = new List<int>() { ItemType<SupremeCalamitasTrophy>(), ItemType<AshenHorns>(), ItemType<SCalMask>(), ItemType<SCalRobes>(), ItemType<SCalBoots>(), ItemType<KnowledgeCalamitas>(), ItemType<BrimstoneJewel>(), ItemType<Levi>() };
string instructions = $"Use an [i:{summon}]";
string despawn = CalamityUtils.ColorMessage("Please don't waste my time.", new Color(0xFF, 0xA5, 0x00));
@@ -609,7 +609,7 @@ namespace CalamityMod
BossDifficulty.TryGetValue("AdultEidolonWyrm", out float order);
int type = NPCType<EidolonWyrmHeadHuge>();
int summon = ItemID.RodofDiscord;
List<int> loot = new List<int>() { ItemType<Voidstone>(), ItemType<Lumenite>(), ItemID.Ectoplasm, ItemType<EidolicWail>(), ItemType<SoulEdge>(), ItemType<HalibutCannon>() };
List<int> loot = new List<int>() { ItemType<Voidstone>(), ItemType<Lumenite>(), ItemID.Ectoplasm, ItemType<EidolicWail>(), ItemType<SoulEdge>(), ItemType<HalibutCannon>(), ItemType<OmegaHealingPotion>() };
List<int> collection = new List<int>() { };
string instructions = $"While in the Abyss, use an item that inflicts Chaos State";
string despawn = CalamityUtils.ColorMessage("...", new Color(0x7F, 0xFF, 0xD4));
@@ -692,7 +692,7 @@ namespace CalamityMod
// Queen Bee
AddLoot(bossChecklist, "QueenBee",
new List<int>() { ItemType<HardenedHoneycomb>(), ItemID.Stinger },
new List<int>() { ItemType<HardenedHoneycomb>(), ItemID.Stinger, ItemType<TheBee>() },
new List<int>() { ItemType<KnowledgeQueenBee>() }
);
@@ -704,13 +704,13 @@ namespace CalamityMod
// Wall of Flesh
AddLoot(bossChecklist, "WallofFlesh",
new List<int>() { ItemType<Meowthrower>(), ItemType<BlackHawkRemote>(), ItemType<BlastBarrel>(), ItemType<RogueEmblem>(), ItemType<MLGRune>(), ItemID.CorruptionKey, ItemID.CrimsonKey },
new List<int>() { ItemType<Meowthrower>(), ItemType<BlackHawkRemote>(), ItemType<BlastBarrel>(), ItemType<RogueEmblem>(), ItemType<EvilSmasher>(), ItemType<MLGRune>(), ItemID.CorruptionKey, ItemID.CrimsonKey },
new List<int>() { ItemType<KnowledgeWallofFlesh>(), ItemType<KnowledgeUnderworld>(), ItemType<IbarakiBox>() }
);
// The Twins
AddLoot(bossChecklist, "TheTwins",
null,
new List<int>() { ItemType<Arbalest>() },
new List<int>() { ItemType<KnowledgeTwins>(), ItemType<KnowledgeMechs>() }
);
@@ -722,20 +722,20 @@ namespace CalamityMod
// Skeletron Prime
AddLoot(bossChecklist, "SkeletronPrime",
null,
new List<int>() { ItemType<SpearofDestiny>(), ItemType<GoldBurdenBreaker>() },
new List<int>() { ItemType<KnowledgeSkeletronPrime>(), ItemType<KnowledgeMechs>() }
);
// Plantera
AddLoot(bossChecklist, "Plantera",
new List<int>() { ItemType<LivingShard>(), ItemType<BlossomFlux>(), ItemType<BloomStone>(), ItemID.JungleKey },
new List<int>() { ItemType<LivingShard>(), ItemType<BlossomFlux>(), ItemType<BloomStone>(), ItemID.JungleKey, ItemType<ThornBlossom>() },
new List<int>() { ItemType<KnowledgePlantera>() }
);
AddSummons(bossChecklist, "Plantera", new List<int>() { ItemType<BulbofDoom>() });
// Golem
AddLoot(bossChecklist, "Golem",
new List<int>() { ItemType<EssenceofCinder>(), ItemType<AegisBlade>() },
new List<int>() { ItemType<EssenceofCinder>(), ItemType<AegisBlade>(), ItemType<LeadWizard>() },
new List<int>() { ItemType<KnowledgeGolem>() }
);
AddSummons(bossChecklist, "Golem", new List<int>() { ItemType<OldPowerCell>() });
@@ -749,12 +749,12 @@ namespace CalamityMod
// Betsy
AddLoot(bossChecklist, "DD2Betsy",
null,
new List<int>() { ItemType<Vesuvius>() }
null
);
// Lunatic Cultist
AddLoot(bossChecklist, "CultistBoss",
new List<int>() { ItemType<StardustStaff>(), ItemType<ThornBlossom>() },
new List<int>() { ItemType<StardustStaff>(), ItemType<EyeofMagnus>() },
new List<int>() { ItemType<KnowledgeLunaticCultist>(), ItemType<KnowledgeBloodMoon>() }
);
AddSummons(bossChecklist, "CultistBoss", new List<int>() { ItemType<EidolonTablet>() });
@@ -770,7 +770,7 @@ namespace CalamityMod
{
// Blood Moon
AddLoot(bossChecklist, "Blood Moon",
new List<int>() { ItemType<BloodOrb>(), ItemType<BouncingEyeball>(), ItemType<Carnage>() },
new List<int>() { ItemType<BloodOrb>(), ItemType<BouncingEyeball>() },
null
);
AddSummons(bossChecklist, "Blood Moon", new List<int>() { ItemType<BloodIdol>() });
@@ -783,7 +783,7 @@ namespace CalamityMod
// Pirates
AddLoot(bossChecklist, "Pirate Invasion",
new List<int>() { ItemType<RaidersGlory>(), ItemType<Arbalest>(), ItemType<ProporsePistol>() },
new List<int>() { ItemType<RaidersGlory>(), ItemType<ProporsePistol>() },
null
);
@@ -825,7 +825,7 @@ namespace CalamityMod
// Lunar Events
AddLoot(bossChecklist, "Lunar Event",
new List<int>() { ItemType<MeldBlob>(), ItemType<TrueConferenceCall>() },
new List<int>() { ItemType<MeldBlob>() },
null
);
}
+30 -30
View File
@@ -3411,8 +3411,12 @@ namespace CalamityMod.NPCs
if (Main.projectile[i].type != bullseyeType || !Main.projectile[i].active || Main.projectile[i].owner != player.whoAmI)
continue;
bullseye = Main.projectile[i];
break;
// Only choose a bullseye if it is attached to the NPC that is being hit.
if (npc.whoAmI == (int)Main.projectile[i].ai[0])
{
bullseye = Main.projectile[i];
break;
}
}
// Don't allow large hitbox projectiles or explosions to "snipe" enemies.
@@ -3421,37 +3425,33 @@ namespace CalamityMod.NPCs
{
if (bullseye != null)
{
// Bullseyes are visually larger on bosses, so account for that.
float baseBullseyeRadius = npc.IsABoss() ? 116f : 54f;
bool hasCollidedWithBullseye;
// Bullseyes are visually different on bosses and thus have larger hitboxes.
float bullseyeRadius = npc.IsABoss() ? DaawnlightSpiritOrigin.BossBullseyeRadius : DaawnlightSpiritOrigin.RegularEnemyBullseyeRadius;
// Custom math to determine if a direction would hit a target if the hitbox would not delete the projectile before it can.
// This can be visualized as using the NPC center as an anchor point, determining the direction to the bullseye from that anchor point,
// calculating the maximum amount of angular error there can be before a hit would not happen, and checking if the projectile's direction
// to the bullseye is within that margin of error.
if (projectile.penetrate <= 1 && projectile.penetrate != -1)
{
// Directions to the bullseye relative to the NPC's center and the projectile that hit the NPC.
Vector2 directionToBullseye = projectile.SafeDirectionTo(bullseye.Center, Vector2.UnitY);
Vector2 bullseyeCenterOffsetDirection = npc.SafeDirectionTo(bullseye.Center);
// Do some geometry + trig to determine if the projectile WOULD hit the bullseye, even if it's about to be deleted on-hit.
// This is the equivalent of drawing a laser sight from the projectile along its velocity vector and seeing if it crosses the bullseye's hitbox.
// To do this more reliably, we back the projectile up quite a distance.
Vector2 normVelocity = projectile.velocity.SafeNormalize(Vector2.UnitY);
Vector2 backedUpPosition = projectile.Center - 160f * normVelocity;
Vector2 directionToBullseyeCenter = (bullseye.Center - backedUpPosition).SafeNormalize(Vector2.UnitY);
Vector2 perp = directionToBullseyeCenter.RotatedBy(MathHelper.PiOver2);
// Double the radius is given so that the cosine break-even point is right at the edge of the hitbox.
Vector2 comparisonPointOne = bullseye.Center + perp * 2f * bullseyeRadius;
Vector2 comparisonPointTwo = bullseye.Center - perp * 2f * bullseyeRadius;
Vector2 dirToPointOne = (comparisonPointOne - backedUpPosition).SafeNormalize(-Vector2.UnitX);
Vector2 dirToPointTwo = (comparisonPointTwo - backedUpPosition).SafeNormalize(Vector2.UnitX);
// Use SOH-CAH-TOA to compute the angle which is needed to reach the edge of the bullseye from the center of the NPC.
// The length of the hypotenuse is the distance from the center of the NPC to the bullseye while the opposite side length is
// the circular hitbox radius of the bullseye. These are sufficient to calculate the angular margin of error.
// If an NPC has a tiny hitbox the arcsine will fail and return NaN, meaning any hit at all will cause a bullseye to be hit.
// In these cases, simply set the "limit" to an extremely large value.
float angularOffsetToEdgeOfBullseye = (float)Math.Asin(baseBullseyeRadius / npc.Distance(bullseye.Center));
if (float.IsNaN(angularOffsetToEdgeOfBullseye))
angularOffsetToEdgeOfBullseye = 1000f;
float orthogonalityToBullseye = directionToBullseye.AngleBetween(bullseyeCenterOffsetDirection);
// Law of cosines: (A dot B) = |A| * |B| * cos(theta)
// where theta is the angle between the two vectors A and B.
// cos(theta) approaches one as the angle approaches zero, so an angle is smaller if the cos is bigger.
// If the angle to the bullseye's center is smaller than the angle to both the comparison points, it's a hit.
float dotCenter = Vector2.Dot(normVelocity, directionToBullseyeCenter);
float dotOne = Vector2.Dot(normVelocity, dirToPointOne);
float dotTwo = Vector2.Dot(normVelocity, dirToPointTwo);
bool willStrikeBullseye = dotCenter > dotOne && dotCenter > dotTwo;
hasCollidedWithBullseye = orthogonalityToBullseye < angularOffsetToEdgeOfBullseye;
}
else
hasCollidedWithBullseye = projectile.WithinRange(bullseye.Center, bullseye.scale * baseBullseyeRadius);
// Do a very high amount of damage if hitting a bullseye.
if (hasCollidedWithBullseye && bullseye.ai[1] == 0f)
// If a bullseye is triggered, set it as hit.
if (willStrikeBullseye && bullseye.ai[1] == 0f)
{
crit = true;
hitBullseye = true;
+1
View File
@@ -126,6 +126,7 @@ namespace CalamityMod.NPCs
private static readonly string[] StylistNames =
{
"Amber", // <@!114677116473180169> (Mishiro Usui#1295)
"Faith", // <@!509050283871961123> (Toasty#1007)
};
private const int TavernkeepVanillaNames = 16;
private static readonly string[] TavernkeepNames =
+1 -1
View File
@@ -142,7 +142,7 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
npc.DeathSound = SoundID.NPCDeath14;
npc.netAlways = true;
npc.boss = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
bossBag = ModContent.ItemType<DraedonTreasureBag>();
}
+1 -1
View File
@@ -140,7 +140,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
npc.DeathSound = SoundID.NPCDeath14;
npc.netAlways = true;
npc.boss = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
bossBag = ModContent.ItemType<DraedonTreasureBag>();
}
+1 -1
View File
@@ -84,7 +84,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
npc.netAlways = true;
npc.boss = true;
npc.hide = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
}
public override void SendExtraAI(BinaryWriter writer)
+1 -1
View File
@@ -82,7 +82,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
npc.netAlways = true;
npc.boss = true;
npc.hide = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
}
public override void SendExtraAI(BinaryWriter writer)
+1 -1
View File
@@ -82,7 +82,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
npc.netAlways = true;
npc.boss = true;
npc.hide = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
}
public override void SendExtraAI(BinaryWriter writer)
+1 -1
View File
@@ -82,7 +82,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
npc.netAlways = true;
npc.boss = true;
npc.hide = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
}
public override void SendExtraAI(BinaryWriter writer)
+1 -1
View File
@@ -153,7 +153,7 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
npc.DeathSound = SoundID.NPCDeath14;
npc.netAlways = true;
npc.boss = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
}
public override void BossHeadSlot(ref int index)
+1 -1
View File
@@ -361,7 +361,7 @@ namespace CalamityMod.NPCs.ExoMechs
if (!ExoMechIsPresent && DefeatTimer <= 0f)
music = mod.GetSoundSlot(SoundType.Music, "Sounds/Music/DraedonAmbience");
if (ExoMechIsPresent)
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
TalkTimer++;
}
+1 -1
View File
@@ -74,7 +74,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
npc.dontCountMe = true;
npc.chaseable = false;
npc.boss = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
}
public override void BossHeadSlot(ref int index)
+1 -1
View File
@@ -74,7 +74,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
npc.dontCountMe = true;
npc.chaseable = false;
npc.boss = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
}
public override void BossHeadSlot(ref int index)
+1 -1
View File
@@ -138,7 +138,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
npc.netAlways = true;
npc.boss = true;
npc.chaseable = false;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
bossBag = ModContent.ItemType<DraedonTreasureBag>();
}
+1 -1
View File
@@ -74,7 +74,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
npc.dontCountMe = true;
npc.chaseable = false;
npc.boss = true;
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
music = CalamityMod.Instance.GetMusicFromMusicMod("ExoMechs") ?? MusicID.Boss3;
}
public override void BossHeadSlot(ref int index)
+1 -1
View File
@@ -2280,7 +2280,7 @@ namespace CalamityMod.Projectiles
}
if (modPlayer.flamingItemEnchant && !projectile.minion && !projectile.npcProj)
target.AddBuff(BuffType<VulnerabilityHex>(), 120);
target.AddBuff(BuffType<VulnerabilityHex>(), VulnerabilityHex.AflameDuration);
if (modPlayer.farProximityRewardEnchant)
{
+4 -1
View File
@@ -1,3 +1,4 @@
using CalamityMod.Items.Accessories;
using CalamityMod.Tiles.AstralDesert;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
@@ -22,7 +23,7 @@ namespace CalamityMod.Projectiles.Typeless
public override string Texture => "CalamityMod/Projectiles/InvisibleProj";
public override void SetDefaults()
{
projectile.width = projectile.height = 2;
projectile.width = projectile.height = (int)(2 * DaawnlightSpiritOrigin.RegularEnemyBullseyeRadius);
projectile.aiStyle = -1;
projectile.friendly = false;
projectile.hostile = false;
@@ -85,6 +86,8 @@ namespace CalamityMod.Projectiles.Typeless
bullseyeTexture = ModContent.GetTexture("CalamityMod/ExtraTextures/DaawnlightSpiritOriginBossBullseye");
frame = bullseyeTexture.Frame(1, 4, 0, (int)(Main.GlobalTime * 7f) % 4);
rotation = 0f;
drawPosition.Y -= 17;
drawPosition.X -= 1;
}
spriteBatch.Draw(bullseyeTexture, drawPosition, frame, Color.White * projectile.Opacity, rotation, frame.Size() * 0.5f, scale, SpriteEffects.None, 0f);
@@ -4,7 +4,7 @@ using Terraria.ModLoader;
namespace CalamityMod.Sounds.Custom
{
public class AdrenalineBurnout2 : ModSound
public class AdrenalineActivate : ModSound
{
public override SoundEffectInstance PlaySound(ref SoundEffectInstance soundInstance, float volume, float pan, SoundType type)
{
Binary file not shown.
Binary file not shown.
@@ -4,7 +4,7 @@ using Terraria.ModLoader;
namespace CalamityMod.Sounds.Custom
{
public class AdrenalineBurnout1 : ModSound
public class AndromedaCripple : ModSound
{
public override SoundEffectInstance PlaySound(ref SoundEffectInstance soundInstance, float volume, float pan, SoundType type)
{
File renamed without changes.
+18
View File
@@ -0,0 +1,18 @@
using Microsoft.Xna.Framework.Audio;
using Terraria;
using Terraria.ModLoader;
namespace CalamityMod.Sounds.Custom
{
public class RageActivate : ModSound
{
public override SoundEffectInstance PlaySound(ref SoundEffectInstance soundInstance, float volume, float pan, SoundType type)
{
soundInstance = sound.CreateInstance();
soundInstance.Volume = volume * 1f;
soundInstance.Pan = pan;
Main.PlaySoundInstance(soundInstance);
return soundInstance;
}
}
}
Binary file not shown.
+18
View File
@@ -0,0 +1,18 @@
using Microsoft.Xna.Framework.Audio;
using Terraria;
using Terraria.ModLoader;
namespace CalamityMod.Sounds.Custom
{
public class RageEnd : ModSound
{
public override SoundEffectInstance PlaySound(ref SoundEffectInstance soundInstance, float volume, float pan, SoundType type)
{
soundInstance = sound.CreateInstance();
soundInstance.Volume = volume * 1f;
soundInstance.Pan = pan;
Main.PlaySoundInstance(soundInstance);
return soundInstance;
}
}
}
Binary file not shown.
Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 537 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 639 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 297 B

After

Width:  |  Height:  |  Size: 330 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 591 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 618 B

After

Width:  |  Height:  |  Size: 519 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 275 B

After

Width:  |  Height:  |  Size: 228 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 320 B

After

Width:  |  Height:  |  Size: 249 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 194 B

After

Width:  |  Height:  |  Size: 141 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 450 B

After

Width:  |  Height:  |  Size: 342 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 757 B

After

Width:  |  Height:  |  Size: 732 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 321 B

After

Width:  |  Height:  |  Size: 264 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 977 B

After

Width:  |  Height:  |  Size: 612 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 250 B

After

Width:  |  Height:  |  Size: 291 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 945 B

After

Width:  |  Height:  |  Size: 630 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 334 B

After

Width:  |  Height:  |  Size: 255 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 633 B

After

Width:  |  Height:  |  Size: 336 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 209 B

After

Width:  |  Height:  |  Size: 267 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 606 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 304 B

After

Width:  |  Height:  |  Size: 336 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 672 B

After

Width:  |  Height:  |  Size: 450 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 204 B

After

Width:  |  Height:  |  Size: 186 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 469 B

After

Width:  |  Height:  |  Size: 405 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 243 B

After

Width:  |  Height:  |  Size: 186 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 492 B

After

Width:  |  Height:  |  Size: 348 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 279 B

After

Width:  |  Height:  |  Size: 174 B

Loaded 100 of 109 files, more files were not shown because too many files have changed in this diff. Show more