Definition at line 38432 of file Player.cs.
38433 {
38435 {
38436 return;
38437 }
38439 for (int i = 0; i < 4; i++)
38440 {
38443 if (i == 0)
38444 {
38446 }
38447 if (i == 1)
38448 {
38450 }
38451 if (i == 2)
38452 {
38454 }
38455 if (i == 3)
38456 {
38458 }
38459 if (Main.tile[
num,
num2].wall != 0)
38460 {
38461 continue;
38462 }
38464 for (
int j = 0;
j < 4;
j++)
38465 {
38469 {
38471 }
38473 {
38475 }
38477 {
38479 }
38481 {
38483 }
38484 if (Main.tile[
num4,
num5].wall == createWall)
38485 {
38487 }
38488 }
38490 {
38491 continue;
38492 }
38494 if (Main.tile[
num,
num2].wall == createWall)
38495 {
38497 {
38499 }
38501 {
38503 }
38504 if (Main.netMode == 1)
38505 {
38506 NetMessage.SendData(17, -1, -1,
null, 3,
num,
num2, createWall);
38507 }
38509 {
38511 }
38512 }
38513 }
38514 }
int stack
The current stack of the item. F:Terraria.Item.maxStack indicates the max possible stack.
int createWall
The ID of the wall this item places on use. Either a T:Terraria.ID.WallID entry or M:Terraria....
void SetDefaults(int Type=0)
static bool ConsumeItem(Item item, Player player)
If ModItem.ConsumeItem or any of the GlobalItem.ConsumeItem hooks returns false, sets consume to fals...
This serves as the central class from which item-related functions are carried out....
void TryPainting(int x, int y, bool paintingAWall=false, bool applyItemAnimation=true)
Item[] inventory
The player's normal inventory. Indexes 0-9 hold the hotbar items, 10-49 the rest of the main inventor...
References Terraria.Player.autoPaint, Terraria.Player.builderAccStatus, Terraria.ModLoader.ItemLoader.ConsumeItem(), Terraria.Item.createWall, Terraria.Player.inventory, Terraria.Main.netMode, Terraria.WorldGen.PlaceWall(), Terraria.Player.selectedItem, Terraria.NetMessage.SendData(), Terraria.Item.SetDefaults(), Terraria.Item.stack, Terraria.Main.tile, Terraria.Player.tileTargetX, Terraria.Player.tileTargetY, and Terraria.Player.TryPainting().
Referenced by Terraria.Player.PlaceThing_Walls().