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

◆ PlaceWall()

static void Terraria.WorldGen.PlaceWall ( int i,
int j,
int type,
bool mute = false )
inlinestatic

Definition at line 64969 of file WorldGen.cs.

64970 {
64971 if (i <= 1 || j <= 1 || i >= Main.maxTilesX - 2 || j >= Main.maxTilesY - 2)
64972 {
64973 return;
64974 }
64975 if (Main.tile[i, j] == null)
64976 {
64977 Main.tile[i, j] = new Tile();
64978 }
64979 if (Main.tile[i, j].wall == 0)
64980 {
64981 Main.tile[i, j].wall = (ushort)type;
64982 SquareWallFrame(i, j);
64983 if (!mute)
64984 {
64985 SoundEngine.PlaySound(0, i * 16, j * 16);
64986 }
64987 }
64988 }
static void PlaySound(int type, Vector2 position, int style=1)
static void SquareWallFrame(int i, int j, bool resetFrame=true)

References Terraria.Main.maxTilesX, Terraria.Main.maxTilesY, Terraria.Audio.SoundEngine.PlaySound(), Terraria.DataStructures.Tile, Terraria.Main.tile, and System.type.

Referenced by Terraria.MessageBuffer.GetData(), Terraria.Player.PlaceThing_Walls(), and Terraria.Player.PlaceThing_Walls_FillEmptySpace().