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

◆ CanSpawnSandstormFriendly()

static bool Terraria.StrayMethods.CanSpawnSandstormFriendly ( Vector2 position,
int expandUp,
int expandDown )
inlinestatic

Definition at line 65 of file StrayMethods.cs.

66 {
67 bool result = true;
68 Point point = position.ToTileCoordinates();
69 for (int i = -1; i <= 1; i++)
70 {
71 Collision.ExpandVertically(point.X + i, point.Y, out var topY, out var bottomY, expandUp, expandDown);
72 topY++;
73 bottomY--;
74 if (bottomY - topY < 10)
75 {
76 result = false;
77 break;
78 }
79 }
80 return result;
81 }

References Terraria.Collision.ExpandVertically(), Microsoft.Xna.Framework.Point.X, and Microsoft.Xna.Framework.Point.Y.

Referenced by Terraria.Player.CommandForbiddenStorm().