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

◆ WireLine()

static void Terraria.WorldBuilding.WorldUtils.WireLine ( Point start,
Point end )
inlinestatic

Definition at line 81 of file WorldUtils.cs.

82 {
83 Point point = start;
84 Point point2 = end;
85 if (end.X < start.X)
86 {
87 Utils.Swap(ref end.X, ref start.X);
88 }
89 if (end.Y < start.Y)
90 {
91 Utils.Swap(ref end.Y, ref start.Y);
92 }
93 for (int i = start.X; i <= end.X; i++)
94 {
95 WorldGen.PlaceWire(i, point.Y);
96 }
97 for (int j = start.Y; j <= end.Y; j++)
98 {
99 WorldGen.PlaceWire(point2.X, j);
100 }
101 }

References Terraria.WorldGen.PlaceWire(), System.start, Microsoft.Xna.Framework.Point.X, and Microsoft.Xna.Framework.Point.Y.

Referenced by Terraria.GameContent.Biomes.MiningExplosivesBiome.Place(), and Terraria.WorldGen.PlaceStatueTrap().