Files
CalamityModPublic/Systems/Collections/ConfusionDebuffImmunitiesList.cs
T
CongratsIsTrash dfb4a5c30b Removed Sea Urchin and Blinded Angler
And their banners
Sea Urchin community suggestion, Blinded Angler has been planned to be cut for the entirety of SSO plans
2025-01-30 00:36:56 -05:00

58 lines
2.0 KiB
C#

using System.Collections.Generic;
using CalamityMod.NPCs.Astral;
using CalamityMod.NPCs.Crags;
using CalamityMod.NPCs.NormalNPCs;
using Terraria.ModLoader;
using static Terraria.ModLoader.ModContent;
namespace CalamityMod.Systems.Collections
{
/// <summary>
/// A <see cref="ModSystem"/> that contains all of the NPC's IDs of the NPCs who are immune to the Confusion debuff.
/// </summary>
public sealed class ConfusionDebuffImmunitiesList : ModSystem
{
public static IList<int> List { get; private set; }
public override void OnModLoad()
{
List =
[
NPCType<AeroSlime>(),
NPCType<Rimehound>(),
NPCType<AstralachneaGround>(),
NPCType<AstralachneaWall>(),
NPCType<BloomSlime>(),
NPCType<Bohldohr>(),
NPCType<CalamityEye>(),
NPCType<CrimulanBlightSlime>(),
NPCType<Cryon>(),
NPCType<CryoSlime>(),
NPCType<RenegadeWarlock>(),
NPCType<DespairStone>(),
NPCType<EbonianBlightSlime>(),
NPCType<FearlessGoldfishWarrior>(),
NPCType<HeatSpirit>(),
NPCType<MantisShrimp>(),
NPCType<OverloadedSoldier>(),
NPCType<PerennialSlime>(),
NPCType<Rotdog>(),
NPCType<Scryllar>(),
NPCType<ScryllarRage>(),
NPCType<StellarCulex>(),
NPCType<Stormlion>(),
NPCType<SuperDummyNPC>(),
NPCType<WulfrumGyrator>(),
NPCType<WulfrumRover>()
];
}
public override void Unload() => List = null;
/// <summary>
/// A shorthand method to check if an NPC is supposed to be immune to the Confusion debuff.
/// </summary>
public static bool Includes(int npcType) => List.Contains(npcType);
}
}