using System; using System.Collections.Generic; using CalamityMod.NPCs.AcidRain; using CalamityMod.NPCs.AquaticScourge; using CalamityMod.NPCs.AstrumAureus; using CalamityMod.NPCs.AstrumDeus; using CalamityMod.NPCs.BrimstoneElemental; using CalamityMod.NPCs.Bumblebirb; using CalamityMod.NPCs.CalClone; using CalamityMod.NPCs.CeaselessVoid; using CalamityMod.NPCs.Crabulon; using CalamityMod.NPCs.Cryogen; using CalamityMod.NPCs.DesertScourge; using CalamityMod.NPCs.DevourerofGods; using CalamityMod.NPCs.ExoMechs.Apollo; using CalamityMod.NPCs.ExoMechs.Ares; using CalamityMod.NPCs.ExoMechs.Artemis; using CalamityMod.NPCs.ExoMechs.Thanatos; using CalamityMod.NPCs.HiveMind; using CalamityMod.NPCs.Leviathan; using CalamityMod.NPCs.NormalNPCs; using CalamityMod.NPCs.OldDuke; using CalamityMod.NPCs.Perforator; using CalamityMod.NPCs.PlaguebringerGoliath; using CalamityMod.NPCs.Polterghast; using CalamityMod.NPCs.PrimordialWyrm; using CalamityMod.NPCs.ProfanedGuardians; using CalamityMod.NPCs.Providence; using CalamityMod.NPCs.Ravager; using CalamityMod.NPCs.Signus; using CalamityMod.NPCs.SlimeGod; using CalamityMod.NPCs.StormWeaver; using CalamityMod.NPCs.SupremeCalamitas; using CalamityMod.NPCs.Yharon; using CalamityMod.Projectiles.Boss; using CalamityMod.Projectiles.Enemy; using CalamityMod.World; using Terraria; using Terraria.ID; using Terraria.ModLoader; namespace CalamityMod { // TODO -- This can be made into a ModSystem with simple OnModLoad and Unload hooks. public static partial class NPCStats { private const double ExpertContactVanillaMultiplier = 2D; private const double MasterContactVanillaMultiplier = 3D; private const double NormalProjectileVanillaMultiplier = 2D; private const double ExpertProjectileVanillaMultiplier = 4D; private const double MasterProjectileVanillaMultiplier = 6D; #region Enemy Stats Container Struct internal partial struct EnemyStats { public static SortedDictionary ExpertDamageMultiplier; public static SortedDictionary ContactDamageValues; public static SortedDictionary, int[]> ProjectileDamageValues; }; #endregion #region Stat Retrieval Methods public static void GetNPCDamage(this NPC npc) { double damageAdjustment = GetExpertDamageMultiplier(npc) * (Main.masterMode ? MasterContactVanillaMultiplier : ExpertContactVanillaMultiplier); // Safety check: If for some reason the contact damage array is not initialized yet, set the NPC's damage to 1. bool exists = EnemyStats.ContactDamageValues.TryGetValue(npc.type, out int[] output); if (!exists) { npc.damage = 1; return; } int[] contactDamage = new int[4]; if (output.Length == 1) { contactDamage[0] = output[0]; contactDamage[1] = output[0] * 2; contactDamage[2] = output[0] * 2; contactDamage[3] = output[0] * 3; } else if (output.Length == 2) { contactDamage[0] = output[0]; contactDamage[1] = output[1]; contactDamage[2] = output[1]; contactDamage[3] = (int)(output[1] * 1.5f); } else if (output.Length == 4) contactDamage = output; int normalDamage = contactDamage[0]; int expertDamage = contactDamage[1] == -1 ? -1 : (int)Math.Round(contactDamage[1] / damageAdjustment); int revengeanceDamage = contactDamage[2] == -1 ? -1 : (int)Math.Round(contactDamage[2] / damageAdjustment); int masterDamage = contactDamage[3] == -1 ? -1 : (int)Math.Round(contactDamage[3] / damageAdjustment); // If the assigned value would be -1, don't actually assign it. This allows for conditionally disabling the system. int damageToUse = Main.masterMode ? masterDamage : CalamityWorld.revenge ? revengeanceDamage : Main.expertMode ? expertDamage : normalDamage; if (damageToUse != -1) npc.damage = damageToUse; } // Gets the amount of damage a given projectile should do from this NPC. // Automatically compensates for Terraria's internal spaghetti scaling. public static int GetProjectileDamage(this NPC npc, int projType) { double damageAdjustment = Main.masterMode ? MasterProjectileVanillaMultiplier : Main.expertMode ? ExpertProjectileVanillaMultiplier : NormalProjectileVanillaMultiplier; // Safety check: If for some reason the projectile damage array is not initialized yet, return 1. bool exists = EnemyStats.ProjectileDamageValues.TryGetValue(new Tuple(npc.type, projType), out int[] output); if (!exists) return 1; int[] projectileDamage = new int[4]; if (output.Length == 1) { projectileDamage[0] = output[0]; projectileDamage[1] = output[0] * 2; projectileDamage[2] = output[0] * 2; projectileDamage[3] = output[0] * 3; } else if (output.Length == 2) { projectileDamage[0] = output[0]; projectileDamage[1] = output[1]; projectileDamage[2] = output[1]; projectileDamage[3] = (int)(output[1] * 1.5f); } else if (output.Length == 4) projectileDamage = output; int normalDamage = (int)Math.Round(projectileDamage[0] / damageAdjustment); int expertDamage = (int)Math.Round(projectileDamage[1] / damageAdjustment); int revengeanceDamage = (int)Math.Round(projectileDamage[2] / damageAdjustment); int masterDamage = (int)Math.Round(projectileDamage[3] / damageAdjustment); int damageToUse = Main.masterMode ? masterDamage : CalamityWorld.revenge ? revengeanceDamage : Main.expertMode ? expertDamage : normalDamage; return damageToUse; } // Gets the amount of damage this projectile should do from a given NPC. // Automatically compensates for Terraria's internal spaghetti scaling. public static int GetProjectileDamage(this Projectile projectile, int npcType) { double damageAdjustment = Main.masterMode ? MasterProjectileVanillaMultiplier : Main.expertMode ? ExpertProjectileVanillaMultiplier : NormalProjectileVanillaMultiplier; // Safety check: If for some reason the projectile damage array is not initialized yet, return 1. bool exists = EnemyStats.ProjectileDamageValues.TryGetValue(new Tuple(npcType, projectile.type), out int[] output); if (!exists) return 1; int[] projectileDamage = new int[4]; if (output.Length == 1) { projectileDamage[0] = output[0]; projectileDamage[1] = output[0] * 2; projectileDamage[2] = output[0] * 2; projectileDamage[3] = output[0] * 3; } else if (output.Length == 2) { projectileDamage[0] = output[0]; projectileDamage[1] = output[1]; projectileDamage[2] = output[1]; projectileDamage[3] = (int)(output[1] * 1.5f); } else if (output.Length == 4) projectileDamage = output; int normalDamage = (int)Math.Round(projectileDamage[0] / damageAdjustment); int expertDamage = (int)Math.Round(projectileDamage[1] / damageAdjustment); int revengeanceDamage = (int)Math.Round(projectileDamage[2] / damageAdjustment); int masterDamage = (int)Math.Round(projectileDamage[3] / damageAdjustment); int damageToUse = Main.masterMode ? masterDamage : CalamityWorld.revenge ? revengeanceDamage : Main.expertMode ? expertDamage : normalDamage; return damageToUse; } // Gets the raw amount of damage a projectile should do from this NPC. // That is, this doesn't adjust the value to compensate for Terraria's internal spaghetti scaling. public static int GetProjectileDamageNoScaling(this NPC npc, int projType) { bool exists = EnemyStats.ProjectileDamageValues.TryGetValue(new Tuple(npc.type, projType), out int[] output); if (!exists) return 1; int[] projectileDamage = new int[4]; if (output.Length == 1) { projectileDamage[0] = output[0]; projectileDamage[1] = output[0] * 2; projectileDamage[2] = output[0] * 2; projectileDamage[3] = output[0] * 3; } else if (output.Length == 2) { projectileDamage[0] = output[0]; projectileDamage[1] = output[1]; projectileDamage[2] = output[1]; projectileDamage[3] = (int)(output[1] * 1.5f); } else if (output.Length == 4) projectileDamage = output; return Main.masterMode ? projectileDamage[3] : CalamityWorld.revenge ? projectileDamage[2] : Main.expertMode ? projectileDamage[1] : projectileDamage[0]; } /// /// Gets the Expert/Master Mode damage multiplier for the specified boss NPC. /// Useful for determining the base damage a boss NPC should have prior to being run through the Expert/Master scaling code. /// /// The NPC you want to get the damage multiplier for /// Whether Master Mode is enabled or not /// public static double GetExpertDamageMultiplier(this NPC npc, bool? master = null) { bool exists = EnemyStats.ExpertDamageMultiplier.TryGetValue(npc.type, out double damageMult); return exists ? damageMult : 1D; } #endregion #region Load/Unload internal static void Load() { LoadEnemyStats(); LoadDebuffs(); } internal static void Unload() { UnloadEnemyStats(); UnloadDebuffs(); } // A static function, called exactly once, which initializes the EnemyStats struct at a predictable time. // This is necessary to ensure this dictionary is populated as early as possible. internal static void LoadEnemyStats() { EnemyStats.ExpertDamageMultiplier = new SortedDictionary { { NPCID.KingSlime, 0.8 }, { ModContent.NPCType(), 1.1 }, { ModContent.NPCType(), 0.8 }, { NPCID.EaterofWorldsHead, 1.1 }, { NPCID.EaterofWorldsBody, 0.8 }, { NPCID.EaterofWorldsTail, 0.8 }, { NPCID.BrainofCthulhu, 0.9 }, { ModContent.NPCType(), 0.9 }, { ModContent.NPCType(), 0.9 }, { NPCID.QueenBee, 0.9 }, { NPCID.Bee, 0.6 }, { NPCID.BeeSmall, 0.6 }, { NPCID.SkeletronHead, 1.1 }, { NPCID.SkeletronHand, 1.1 }, { NPCID.WallofFlesh, 1.5 }, { NPCID.WallofFleshEye, 1.5 }, { ModContent.NPCType(), 1.15 }, { NPCID.Spazmatism, 0.85 }, { NPCID.Retinazer, 0.85 }, { ModContent.NPCType(), 1.1 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { NPCID.TheDestroyer, 2 }, { NPCID.TheDestroyerBody, 0.85 }, { NPCID.TheDestroyerTail, 0.85 }, { ModContent.NPCType(), 0.8 }, { NPCID.SkeletronPrime, 0.85 }, { NPCID.PrimeCannon, 0.85 }, { NPCID.PrimeLaser, 0.85 }, { NPCID.PrimeSaw, 0.85 }, { NPCID.PrimeVice, 0.85 }, { ModContent.NPCType(), 0.8 }, { NPCID.Plantera, 1.15 }, { NPCID.PlanterasTentacle, 1.15 }, { ModContent.NPCType(), 1.15 }, { NPCID.HallowBoss, 0.6875 }, { ModContent.NPCType(), 1.2 }, { ModContent.NPCType(), 0.8 }, { NPCID.DetonatingBubble, 0.75 }, { ModContent.NPCType(), 1.1 }, { NPCID.Golem, 0.8 }, { NPCID.GolemHead, 0.8 }, { NPCID.GolemFistLeft, 0.8 }, { NPCID.GolemFistRight, 0.8 }, { ModContent.NPCType(), 0.9 }, { NPCID.DukeFishron, 0.7 }, { NPCID.Sharkron, 0.75 }, { NPCID.Sharkron2, 0.75 }, { ModContent.NPCType(), 0.8 }, { NPCID.CultistDragonHead, 0.75 }, { NPCID.CultistDragonBody1, 0.75 }, { NPCID.CultistDragonBody2, 0.75 }, { NPCID.CultistDragonBody3, 0.75 }, { NPCID.CultistDragonBody4, 0.75 }, { NPCID.CultistDragonTail, 0.75 }, { NPCID.AncientDoom, 0.75 }, { NPCID.AncientLight, 0.75 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.9 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.9 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.85 }, { ModContent.NPCType(), 0.85 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 }, { ModContent.NPCType(), 0.8 } }; EnemyStats.ContactDamageValues = new SortedDictionary { { NPCID.KingSlime, new int[] { 40, 64 } }, { ModContent.NPCType(), new int[] { 30, 48 } }, { ModContent.NPCType(), new int[] { 44, 70 } }, { ModContent.NPCType(), new int[] { 20, 36 } }, { ModContent.NPCType(), new int[] { 15 } }, { ModContent.NPCType(), new int[] { 25, 40 } }, { ModContent.NPCType(), new int[] { 16 } }, { ModContent.NPCType(), new int[] { 10 } }, { ModContent.NPCType(), new int[] { 25, 40 } }, { ModContent.NPCType(), new int[] { 16 } }, { ModContent.NPCType(), new int[] { 10 } }, { NPCID.EyeofCthulhu, new int[] { 15 } }, // Phase 2: 23, 36 + Phase 3 (Expert): 40 { NPCID.ServantofCthulhu, new int[] { 12 } }, { ModContent.NPCType(), new int[] { 40, 64 } }, { ModContent.NPCType(), new int[] { 25, 40 } }, { NPCID.EaterofWorldsHead, new int[] { 22, 48 } }, { NPCID.EaterofWorldsBody, new int[] { 13, 20 } }, { NPCID.EaterofWorldsTail, new int[] { 11, 17 } }, { NPCID.VileSpitEaterOfWorlds, new int[] { -1, 64 } }, { NPCID.BrainofCthulhu, new int[] { 30, 54 } }, { NPCID.Creeper, new int[] { 20, 36 } }, { ModContent.NPCType(), new int[] { 40, 64 } }, { ModContent.NPCType(), new int[] { 30, 48 } }, { ModContent.NPCType(), new int[] { 30, 54 } }, { ModContent.NPCType(), new int[] { 40, 88 } }, { ModContent.NPCType(), new int[] { 23, 40 } }, { ModContent.NPCType(), new int[] { 20, 32 } }, { ModContent.NPCType(), new int[] { 24, 72 } }, { ModContent.NPCType(), new int[] { 18, 28 } }, { ModContent.NPCType(), new int[] { 16, 25 } }, { ModContent.NPCType(), new int[] { 20, 60 } }, { ModContent.NPCType(), new int[] { 14, 22 } }, { ModContent.NPCType(), new int[] { 12, 19 } }, { NPCID.QueenBee, new int[] { 30, 54 } }, { NPCID.Bee, new int[] { 20, 24 } }, { NPCID.BeeSmall, new int[] { 15, 18 } }, { NPCID.SkeletronHead, new int[] { 32, 70 } }, // Spinning: 41, 91 { NPCID.SkeletronHand, new int[] { 20, 44 } }, { NPCID.Deerclops, new int[] { 20 } }, { ModContent.NPCType(), new int[] { 40 } }, { ModContent.NPCType(), new int[] { 45 } }, { ModContent.NPCType(), new int[] { 40 } }, { ModContent.NPCType(), new int[] { 50 } }, { ModContent.NPCType(), new int[] { 45 } }, { ModContent.NPCType(), new int[] { 30 } }, { ModContent.NPCType(), new int[] { 20 } }, { ModContent.NPCType(), new int[] { 35 } }, { ModContent.NPCType(), new int[] { 25 } }, { NPCID.WallofFlesh, new int[] { 50, 150 } }, { NPCID.WallofFleshEye, new int[] { 50, 150 } }, { NPCID.TheHungry, new int[] { 30 } }, // Scales up to 60 as health lowers { NPCID.TheHungryII, new int[] { 30 } }, { NPCID.LeechHead, new int[] { 26 } }, { NPCID.LeechBody, new int[] { 22 } }, { NPCID.LeechTail, new int[] { 18 } }, { NPCID.QueenSlimeBoss, new int[] { 60 } }, { NPCID.QueenSlimeMinionBlue, new int[] { 40 } }, { NPCID.QueenSlimeMinionPink, new int[] { 40 } }, { NPCID.QueenSlimeMinionPurple, new int[] { 50 } }, { ModContent.NPCType(), new int[] { 69 } }, { ModContent.NPCType(), new int[] { 60 } }, { NPCID.Spazmatism, new int[] { 50, 85 } }, // Phase 2: 75, 127 { NPCID.Retinazer, new int[] { 45, 76 } }, // Phase 2: 67, 114 { ModContent.NPCType(), new int[] { 70, 176 } }, { ModContent.NPCType(), new int[] { 65, 112 } }, { ModContent.NPCType(), new int[] { 60, 104 } }, { ModContent.NPCType(), new int[] { 48, 81 } }, { NPCID.TheDestroyer, new int[] { 70, 280 } }, { NPCID.TheDestroyerBody, new int[] { 55, 93 } }, { NPCID.TheDestroyerTail, new int[] { 40, 68 } }, { ModContent.NPCType(), new int[] { 65, 112 } }, { NPCID.SkeletronPrime, new int[] { 47, 79 } }, // Spinning: 94, 158 { NPCID.PrimeVice, new int[] { 52, 88 } }, { NPCID.PrimeSaw, new int[] { 56, 95 } }, { NPCID.PrimeCannon, new int[] { 30, 49 } }, { NPCID.PrimeLaser, new int[] { 29, 51 } }, { ModContent.NPCType(), new int[] { 60 } }, { ModContent.NPCType(), new int[] { 50 } }, { ModContent.NPCType(), new int[] { 55 } }, { NPCID.Plantera, new int[] { 50 } }, // Phase 2: 70 { NPCID.PlanterasTentacle, new int[] { 60, 138 } }, { ModContent.NPCType(), new int[] { 60, 138 } }, { NPCID.Spore, new int[] { 70 } }, { NPCID.HallowBoss, new int[] { 80, 110 } }, // Dash: 120, 165 { ModContent.NPCType(), new int[] { 105 } }, { ModContent.NPCType(), new int[] { 75, 110 } }, // Dash: 113, 165 { ModContent.NPCType(), new int[] { 60, 90 } }, { NPCID.DetonatingBubble, new int[] { 100, 150 } }, { ModContent.NPCType(), new int[] { 70 } }, { ModContent.NPCType(), new int[] { 105 } }, { ModContent.NPCType(), new int[] { 75, 110 } }, { NPCID.Golem, new int[] { 72, 115 } }, { NPCID.GolemHead, new int[] { 64, 102 } }, { NPCID.GolemFistLeft, new int[] { 59, 94 } }, { NPCID.GolemFistRight, new int[] { 59, 94 } }, { ModContent.NPCType(), new int[] { 120, 180 } }, { ModContent.NPCType(), new int[] { 100, 150 } }, { ModContent.NPCType(), new int[] { 120, 180 } }, { NPCID.DukeFishron, new int[] { 100, 140 } }, // Phase 2: 120, 201 + Phase 3 (Expert): 184 { NPCID.Sharkron, new int[] { 100, 150 } }, { NPCID.Sharkron2, new int[] { 120, 180 } }, { ModContent.NPCType(), new int[] { 120, 180 } }, { ModContent.NPCType(), new int[] { 100, 150 } }, { ModContent.NPCType(), new int[] { 100, 150 } }, { ModContent.NPCType(), new int[] { 120, 180 } }, { ModContent.NPCType(), new int[] { 100, 150 } }, { NPCID.CultistDragonHead, new int[] { 100, 150 } }, { NPCID.CultistDragonBody1, new int[] { 50, 75 } }, { NPCID.CultistDragonBody2, new int[] { 50, 75 } }, { NPCID.CultistDragonBody3, new int[] { 50, 75 } }, { NPCID.CultistDragonBody4, new int[] { 50, 75 } }, { NPCID.CultistDragonTail, new int[] { 50, 75 } }, { NPCID.AncientCultistSquidhead, new int[] { 90 } }, { NPCID.AncientLight, new int[] { 120, 180 } }, { ModContent.NPCType(), new int[] { 120 } }, { ModContent.NPCType(), new int[] { 80 } }, { ModContent.NPCType(), new int[] { 64 } }, { ModContent.NPCType(), new int[] { 110 } }, { ModContent.NPCType(), new int[] { 110 } }, { ModContent.NPCType(), new int[] { 100 } }, { ModContent.NPCType(), new int[] { 100 } }, { ModContent.NPCType(), new int[] { 120 } }, { ModContent.NPCType(), new int[] { 110 } }, { ModContent.NPCType(), new int[] { 180 } }, { ModContent.NPCType(), new int[] { 120 } }, { ModContent.NPCType(), new int[] { 180 } }, { ModContent.NPCType(), new int[] { 96 } }, { ModContent.NPCType(), new int[] { 80 } }, { ModContent.NPCType(), new int[] { 160 } }, { ModContent.NPCType(), new int[] { 120 } }, { ModContent.NPCType(), new int[] { 140 } }, { ModContent.NPCType(), new int[] { 120 } }, // Phase 2: 144 + Phase 3: 168 { ModContent.NPCType(), new int[] { 168 } }, { ModContent.NPCType(), new int[] { 140 } }, // Phase 2: 154 + Phase 3: 168 { ModContent.NPCType(), new int[] { 120 } }, { ModContent.NPCType(), new int[] { 120 } }, { ModContent.NPCType(), new int[] { 250 } }, { ModContent.NPCType(), new int[] { 150 } }, { ModContent.NPCType(), new int[] { 100 } }, { ModContent.NPCType(), new int[] { 180 } }, { ModContent.NPCType(), new int[] { 120 } }, { ModContent.NPCType(), new int[] { 90 } }, { ModContent.NPCType(), new int[] { 200 } }, { ModContent.NPCType(), new int[] { 240 } }, { ModContent.NPCType(), new int[] { 240 } }, { ModContent.NPCType(), new int[] { 200 } }, { ModContent.NPCType(), new int[] { 270 } }, { ModContent.NPCType(), new int[] { 180 } }, { ModContent.NPCType(), new int[] { 180 } }, { ModContent.NPCType(), new int[] { 150 } }, { ModContent.NPCType(), new int[] { 300 } } }; EnemyStats.ProjectileDamageValues = new SortedDictionary, int[]> { { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 18 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 18 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 18 } }, { new Tuple(NPCID.EyeofCthulhu, ProjectileID.BloodNautilusShot), new int[] { 15 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 22 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 22 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 22 } }, { new Tuple(NPCID.EaterofWorldsHead, ProjectileID.CursedFlameHostile), new int[] { 22 } }, { new Tuple(NPCID.EaterofWorldsHead, ModContent.ProjectileType()), new int[] { 22 } }, { new Tuple(NPCID.BrainofCthulhu, ProjectileID.BloodNautilusShot), new int[] { 22 } }, { new Tuple(NPCID.BrainofCthulhu, ProjectileID.BloodShot), new int[] { 15 } }, { new Tuple(NPCID.Creeper, ProjectileID.BloodShot), new int[] { 15 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 16 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 16 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 22 } }, { new Tuple(NPCID.QueenBee, ProjectileID.QueenBeeStinger), new int[] { 22 } }, { new Tuple(NPCID.QueenBee, ModContent.ProjectileType()), new int[] { 36 } }, // Beenade Bees (Death): 92 { new Tuple(NPCID.SkeletronHead, ProjectileID.Skull), new int[] { 34 } }, { new Tuple(NPCID.SkeletronHead, ProjectileID.Shadowflames), new int[] { 40 } }, { new Tuple(NPCID.SkeletronHand, ProjectileID.Skull), new int[] { 34 } }, { new Tuple(NPCID.Deerclops, ProjectileID.DeerclopsIceSpike), new int[] { 26 } }, { new Tuple(NPCID.Deerclops, ProjectileID.DeerclopsRangedProjectile), new int[] { 36 } }, { new Tuple(NPCID.Deerclops, ProjectileID.InsanityShadowHostile), new int[] { 20 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 30 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 30 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 30 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 30 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 42 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 30 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 30 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 34 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 24 } }, { new Tuple(NPCID.WallofFleshEye, ProjectileID.EyeLaser), new int[] { 22 } }, // Scales up to 30 as health lowers { new Tuple(NPCID.WallofFlesh, ProjectileID.DemonSickle), new int[] { 45 } }, { new Tuple(NPCID.WallofFlesh, ProjectileID.Fireball), new int[] { 36 } }, { new Tuple(NPCID.QueenSlimeBoss, ProjectileID.QueenSlimeGelAttack), new int[] { 60 } }, { new Tuple(NPCID.QueenSlimeBoss, ProjectileID.QueenSlimeSmash), new int[] { 80 } }, { new Tuple(NPCID.QueenSlimeBoss, ProjectileID.QueenSlimeMinionBlueSpike), new int[] { 30 } }, { new Tuple(NPCID.QueenSlimeMinionBlue, ProjectileID.QueenSlimeMinionBlueSpike), new int[] { 30 } }, { new Tuple(NPCID.QueenSlimeMinionPink, ProjectileID.QueenSlimeMinionPinkBall), new int[] { 30 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 45 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 45 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 45 } }, { new Tuple(NPCID.Retinazer, ProjectileID.EyeLaser), new int[] { 40, 76 } }, { new Tuple(NPCID.Retinazer, ProjectileID.DeathLaser), new int[] { 50, 92 } }, // Rapid fire: 36, 68 { new Tuple(NPCID.Retinazer, ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(NPCID.Spazmatism, ProjectileID.CursedFlameHostile), new int[] { 50, 88 } }, { new Tuple(NPCID.Spazmatism, ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(NPCID.Spazmatism, ModContent.ProjectileType()), new int[] { 70, 120 } }, { new Tuple(NPCID.Spazmatism, ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 50, 92 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 70, 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 80, 140 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 50, 92 } }, { new Tuple(NPCID.TheDestroyer, ProjectileID.DeathLaser), new int[] { 44, 72 } }, { new Tuple(NPCID.TheDestroyer, ModContent.ProjectileType()), new int[] { 44, 72 } }, { new Tuple(NPCID.TheDestroyer, ModContent.ProjectileType()), new int[] { 44, 72 } }, { new Tuple(NPCID.TheDestroyerBody, ProjectileID.DeathLaser), new int[] { 44, 72 } }, { new Tuple(NPCID.TheDestroyerBody, ModContent.ProjectileType()), new int[] { 44, 72 } }, { new Tuple(NPCID.TheDestroyerBody, ModContent.ProjectileType()), new int[] { 44, 72 } }, { new Tuple(NPCID.Probe, ProjectileID.PinkLaser), new int[] { 50, 88 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 50, 92 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 80, 200 } }, // Split shots: 48, 120 { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 50, 92 } }, { new Tuple(NPCID.SkeletronPrime, ProjectileID.Skull), new int[] { 50 } }, { new Tuple(NPCID.SkeletronPrime, ProjectileID.DeathLaser), new int[] { 50 } }, { new Tuple(NPCID.SkeletronPrime, ProjectileID.RocketSkeleton), new int[] { 60 } }, { new Tuple(NPCID.PrimeCannon, ProjectileID.RocketSkeleton), new int[] { 60 } }, { new Tuple(NPCID.PrimeCannon, ProjectileID.BombSkeletronPrime), new int[] { 80 } }, { new Tuple(NPCID.PrimeLaser, ProjectileID.DeathLaser), new int[] { 50 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 80, 140 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 50, 92 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 70, 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60, 108 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 50, 92 } }, { new Tuple(NPCID.Plantera, ProjectileID.SeedPlantera), new int[] { 44, 76 } }, { new Tuple(NPCID.Plantera, ProjectileID.PoisonSeedPlantera), new int[] { 54, 96 } }, { new Tuple(NPCID.Plantera, ProjectileID.ThornBall), new int[] { 62, 108 } }, { new Tuple(NPCID.Plantera, ModContent.ProjectileType()), new int[] { 54, 96 } }, { new Tuple(NPCID.Plantera, ModContent.ProjectileType()), new int[] { 54, 96 } }, { new Tuple(NPCID.HallowBoss, ProjectileID.HallowBossRainbowStreak), new int[] { 90, 120 } }, { new Tuple(NPCID.HallowBoss, ProjectileID.FairyQueenSunDance), new int[] { 100, 140 } }, { new Tuple(NPCID.HallowBoss, ProjectileID.HallowBossLastingRainbow), new int[] { 90, 120 } }, { new Tuple(NPCID.HallowBoss, ProjectileID.FairyQueenLance), new int[] { 100, 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 100, 160 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 48 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 48 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 48 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 48 } }, { new Tuple(NPCID.Golem, ProjectileID.Fireball), new int[] { 48 } }, { new Tuple(NPCID.Golem, ProjectileID.EyeBeam), new int[] { 56 } }, { new Tuple(NPCID.GolemHead, ProjectileID.Fireball), new int[] { 36 } }, // Scales up to 48 as health lowers { new Tuple(NPCID.GolemHead, ProjectileID.EyeBeam), new int[] { 56 } }, { new Tuple(NPCID.GolemFistLeft, ProjectileID.InfernoHostileBolt), new int[] { 70 } }, { new Tuple(NPCID.GolemFistRight, ProjectileID.InfernoHostileBolt), new int[] { 70 } }, { new Tuple(NPCID.GolemHeadFree, ProjectileID.Fireball), new int[] { 40 } }, { new Tuple(NPCID.GolemHeadFree, ProjectileID.EyeBeam), new int[] { 48 } }, // Scales up to 58 as health lowers { new Tuple(NPCID.GolemHeadFree, ProjectileID.InfernoHostileBolt), new int[] { 70 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 56 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 56 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 80 } }, { new Tuple(NPCID.DukeFishron, ProjectileID.Sharknado), new int[] { 80, 100 } }, { new Tuple(NPCID.DukeFishron, ProjectileID.Cthulunado), new int[] { 160, 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 90 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 80 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 80 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60 } }, { new Tuple(NPCID.CultistBoss, ProjectileID.CultistBossFireBall), new int[] { 60, 80 } }, { new Tuple(NPCID.CultistBoss, ProjectileID.CultistBossIceMist), new int[] { 70, 100 } }, { new Tuple(NPCID.CultistBoss, ProjectileID.CultistBossLightningOrb), new int[] { 90, 120 } }, { new Tuple(NPCID.CultistBossClone, ProjectileID.CultistBossFireBallClone), new int[] { 36 } }, { new Tuple(NPCID.AncientDoom, ProjectileID.AncientDoomProjectile), new int[] { 90 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 60 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 80 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 80 } }, { new Tuple(NPCID.MoonLordHead, ProjectileID.PhantasmalDeathray), new int[] { 150 } }, { new Tuple(NPCID.MoonLordHead, ProjectileID.PhantasmalBolt), new int[] { 60 } }, { new Tuple(NPCID.MoonLordHand, ProjectileID.PhantasmalEye), new int[] { 60 } }, { new Tuple(NPCID.MoonLordHand, ProjectileID.PhantasmalSphere), new int[] { 80 } }, { new Tuple(NPCID.MoonLordHand, ProjectileID.PhantasmalBolt), new int[] { 60 } }, { new Tuple(NPCID.MoonLordFreeEye, ProjectileID.PhantasmalBolt), new int[] { 70 } }, { new Tuple(NPCID.MoonLordFreeEye, ProjectileID.PhantasmalEye), new int[] { 70 } }, { new Tuple(NPCID.MoonLordFreeEye, ProjectileID.PhantasmalSphere), new int[] { 110 } }, { new Tuple(NPCID.MoonLordFreeEye, ProjectileID.PhantasmalDeathray), new int[] { 100 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 96 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 96 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 160 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 85 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 85 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 96 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 35, 50 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 85 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 150 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 128 } }, // Split holy fire: 96 { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 96 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 96 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 35, 50 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 85 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 85 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ProjectileID.CultistBossLightningOrbArc), new int[] { 132 } }, { new Tuple(ModContent.NPCType(), ProjectileID.FrostWave), new int[] { 132 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 132 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ProjectileID.CultistBossLightningOrb), new int[] { 132 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 132 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 132 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 144 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 150 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 132 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 110 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 140 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 210 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 140 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 120 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 150 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 125 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 250 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 150 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 150 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 150 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 150 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 240 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 240 } }, // Deals damage non-conventionally. Ignore this value. { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 240 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 200 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 270 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 240 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 240 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 180 } }, { new Tuple(ModContent.NPCType(), ModContent.ProjectileType()), new int[] { 270 } }, { new Tuple(ModContent.NPCType(), ProjectileID.CultistBossIceMist), new int[] { 240 } }, { new Tuple(ModContent.NPCType(), ProjectileID.CultistBossLightningOrbArc), new int[] { 280 } }, { new Tuple(ModContent.NPCType(), ProjectileID.AncientDoomProjectile), new int[] { 240 } }, { new Tuple(ModContent.NPCType(), ProjectileID.CultistBossFireBallClone), new int[] { 240 } } }; } // Destroys the EnemyStats struct to save memory because mod assemblies will not be fully unloaded until TML 1.4. internal static void UnloadEnemyStats() { EnemyStats.ExpertDamageMultiplier = null; EnemyStats.ContactDamageValues = null; EnemyStats.ProjectileDamageValues = null; } #endregion } }