tModLoader v0.11.8.9
A mod to make and play Terraria mods
|
This serves as the central class from which NPC-related functions are carried out. It also stores a list of mod NPCs by ID. More...
Classes | |
class | HookList |
Static Public Member Functions | |
static void | AI (NPC npc) |
static void | BossBag (NPC npc, ref int bagType) |
static void | BossHeadRotation (NPC npc, ref float rotation) |
static void | BossHeadSlot (NPC npc, ref int index) |
static void | BossHeadSpriteEffects (NPC npc, ref SpriteEffects spriteEffects) |
static void | BossLoot (NPC npc, ref string name, ref int potionType) |
static void | BuffTownNPC (ref float damageMult, ref int defense) |
static ? bool | CanBeHitByItem (NPC npc, Player player, Item item) |
static ? bool | CanBeHitByProjectile (NPC npc, Projectile projectile) |
static bool | CanChat (NPC npc, bool vanillaCanChat) |
static bool | CanGoToStatue (NPC npc, bool toKingStatue, bool vanillaCanGo) |
static ? bool | CanHitNPC (NPC npc, NPC target) |
static bool | CanHitPlayer (NPC npc, Player target, ref int cooldownSlot) |
static void | CanTownNPCSpawn (int numTownNPCs, int money) |
static bool | CheckActive (NPC npc) |
static bool | CheckConditions (int type) |
static bool | CheckDead (NPC npc) |
static ? int | ChooseSpawn (NPCSpawnInfo spawnInfo) |
static void | DrawEffects (NPC npc, ref Color drawColor) |
static bool | DrawHealthBar (NPC npc, ref float scale) |
static void | DrawTownAttackGun (NPC npc, ref float scale, ref int item, ref int closeness) |
static void | DrawTownAttackSwing (NPC npc, ref Texture2D item, ref int itemSize, ref float scale, ref Vector2 offset) |
static void | EditSpawnRange (Player player, ref int spawnRangeX, ref int spawnRangeY, ref int safeRangeX, ref int safeRangeY) |
static void | EditSpawnRate (Player player, ref int spawnRate, ref int maxSpawns) |
static void | FindFrame (NPC npc, int frameHeight) |
static ? Color | GetAlpha (NPC npc, Color lightColor) |
static void | GetChat (NPC npc, ref string chat) |
static ModNPC | GetNPC (int type) |
Gets the ModNPC instance corresponding to the specified type. More... | |
static void | HitEffect (NPC npc, int hitDirection, double damage) |
static void | ModifyHitByItem (NPC npc, Player player, Item item, ref int damage, ref float knockback, ref bool crit) |
static void | ModifyHitByProjectile (NPC npc, Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection) |
static void | ModifyHitNPC (NPC npc, NPC target, ref int damage, ref float knockback, ref bool crit) |
static void | ModifyHitPlayer (NPC npc, Player target, ref int damage, ref bool crit) |
static void | NPCAI (NPC npc) |
static void | NPCLoot (NPC npc) |
static void | OnCatchNPC (NPC npc, Player player, Item item) |
static void | OnChatButtonClicked (bool firstButton) |
static void | OnGoToStatue (NPC npc, bool toKingStatue) |
static void | OnHitByItem (NPC npc, Player player, Item item, int damage, float knockback, bool crit) |
static void | OnHitByProjectile (NPC npc, Projectile projectile, int damage, float knockback, bool crit) |
static void | OnHitNPC (NPC npc, NPC target, int damage, float knockback, bool crit) |
static void | OnHitPlayer (NPC npc, Player target, int damage, bool crit) |
static void | PostAI (NPC npc) |
static void | PostDraw (NPC npc, SpriteBatch spriteBatch, Color drawColor) |
static bool | PreAI (NPC npc) |
static bool | PreChatButtonClicked (bool firstButton) |
static bool | PreDraw (NPC npc, SpriteBatch spriteBatch, Color drawColor) |
static bool | PreNPCLoot (NPC npc) |
static void | ReceiveExtraAI (NPC npc, BinaryReader reader) |
static void | ResetEffects (NPC npc) |
static void | ScaleExpertStats (NPC npc, int numPlayers, float bossLifeScale) |
static void | SendExtraAI (NPC npc, BinaryWriter writer) |
static void | SetChatButtons (ref string button, ref string button2) |
static void | SetupShop (int type, Chest shop, ref int nextSlot) |
static void | SetupTravelShop (int[] shop, ref int nextSlot) |
static int | SpawnNPC (int type, int tileX, int tileY) |
static bool | SpecialNPCLoot (NPC npc) |
static bool | StrikeNPC (NPC npc, ref double damage, int defense, ref float knockback, int hitDirection, ref bool crit) |
static void | TownNPCAttackCooldown (NPC npc, ref int cooldown, ref int randExtraCooldown) |
static void | TownNPCAttackMagic (NPC npc, ref float auraLightMultiplier) |
static void | TownNPCAttackProj (NPC npc, ref int projType, ref int attackDelay) |
static void | TownNPCAttackProjSpeed (NPC npc, ref float multiplier, ref float gravityCorrection, ref float randomOffset) |
static void | TownNPCAttackShoot (NPC npc, ref bool inBetweenShots) |
static void | TownNPCAttackStrength (NPC npc, ref int damage, ref float knockback) |
static void | TownNPCAttackSwing (NPC npc, ref int itemWidth, ref int itemHeight) |
static string | TownNPCName (int type) |
static void | UpdateLifeRegen (NPC npc, ref int damage) |
static bool | UsesPartyHat (NPC npc) |
Static Public Attributes | |
static readonly IList< int > | blockLoot = new List<int>() |
Allows you to stop an NPC from dropping loot by adding item IDs to this list. This list will be cleared whenever NPCLoot ends. Useful for either removing an item or change the drop rate of an item in the NPC's loot table. To change the drop rate of an item, use the PreNPCLoot hook, spawn the item yourself, then add the item's ID to this list. More... | |
Properties | |
static int | NPCCount [get] |
Private Member Functions | |
delegate void | DelegateBossHeadRotation (NPC npc, ref float rotation) |
delegate void | DelegateBossHeadSlot (NPC npc, ref int index) |
delegate void | DelegateBossHeadSpriteEffects (NPC npc, ref SpriteEffects spriteEffects) |
delegate void | DelegateBuffTownNPC (ref float damageMult, ref int defense) |
delegate bool | DelegateCanHitPlayer (NPC npc, Player target, ref int cooldownSlot) |
delegate void | DelegateDrawEffects (NPC npc, ref Color drawColor) |
delegate? bool | DelegateDrawHealthBar (NPC npc, byte bhPosition, ref float scale, ref Vector2 position) |
delegate void | DelegateDrawTownAttackGun (NPC npc, ref float scale, ref int item, ref int closeness) |
delegate void | DelegateDrawTownAttackSwing (NPC npc, ref Texture2D item, ref int itemSize, ref float scale, ref Vector2 offset) |
delegate void | DelegateEditSpawnRange (Player player, ref int spawnRangeX, ref int spawnRangeY, ref int safeRangeX, ref int safeRangeY) |
delegate void | DelegateEditSpawnRate (Player player, ref int spawnRate, ref int maxSpawns) |
delegate void | DelegateGetChat (NPC npc, ref string chat) |
delegate void | DelegateModifyHitByItem (NPC npc, Player player, Item item, ref int damage, ref float knockback, ref bool crit) |
delegate void | DelegateModifyHitByProjectile (NPC npc, Projectile projectile, ref int damage, ref float knockback, ref bool crit, ref int hitDirection) |
delegate void | DelegateModifyHitNPC (NPC npc, NPC target, ref int damage, ref float knockback, ref bool crit) |
delegate void | DelegateModifyHitPlayer (NPC npc, Player target, ref int damage, ref bool crit) |
delegate void | DelegateOnChatButtonClicked (NPC npc, bool firstButton) |
delegate void | DelegateSetupShop (int type, Chest shop, ref int nextSlot) |
delegate void | DelegateSetupTravelShop (int[] shop, ref int nextSlot) |
delegate bool | DelegateStrikeNPC (NPC npc, ref double damage, int defense, ref float knockback, int hitDirection, ref bool crit) |
delegate void | DelegateTownNPCAttackCooldown (NPC npc, ref int cooldown, ref int randExtraCooldown) |
delegate void | DelegateTownNPCAttackMagic (NPC npc, ref float auraLightMultiplier) |
delegate void | DelegateTownNPCAttackProj (NPC npc, ref int projType, ref int attackDelay) |
delegate void | DelegateTownNPCAttackProjSpeed (NPC npc, ref float multiplier, ref float gravityCorrection, ref float randomOffset) |
delegate void | DelegateTownNPCAttackShoot (NPC npc, ref bool inBetweenShots) |
delegate void | DelegateTownNPCAttackStrength (NPC npc, ref int damage, ref float knockback) |
delegate void | DelegateTownNPCAttackSwing (NPC npc, ref int itemWidth, ref int itemHeight) |
delegate void | DelegateUpdateLifeRegen (NPC npc, ref int damage) |
Static Private Member Functions | |
static | NPCLoader () |
static HookList | AddHook< F > (Expression< Func< GlobalNPC, F > > func) |
static void | DrawHealthBar (NPC npc, Vector2 position, float scale) |
static bool | HasMethod (Type t, string method, params Type[] args) |
Static Private Attributes | |
static HookList | HookAI = AddHook<Action<NPC>>(g => g.AI) |
static HookList | HookBossHeadRotation = AddHook<DelegateBossHeadRotation>(g => g.BossHeadRotation) |
static HookList | HookBossHeadSlot = AddHook<DelegateBossHeadSlot>(g => g.BossHeadSlot) |
static HookList | HookBossHeadSpriteEffects = AddHook<DelegateBossHeadSpriteEffects>(g => g.BossHeadSpriteEffects) |
static HookList | HookBuffTownNPC = AddHook<DelegateBuffTownNPC>(g => g.BuffTownNPC) |
static HookList | HookCanBeHitByItem = AddHook<Func<NPC, Player, Item, bool?>>(g => g.CanBeHitByItem) |
static HookList | HookCanBeHitByProjectile = AddHook<Func<NPC, Projectile, bool?>>(g => g.CanBeHitByProjectile) |
static HookList | HookCanChat = AddHook<Func<NPC, bool?>>(g => g.CanChat) |
static HookList | HookCanGoToStatue = AddHook<Func<NPC, bool, bool?>>(g => g.CanGoToStatue) |
static HookList | HookCanHitNPC = AddHook<Func<NPC, NPC, bool?>>(g => g.CanHitNPC) |
static HookList | HookCanHitPlayer = AddHook<DelegateCanHitPlayer>(g => g.CanHitPlayer) |
static HookList | HookCheckActive = AddHook<Func<NPC, bool>>(g => g.CheckActive) |
static HookList | HookCheckDead = AddHook<Func<NPC, bool>>(g => g.CheckDead) |
static HookList | HookDrawBehind = AddHook<Action<NPC, int>>(g => g.DrawBehind) |
static HookList | HookDrawEffects = AddHook<DelegateDrawEffects>(g => g.DrawEffects) |
static HookList | HookDrawHealthBar = AddHook<DelegateDrawHealthBar>(g => g.DrawHealthBar) |
static HookList | HookDrawTownAttackGun = AddHook<DelegateDrawTownAttackGun>(g => g.DrawTownAttackGun) |
static HookList | HookDrawTownAttackSwing = AddHook<DelegateDrawTownAttackSwing>(g => g.DrawTownAttackSwing) |
static HookList | HookEditSpawnPool = AddHook<Action<Dictionary<int, float>, NPCSpawnInfo>>(g => g.EditSpawnPool) |
static HookList | HookEditSpawnRange = AddHook<DelegateEditSpawnRange>(g => g.EditSpawnRange) |
static HookList | HookEditSpawnRate = AddHook<DelegateEditSpawnRate>(g => g.EditSpawnRate) |
static HookList | HookFindFrame = AddHook<Action<NPC, int>>(g => g.FindFrame) |
static HookList | HookGetAlpha = AddHook<Func<NPC, Color, Color?>>(g => g.GetAlpha) |
static HookList | HookGetChat = AddHook<DelegateGetChat>(g => g.GetChat) |
static HookList | HookHitEffect = AddHook<Action<NPC, int, double>>(g => g.HitEffect) |
static HookList | HookModifyHitByItem = AddHook<DelegateModifyHitByItem>(g => g.ModifyHitByItem) |
static HookList | HookModifyHitByProjectile = AddHook<DelegateModifyHitByProjectile>(g => g.ModifyHitByProjectile) |
static HookList | HookModifyHitNPC = AddHook<DelegateModifyHitNPC>(g => g.ModifyHitNPC) |
static HookList | HookModifyHitPlayer = AddHook<DelegateModifyHitPlayer>(g => g.ModifyHitPlayer) |
static HookList | HookNPCLoot = AddHook<Action<NPC>>(g => g.NPCLoot) |
static HookList | HookOnCatchNPC = AddHook<Action<NPC, Player, Item>>(g => g.OnCatchNPC) |
static HookList | HookOnChatButtonClicked = AddHook<DelegateOnChatButtonClicked>(g => g.OnChatButtonClicked) |
static HookList | HookOnGoToStatue = AddHook<Action<NPC, bool>>(g => g.OnGoToStatue) |
static HookList | HookOnHitByItem = AddHook<Action<NPC, Player, Item, int, float, bool>>(g => g.OnHitByItem) |
static HookList | HookOnHitByProjectile = AddHook<Action<NPC, Projectile, int, float, bool>>(g => g.OnHitByProjectile) |
static HookList | HookOnHitNPC = AddHook<Action<NPC, NPC, int, float, bool>>(g => g.OnHitNPC) |
static HookList | HookOnHitPlayer = AddHook<Action<NPC, Player, int, bool>>(g => g.OnHitPlayer) |
static HookList | HookPostAI = AddHook<Action<NPC>>(g => g.PostAI) |
static HookList | HookPostDraw = AddHook<Action<NPC, SpriteBatch, Color>>(g => g.PostDraw) |
static HookList | HookPreAI = AddHook<Func<NPC, bool>>(g => g.PreAI) |
static HookList | HookPreChatButtonClicked = AddHook<Func<NPC, bool, bool>>(g => g.PreChatButtonClicked) |
static HookList | HookPreDraw = AddHook<Func<NPC, SpriteBatch, Color, bool>>(g => g.PreDraw) |
static HookList | HookPreNPCLoot = AddHook<Func<NPC, bool>>(g => g.PreNPCLoot) |
static HookList | HookResetEffects = AddHook<Action<NPC>>(g => g.ResetEffects) |
static List< HookList > | hooks = new List<HookList>() |
static HookList | HookScaleExpertStats = AddHook<Action<NPC, int, float>>(g => g.ScaleExpertStats) |
static HookList | HookSetDefaults = AddHook<Action<NPC>>(g => g.SetDefaults) |
static HookList | HookSetupShop = AddHook<DelegateSetupShop>(g => g.SetupShop) |
static HookList | HookSetupTravelShop = AddHook<DelegateSetupTravelShop>(g => g.SetupTravelShop) |
static HookList | HookSpawnNPC = AddHook<Action<int, int, int>>(g => g.SpawnNPC) |
static HookList | HookSpecialNPCLoot = AddHook<Func<NPC, bool>>(g => g.SpecialNPCLoot) |
static HookList | HookStrikeNPC = AddHook<DelegateStrikeNPC>(g => g.StrikeNPC) |
static HookList | HookTownNPCAttackCooldown = AddHook<DelegateTownNPCAttackCooldown>(g => g.TownNPCAttackCooldown) |
static HookList | HookTownNPCAttackMagic = AddHook<DelegateTownNPCAttackMagic>(g => g.TownNPCAttackMagic) |
static HookList | HookTownNPCAttackProj = AddHook<DelegateTownNPCAttackProj>(g => g.TownNPCAttackProj) |
static HookList | HookTownNPCAttackProjSpeed = AddHook<DelegateTownNPCAttackProjSpeed>(g => g.TownNPCAttackProjSpeed) |
static HookList | HookTownNPCAttackShoot = AddHook<DelegateTownNPCAttackShoot>(g => g.TownNPCAttackShoot) |
static HookList | HookTownNPCAttackStrength = AddHook<DelegateTownNPCAttackStrength>(g => g.TownNPCAttackStrength) |
static HookList | HookTownNPCAttackSwing = AddHook<DelegateTownNPCAttackSwing>(g => g.TownNPCAttackSwing) |
static HookList | HookUpdateLifeRegen = AddHook<DelegateUpdateLifeRegen>(g => g.UpdateLifeRegen) |
static int | nextNPC = NPCID.Count |
static readonly int[] | shopToNPC = new int[Main.MaxShopIDs - 1] |
static int | vanillaSkeletonCount = NPCID.Sets.Skeletons.Count |
This serves as the central class from which NPC-related functions are carried out. It also stores a list of mod NPCs by ID.
Definition at line 19 of file NPCLoader.cs.
|
staticprivate |
Definition at line 54 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.shopToNPC.
|
staticprivate |
Definition at line 48 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.hooks.
|
static |
Definition at line 270 of file NPCLoader.cs.
References Terraria.ModLoader.GlobalNPC.AI(), Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookAI, and Terraria.ModLoader.GlobalNPC.Instance().
Referenced by Terraria.ModLoader.NPCLoader.NPCAI().
|
static |
Definition at line 435 of file NPCLoader.cs.
|
static |
Definition at line 654 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.BossHeadRotation(), Terraria.ModLoader.NPCLoader.HookBossHeadRotation, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 643 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.BossHeadSlot(), Terraria.ModLoader.NPCLoader.HookBossHeadSlot, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 665 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.BossHeadSpriteEffects(), Terraria.ModLoader.NPCLoader.HookBossHeadSpriteEffects, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 431 of file NPCLoader.cs.
|
static |
Definition at line 994 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.BuffTownNPC(), and Terraria.ModLoader.NPCLoader.HookBuffTownNPC.
|
static |
Definition at line 534 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.CanBeHitByItem(), Terraria.ModLoader.NPCLoader.HookCanBeHitByItem, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 580 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.CanBeHitByProjectile(), Terraria.ModLoader.NPCLoader.HookCanBeHitByProjectile, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 861 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.CanChat(), Terraria.ModLoader.NPCLoader.HookCanChat, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 965 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.CanGoToStatue(), Terraria.ModLoader.NPCLoader.HookCanGoToStatue, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 489 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.CanHitNPC(), Terraria.ModLoader.NPCLoader.HookCanHitNPC, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 454 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.CanHitPlayer(), Terraria.ModLoader.NPCLoader.HookCanHitPlayer, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 835 of file NPCLoader.cs.
References Terraria.ModLoader.ModNPC.CanTownNPCSpawn(), and Terraria.ModLoader.ModNPC.npc.
|
static |
Definition at line 358 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.CheckActive(), Terraria.ModLoader.NPCLoader.HookCheckActive, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 847 of file NPCLoader.cs.
References Terraria.ModLoader.ModNPC.CheckConditions(), and Terraria.ModLoader.NPCLoader.GetNPC().
|
static |
Definition at line 372 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.CheckDead(), Terraria.ModLoader.NPCLoader.HookCheckDead, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 789 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.EditSpawnPool(), Terraria.ModLoader.NPCLoader.HookEditSpawnPool, Terraria.ModLoader.ModNPC.npc, and Terraria.ModLoader.ModNPC.SpawnChance().
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
static |
Definition at line 688 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.DrawEffects(), Terraria.ModLoader.NPCLoader.HookDrawEffects, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 733 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.DrawHealthBar(), Terraria.ModLoader.NPCLoader.DrawHealthBar(), Terraria.ModLoader.NPCLoader.HookDrawHealthBar, and Terraria.ModLoader.GlobalNPC.Instance().
Referenced by Terraria.ModLoader.NPCLoader.DrawHealthBar().
|
staticprivate |
Definition at line 762 of file NPCLoader.cs.
|
static |
Definition at line 1097 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.DrawTownAttackGun(), Terraria.ModLoader.NPCLoader.HookDrawTownAttackGun, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 1108 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.DrawTownAttackSwing(), Terraria.ModLoader.NPCLoader.HookDrawTownAttackSwing, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 780 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.EditSpawnRange(), and Terraria.ModLoader.NPCLoader.HookEditSpawnRange.
|
static |
Definition at line 770 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.EditSpawnRate(), and Terraria.ModLoader.NPCLoader.HookEditSpawnRate.
|
static |
Definition at line 320 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.FindFrame(), Terraria.ModLoader.NPCLoader.HookFindFrame, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 675 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.GetAlpha(), Terraria.ModLoader.NPCLoader.HookGetAlpha, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 880 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.GetChat(), Terraria.ModLoader.NPCLoader.HookGetChat, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Gets the ModNPC instance corresponding to the specified type.
type | The type of the npc |
Definition at line 93 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.NPCCount.
Referenced by Terraria.ModLoader.NPCLoader.CheckConditions(), Terraria.ModLoader.NPCLoader.SetupShop(), Terraria.ModLoader.NPCLoader.SpawnNPC(), and Terraria.ModLoader.NPCLoader.TownNPCName().
|
staticprivate |
Definition at line 1116 of file NPCLoader.cs.
|
static |
Definition at line 336 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.GlobalNPC.HitEffect(), Terraria.ModLoader.NPCLoader.HookHitEffect, and Terraria.ModLoader.GlobalNPC.Instance().
|
static |
Definition at line 560 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookModifyHitByItem, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.ModifyHitByItem().
|
static |
Definition at line 606 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookModifyHitByProjectile, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.ModifyHitByProjectile().
|
static |
Definition at line 515 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookModifyHitNPC, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.ModifyHitNPC().
|
static |
Definition at line 469 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookModifyHitPlayer, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.ModifyHitPlayer().
|
static |
Definition at line 239 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.AI(), Terraria.ModLoader.NPCLoader.PostAI(), and Terraria.ModLoader.NPCLoader.PreAI().
|
static |
Definition at line 422 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.blockLoot, Terraria.ModLoader.NPCLoader.HookNPCLoot, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.NPCLoot().
|
static |
Definition at line 443 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookOnCatchNPC, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.OnCatchNPC().
|
static |
Definition at line 920 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookOnChatButtonClicked, Terraria.ModLoader.GlobalNPC.Instance(), Terraria.ModLoader.ModNPC.npc, and Terraria.ModLoader.GlobalNPC.OnChatButtonClicked().
|
static |
Definition at line 983 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookOnGoToStatue, and Terraria.ModLoader.GlobalNPC.OnGoToStatue().
|
static |
Definition at line 570 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookOnHitByItem, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.OnHitByItem().
|
static |
Definition at line 616 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookOnHitByProjectile, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.OnHitByProjectile().
|
static |
Definition at line 525 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookOnHitNPC, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.OnHitNPC().
|
static |
Definition at line 479 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookOnHitPlayer, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.OnHitPlayer().
|
static |
Definition at line 280 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookPostAI, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.PostAI().
Referenced by Terraria.ModLoader.NPCLoader.NPCAI().
|
static |
Definition at line 711 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookPostDraw, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.PostDraw().
|
static |
Definition at line 257 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookPreAI, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.PreAI().
Referenced by Terraria.ModLoader.NPCLoader.NPCAI().
|
static |
Definition at line 901 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookPreChatButtonClicked, Terraria.ModLoader.GlobalNPC.Instance(), Terraria.ModLoader.ModNPC.npc, and Terraria.ModLoader.GlobalNPC.PreChatButtonClicked().
|
static |
Definition at line 698 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookPreDraw, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.PreDraw().
|
static |
Definition at line 402 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.blockLoot, Terraria.ModLoader.NPCLoader.HookPreNPCLoot, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.PreNPCLoot().
|
static |
Definition at line 305 of file NPCLoader.cs.
|
static |
Definition at line 231 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookResetEffects, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.ResetEffects().
|
static |
Definition at line 221 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookScaleExpertStats, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.ScaleExpertStats().
|
static |
Definition at line 288 of file NPCLoader.cs.
|
static |
Definition at line 892 of file NPCLoader.cs.
References Terraria.ModLoader.ModNPC.npc.
|
static |
Definition at line 942 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.GetNPC(), Terraria.ModLoader.NPCLoader.HookSetupShop, Terraria.ModLoader.ModNPC.SetupShop(), Terraria.ModLoader.GlobalNPC.SetupShop(), and Terraria.ModLoader.NPCLoader.shopToNPC.
|
static |
Definition at line 957 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookSetupTravelShop, and Terraria.ModLoader.GlobalNPC.SetupTravelShop().
|
static |
Definition at line 823 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.GetNPC(), Terraria.ModLoader.NPCLoader.HookSpawnNPC, Terraria.ModLoader.GlobalNPC.Instance(), Terraria.ModLoader.GlobalNPC.SpawnNPC(), and Terraria.ModLoader.ModNPC.SpawnNPC().
|
static |
Definition at line 388 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookSpecialNPCLoot, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.SpecialNPCLoot().
|
static |
Definition at line 627 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookStrikeNPC, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.StrikeNPC().
|
static |
Definition at line 1029 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookTownNPCAttackCooldown, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.TownNPCAttackCooldown().
|
static |
Definition at line 1075 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookTownNPCAttackMagic, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.TownNPCAttackMagic().
|
static |
Definition at line 1040 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookTownNPCAttackProj, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.TownNPCAttackProj().
|
static |
Definition at line 1052 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookTownNPCAttackProjSpeed, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.TownNPCAttackProjSpeed().
|
static |
Definition at line 1064 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookTownNPCAttackShoot, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.TownNPCAttackShoot().
|
static |
Definition at line 1018 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookTownNPCAttackStrength, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.TownNPCAttackStrength().
|
static |
Definition at line 1086 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookTownNPCAttackSwing, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.TownNPCAttackSwing().
|
static |
Definition at line 851 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.GetNPC(), and Terraria.ModLoader.ModNPC.TownNPCName().
|
static |
Definition at line 348 of file NPCLoader.cs.
References Terraria.ModLoader.NPCLoader.HookList.arr, Terraria.ModLoader.NPCLoader.HookUpdateLifeRegen, Terraria.ModLoader.GlobalNPC.Instance(), and Terraria.ModLoader.GlobalNPC.UpdateLifeRegen().
|
static |
Definition at line 855 of file NPCLoader.cs.
|
static |
Allows you to stop an NPC from dropping loot by adding item IDs to this list. This list will be cleared whenever NPCLoot ends. Useful for either removing an item or change the drop rate of an item in the NPC's loot table. To change the drop rate of an item, use the PreNPCLoot hook, spawn the item yourself, then add the item's ID to this list.
Definition at line 34 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.NPCLoot(), Terraria.ModLoader.NPCLoader.PreNPCLoot(), and Terraria.ModLoader.ItemLoader.PreOpenVanillaBag().
|
staticprivate |
Definition at line 268 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.AI().
|
staticprivate |
Definition at line 652 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.BossHeadRotation().
|
staticprivate |
Definition at line 641 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.BossHeadSlot().
|
staticprivate |
Definition at line 663 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.BossHeadSpriteEffects().
|
staticprivate |
Definition at line 992 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.BuffTownNPC().
|
staticprivate |
Definition at line 532 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.CanBeHitByItem().
|
staticprivate |
Definition at line 578 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.CanBeHitByProjectile().
|
staticprivate |
Definition at line 859 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.CanChat().
|
staticprivate |
Definition at line 963 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.CanGoToStatue().
|
staticprivate |
Definition at line 487 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.CanHitNPC().
|
staticprivate |
Definition at line 452 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.CanHitPlayer().
|
staticprivate |
Definition at line 356 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.CheckActive().
|
staticprivate |
Definition at line 370 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.CheckDead().
|
staticprivate |
Definition at line 719 of file NPCLoader.cs.
|
staticprivate |
Definition at line 686 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.DrawEffects().
|
staticprivate |
Definition at line 731 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.DrawHealthBar().
|
staticprivate |
Definition at line 1095 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.DrawTownAttackGun().
|
staticprivate |
Definition at line 1106 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.DrawTownAttackSwing().
|
staticprivate |
Definition at line 787 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.ChooseSpawn().
|
staticprivate |
Definition at line 778 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.EditSpawnRange().
|
staticprivate |
Definition at line 768 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.EditSpawnRate().
|
staticprivate |
Definition at line 318 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.FindFrame().
|
staticprivate |
Definition at line 673 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.GetAlpha().
|
staticprivate |
Definition at line 878 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.GetChat().
|
staticprivate |
Definition at line 334 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.HitEffect().
|
staticprivate |
Definition at line 558 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.ModifyHitByItem().
|
staticprivate |
Definition at line 604 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.ModifyHitByProjectile().
|
staticprivate |
Definition at line 513 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.ModifyHitNPC().
|
staticprivate |
Definition at line 467 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.ModifyHitPlayer().
|
staticprivate |
Definition at line 420 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.NPCLoot().
|
staticprivate |
Definition at line 441 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.OnCatchNPC().
|
staticprivate |
Definition at line 918 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.OnChatButtonClicked().
|
staticprivate |
Definition at line 981 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.OnGoToStatue().
|
staticprivate |
Definition at line 568 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.OnHitByItem().
|
staticprivate |
Definition at line 614 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.OnHitByProjectile().
|
staticprivate |
Definition at line 523 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.OnHitNPC().
|
staticprivate |
Definition at line 477 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.OnHitPlayer().
|
staticprivate |
Definition at line 278 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.PostAI().
|
staticprivate |
Definition at line 709 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.PostDraw().
|
staticprivate |
Definition at line 255 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.PreAI().
|
staticprivate |
Definition at line 899 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.PreChatButtonClicked().
|
staticprivate |
Definition at line 696 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.PreDraw().
|
staticprivate |
Definition at line 400 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.PreNPCLoot().
|
staticprivate |
Definition at line 229 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.ResetEffects().
Definition at line 46 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.AddHook< F >().
|
staticprivate |
Definition at line 219 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.ScaleExpertStats().
|
staticprivate |
Definition at line 190 of file NPCLoader.cs.
|
staticprivate |
Definition at line 940 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.SetupShop().
|
staticprivate |
Definition at line 955 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.SetupTravelShop().
|
staticprivate |
Definition at line 821 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.SpawnNPC().
|
staticprivate |
Definition at line 386 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.SpecialNPCLoot().
|
staticprivate |
Definition at line 625 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.StrikeNPC().
|
staticprivate |
Definition at line 1027 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.TownNPCAttackCooldown().
|
staticprivate |
Definition at line 1073 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.TownNPCAttackMagic().
|
staticprivate |
Definition at line 1038 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.TownNPCAttackProj().
|
staticprivate |
Definition at line 1050 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.TownNPCAttackProjSpeed().
|
staticprivate |
Definition at line 1062 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.TownNPCAttackShoot().
|
staticprivate |
Definition at line 1016 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.TownNPCAttackStrength().
|
staticprivate |
Definition at line 1084 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.TownNPCAttackSwing().
|
staticprivate |
Definition at line 346 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.UpdateLifeRegen().
|
staticprivate |
Definition at line 22 of file NPCLoader.cs.
|
staticprivate |
Definition at line 30 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.NPCLoader(), and Terraria.ModLoader.NPCLoader.SetupShop().
|
staticprivate |
Definition at line 29 of file NPCLoader.cs.
|
staticget |
Definition at line 86 of file NPCLoader.cs.
Referenced by Terraria.ModLoader.NPCLoader.GetNPC().