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

◆ PlantSeaOat()

static bool Terraria.WorldGen.PlantSeaOat ( int x,
int y )
inlinestaticprivate

Definition at line 49237 of file WorldGen.cs.

49238 {
49239 if (Main.tile[x, y].wall > 0 || Main.tile[x, y].active() || Main.tile[x, y].liquid > 0 || !SolidTileAllowBottomSlope(x, y + 1) || !TileID.Sets.Conversion.Sand[Main.tile[x, y + 1].type])
49240 {
49241 return false;
49242 }
49243 if (!SeaOatWaterCheck(x, y))
49244 {
49245 return false;
49246 }
49247 Main.tile[x, y].active(active: true);
49248 Main.tile[x, y].slope(0);
49249 Main.tile[x, y].halfBrick(halfBrick: false);
49250 Main.tile[x, y].type = 529;
49251 Main.tile[x, y].frameX = (short)(genRand.Next(5) * 18);
49252 int num = 0;
49253 Main.tile[x, y].frameY = (short)(num * 34);
49254 if (Main.netMode == 2)
49255 {
49256 NetMessage.SendTileSquare(-1, x, y);
49257 }
49258 return true;
49259 }
static UnifiedRandom genRand
Definition WorldGen.cs:1215
static bool SeaOatWaterCheck(int x, int y)
static bool SolidTileAllowBottomSlope(int i, int j)

References Terraria.Main.netMode, Terraria.ID.TileID.Sets.Conversion.Sand, Terraria.NetMessage.SendTileSquare(), and Terraria.Main.tile.