85612 {
85614 {
85615 return;
85616 }
85618 {
85619 for (int i = 0; i < 200; i++)
85620 {
85621 if (i !=
whoAmI && Main.npc[i].active && (Main.npc[i].type == 13 || Main.npc[i].type == 14 || Main.npc[i].type == 15))
85622 {
85623 Main.npc[i].ApplyInteraction(player);
85624 }
85625 }
85626 }
85628 {
85629 for (
int j = 0;
j < 200;
j++)
85630 {
85631 if (
j !=
whoAmI && Main.npc[
j].active && (Main.npc[
j].type == 134 || Main.npc[
j].type == 135 || Main.npc[
j].type == 136))
85632 {
85633 Main.npc[
j].ApplyInteraction(player);
85634 }
85635 }
85636 }
85638 {
85639 for (
int k = 0;
k < 200;
k++)
85640 {
85641 if (
k !=
whoAmI && Main.npc[
k].active && (Main.npc[
k].type == 35 || Main.npc[
k].type == 36))
85642 {
85643 Main.npc[
k].ApplyInteraction(player);
85644 }
85645 }
85646 }
85648 {
85649 for (
int l = 0;
l < 200;
l++)
85650 {
85651 if (
l !=
whoAmI && Main.npc[
l].active && (Main.npc[
l].type == 113 || Main.npc[
l].type == 114))
85652 {
85653 Main.npc[
l].ApplyInteraction(player);
85654 }
85655 }
85656 }
85658 {
85659 for (
int m = 0;
m < 200;
m++)
85660 {
85661 if (
m !=
whoAmI && Main.npc[
m].active && Main.npc[
m].type >= 127 && Main.npc[
m].type <= 131)
85662 {
85663 Main.npc[
m].ApplyInteraction(player);
85664 }
85665 }
85666 }
85668 {
85669 for (
int n = 0;
n < 200;
n++)
85670 {
85671 if (
n !=
whoAmI && Main.npc[
n].active && Main.npc[
n].type >= 245 && Main.npc[
n].type <= 249)
85672 {
85673 Main.npc[
n].ApplyInteraction(player);
85674 }
85675 }
85676 }
85677 if ((
type == 396 ||
type == 397) && Main.npc[(
int)
ai[3]].active && Main.npc[(
int)
ai[3]].type == 398)
85678 {
85680 }
85681 if ((
type == 393 ||
type == 394) && Main.npc[(int)
ai[0]].
active && Main.npc[(
int)
ai[0]].type == 395)
85682 {
85684 }
85685 if (
type == 492 && Main.npc[(
int)
ai[0]].active && Main.npc[(int)
ai[0]].
type == 491)
85686 {
85688 }
85690 {
85692 {
85693 if (
num !=
whoAmI && Main.npc[
num].active && (Main.npc[
num].type == 125 || Main.npc[
num].type == 126))
85694 {
85695 Main.npc[
num].ApplyInteraction(player);
85696 }
85697 }
85698 }
85700 }
int whoAmI
The index of this Entity within its specific array. These arrays track the entities in the world....
bool active
If true, the Entity actually exists within the game world. Within the specific entity array,...
float[] ai
An array with 4 slots used for any sort of data storage, which is occasionally synced from the server...
void ApplyInteraction(int player)
int type
The NPC ID of this NPC. The NPC ID is a unique number assigned to each NPC loaded into the game....
int lastInteraction
The F:Terraria.Entity.whoAmI of the T:Terraria.Player that last damaged this NPC. Used to award Banne...
int realLife
Stores the index (the F:Terraria.Entity.whoAmI) of a single NPC. This NPC will then share a health po...