Files
CalamityModPublic/Systems/Collections/EclipseBuffList.cs
T
2024-11-13 16:18:35 -05:00

48 lines
1.3 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace CalamityMod.Systems.Collections
{
/// <summary>
/// A <see cref="ModSystem"/> that contains a <see cref="IList{T}"/> of all NPC Types that receive Post-DoG Eclipse Buff
/// </summary>
public sealed class EclipseBuffList : ModSystem
{
public static IList<int> List { get; private set; }
public override void OnModLoad()
{
List =
[
NPCID.Eyezor,
NPCID.Reaper,
NPCID.Frankenstein,
NPCID.SwampThing,
NPCID.Vampire,
NPCID.VampireBat,
NPCID.Butcher,
NPCID.CreatureFromTheDeep,
NPCID.Fritz,
NPCID.Nailhead,
NPCID.Psycho,
NPCID.DeadlySphere,
NPCID.DrManFly,
NPCID.ThePossessed,
NPCID.Mothron,
NPCID.MothronEgg,
NPCID.MothronSpawn
];
}
public override void Unload() => List = null;
public static bool IsEclipseBuffNPC(NPC npc) => List.Contains(npc.type);
}
}