Definition at line 48614 of file NPC.cs.
48615 {
48616
48617
48618
48619
48620
48621
48622
48623
48624
48625
48626
48627
48628
48629
48630
48631
48632
48633
48634 if (!Main.IsItAHappyWindyDay &&
timeLeft > 10)
48635 {
48637 }
48644 {
48646 float windSpeedCurrent = Main.windSpeedCurrent;
48650 }
48652 {
48655 {
48657 }
48658 if (Main.netMode == 1)
48659 {
48660 return;
48661 }
48663 {
48666 }
48667 else
48668 {
48670 {
48671 return;
48672 }
48675 {
48678 }
48679 else
48680 {
48682 {
48683 return;
48684 }
48685 Vector2
vector =
default(Vector2);
48686 Vector2
vector2 =
default(Vector2);
48687 for (int i = 0; i < 1 + Main.rand.Next(3); i++)
48688 {
48691 {
48693 }
48694 ((Vector2)(
ref vector)).
_002Ector((
float)(
num3 * Main.rand.Next(-2, 10)), (
float)(10 + Main.rand.Next(-6, 6)));
48698 {
48700 }
48702 vector3.X +=
num3 * 6;
48705 }
48707 }
48708 }
48709 }
48710 else if (
ai[0] == 0
f)
48711 {
48714 if (Main.netMode != 1 &&
flag)
48715 {
48718 }
48719 }
48720 }
float[] localAI
Acts like F:Terraria.NPC.ai, but does not sync to the server. Many vanilla T:Terraria....
NPCAimedTarget GetTargetData(bool ignorePlayerTankPets=true)
float[] ai
An array with 4 slots used for any sort of data storage, which is occasionally synced from the server...
IEntitySource GetSpawnSource_ForProjectile()
static void TargetClosestDownwindFromNPC(NPC searcher, float distanceMaxX, bool faceTarget=true, Vector2? checkPosition=null)
References Terraria.NPC.ai, Terraria.Entity.Center, Terraria.NPC.GetSpawnSource_ForProjectile(), Terraria.NPC.GetTargetData(), Terraria.Main.IsItAHappyWindyDay, Terraria.NPC.localAI, Terraria.Main.myPlayer, Terraria.Main.netMode, Terraria.NPC.netUpdate, Terraria.Projectile.NewProjectile(), Terraria.Main.rand, Terraria.NPC.target, Terraria.Utilities.NPCUtils.TargetClosestDownwindFromNPC(), Terraria.NPC.timeLeft, and Terraria.Main.windSpeedCurrent.
Referenced by Terraria.NPC.VanillaAI_Inner().