TModLoader v1.4.4.9
TModLoader source code documentation
Loading...
Searching...
No Matches

◆ ScanPlayer()

void Terraria.GameContent.Drawing.WindGrid.ScanPlayer ( int i)
inlineprivate

Definition at line 88 of file WindGrid.cs.

89 {
90 //IL_0041: Unknown result type (might be due to invalid IL or missing references)
91 //IL_004b: Unknown result type (might be due to invalid IL or missing references)
92 //IL_0050: Unknown result type (might be due to invalid IL or missing references)
93 //IL_0055: Unknown result type (might be due to invalid IL or missing references)
94 //IL_0059: Unknown result type (might be due to invalid IL or missing references)
95 //IL_0066: Unknown result type (might be due to invalid IL or missing references)
96 //IL_0096: Unknown result type (might be due to invalid IL or missing references)
97 //IL_009c: Unknown result type (might be due to invalid IL or missing references)
98 //IL_00b1: Unknown result type (might be due to invalid IL or missing references)
99 //IL_00b6: Unknown result type (might be due to invalid IL or missing references)
100 //IL_00b9: Unknown result type (might be due to invalid IL or missing references)
101 //IL_00c0: Unknown result type (might be due to invalid IL or missing references)
102 Player player = Main.player[i];
103 if (!player.active || player.dead || (player.velocity.X == 0f && player.velocity.Y == 0f))
104 {
105 return;
106 }
107 Rectangle val = Utils.CenteredRectangle(Main.Camera.Center, Main.Camera.UnscaledSize);
108 if (!((Rectangle)(ref val)).Intersects(player.Hitbox) || player.velocity.HasNaNs())
109 {
110 return;
111 }
112 int directionX = Math.Sign(player.velocity.X);
113 int directionY = Math.Sign(player.velocity.Y);
114 foreach (Point item in Collision.GetTilesIn(player.TopLeft, player.BottomRight))
115 {
116 SetWindTime(item.X, item.Y, directionX, directionY);
117 }
118 }
void SetWindTime(int tileX, int tileY, int directionX, int directionY)
Definition WindGrid.cs:64

References Terraria.Entity.active, Terraria.Main.Camera, Terraria.Utils.CenteredRectangle(), Terraria.Player.dead, Terraria.Collision.GetTilesIn(), Terraria.Entity.Hitbox, Terraria.Main.player, Terraria.GameContent.Drawing.WindGrid.SetWindTime(), and Terraria.Entity.velocity.

Referenced by Terraria.GameContent.Drawing.WindGrid.ScanPlayers().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: