Automatically sets certain static defaults. Override this if you do not want the properties to be set for you.
Definition at line 146 of file ModNPC.cs.
147 {
150 {
152 }
154 {
156 }
158 {
159 Main.npcLifeBytes[
NPC.
type] = 4;
160 }
162 {
163 Main.npcLifeBytes[
NPC.
type] = 2;
164 }
165 else
166 {
167 Main.npcLifeBytes[
NPC.
type] = 1;
168 }
169 }
static Asset< Texture2D >[] Npc
static string GetTextValue(string key)
Retrieves the text value for a specified localization key. The text returned will be for the currentl...
Contains methods to access or retrieve localization values. The Localization Guideteaches more about ...
int Banner
The type of NPC that this NPC will be considered as when determining banner drops and banner bonuses....
virtual string Texture
The file name of this type's texture file in the mod loader's file space.
int BannerItem
The type of the item this NPC drops for every 50 times it is defeated. For any ModNPC whose banner fi...
NPC NPC
The NPC object that this ModNPC controls.
bool boss
Set to true if the NPC is a boss. Prevents off-screen despawn. Bosses also need [AutoloadBossHead] an...
int lifeMax
The maximum life of this NPC.
int type
The NPC ID of this NPC. The NPC ID is a unique number assigned to each NPC loaded into the game....
string Name
The internal name of this instance.
References Terraria.ModLoader.ModNPC.Banner, Terraria.ModLoader.ModNPC.BannerItem, Terraria.ModLoader.NPCLoader.bannerToItem, Terraria.NPC.boss, Terraria.Localization.Language.GetTextValue(), Terraria.NPC.lifeMax, Terraria.ModLoader.IModType.Name, Terraria.GameContent.TextureAssets.Npc, Terraria.Main.npcLifeBytes, Terraria.ModLoader.ModNPC.Texture, Terraria.ModLoader.Logging.tML, and Terraria.NPC.type.
Referenced by Terraria.ModLoader.ModNPC.SetupContent().