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

◆ paintTile()

static bool Terraria.WorldGen.paintTile ( int x,
int y,
byte color,
bool broadCast = false )
inlinestatic

Definition at line 36894 of file WorldGen.cs.

36895 {
36896 Tile tile = Main.tile[x, y];
36897 if (tile == null || !tile.active())
36898 {
36899 return false;
36900 }
36901 byte b = tile.color();
36902 if (b == color)
36903 {
36904 return false;
36905 }
36906 paintEffect(x, y, color, b);
36907 tile.color(color);
36908 if (broadCast)
36909 {
36910 NetMessage.SendData(63, -1, -1, null, x, y, (int)color);
36911 }
36912 return true;
36913 }
static void paintEffect(int x, int y, byte color, byte oldColor)

References Terraria.Tile.active(), Terraria.Tile.color(), Terraria.NetMessage.SendData(), and Terraria.Main.tile.

Referenced by Terraria.Player.ApplyPaint(), Terraria.MessageBuffer.GetData(), and Terraria.Player.PlaceThing_PaintScrapper_TryScrapping().

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