Extend NetItem
This commit is contained in:
parent
0535f6b7c6
commit
d5fb8726cc
7 changed files with 170 additions and 194 deletions
|
|
@ -1278,14 +1278,14 @@ namespace TShockAPI
|
|||
|
||||
// Players send a slot update packet for each inventory slot right after they've joined.
|
||||
bool bypassTrashCanCheck = false;
|
||||
if (plr == args.Player.Index && !args.Player.HasSentInventory && slot == NetItem.maxNetInventory)
|
||||
if (plr == args.Player.Index && !args.Player.HasSentInventory && slot == NetItem.MaxInventory)
|
||||
{
|
||||
args.Player.HasSentInventory = true;
|
||||
bypassTrashCanCheck = true;
|
||||
}
|
||||
|
||||
if (OnPlayerSlot(plr, slot, stack, prefix, type) || plr != args.Player.Index || slot < 0 ||
|
||||
slot > NetItem.maxNetInventory)
|
||||
slot > NetItem.MaxInventory)
|
||||
return true;
|
||||
if (args.Player.IgnoreSSCPackets)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue