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

◆ WouldTileReplacementBeBlockedByLiquid()

static bool Terraria.WorldGen.WouldTileReplacementBeBlockedByLiquid ( int x,
int y,
int liquidType )
inlinestatic

Definition at line 53362 of file WorldGen.cs.

53363 {
53364 if ((Main.tile[x - 1, y].liquid <= 0 || Main.tile[x - 1, y].liquidType() != liquidType) && (Main.tile[x + 1, y].liquid <= 0 || Main.tile[x + 1, y].liquidType() != liquidType))
53365 {
53366 if (Main.tile[x, y - 1].liquid > 0)
53367 {
53368 return Main.tile[x, y - 1].liquidType() == liquidType;
53369 }
53370 return false;
53371 }
53372 return true;
53373 }

References Terraria.Main.tile.

Referenced by Terraria.Player.PlaceThing_ValidTileForReplacement().