TModLoader v1.4.4.9
TModLoader source code documentation
Loading...
Searching...
No Matches

◆ ImmuneToAllBuffs

bool [] Terraria.ID.NPCID.Sets.ImmuneToAllBuffs
static

If true, this NPC type (F:Terraria.NPC.type) will be immune to all debuffs and "tag" buffs by default.

Use this for special NPCs that cannot be hit at all, such as fairy critters, container NPCs like Martian Saucer and Pirate Ship, bound town slimes, and Blazing Wheel. Dungeon Guardian also is in this set to prevent the bonus damage from "tag" buffs.

If the NPC should be attacked, it is recommended to set F:Terraria.ID.NPCID.Sets.ImmuneToRegularBuffs to true instead. This will prevent all debuffs except "tag" buffs (F:Terraria.ID.BuffID.Sets.IsATagBuff), which are intended to affect enemies typically seen as immune to all debuffs. Tag debuffs are special debuffs that facilitate combat mechanics, they are not something that adversely affects NPC.

Modders can specify specific buffs to be vulnerable to by assigning F:Terraria.ID.NPCID.Sets.SpecificDebuffImmunity to false.

Definition at line 668 of file NPCID.cs.

Referenced by Terraria.ID.NPCID.Sets.Sets(), and Terraria.NPC.SetDefaults().