tModLoader v2024.09
A mod to make and play Terraria mods
NPCDefinition Class Reference

Inherits EntityDefinition.

Public Member Functions

 NPCDefinition (int type)
 Note: As ModConfig loads before other content, make sure to only use NPCDefinition(string, string) for modded content in ModConfig classes.
 
 NPCDefinition (string key)
 
 NPCDefinition (string mod, string name)
 
- Public Member Functions inherited from EntityDefinition
 EntityDefinition (string key)
 
 EntityDefinition (string mod, string name)
 
override bool Equals (object obj)
 
override int GetHashCode ()
 
TagCompound SerializeData ()
 
override string ToString ()
 
TagCompound SerializeData ()
 

Static Public Member Functions

static NPCDefinition FromString (string s)
 
static NPCDefinition Load (TagCompound tag)
 

Static Public Attributes

static readonly Func< TagCompound, NPCDefinitionDESERIALIZER = Load
 

Properties

override string DisplayName [get]
 
override int Type [get]
 
- Properties inherited from EntityDefinition
virtual string DisplayName [get]
 
virtual bool IsUnloaded [get]
 
abstract int Type [get]
 

Additional Inherited Members

- Public Attributes inherited from EntityDefinition
string Mod
 
string Name