diff --git a/TShockAPI/TShock.cs b/TShockAPI/TShock.cs index 8d76efea..07427ffd 100644 --- a/TShockAPI/TShock.cs +++ b/TShockAPI/TShock.cs @@ -416,6 +416,20 @@ namespace TShockAPI StatTracker.checkin(); + FixChestStacks(); + + } + + private void FixChestStacks() + { + foreach(Chest chest in Main.chest) + { + foreach(Item item in chest.item) + { + if (item.stack > item.maxStack) + item.stack = item.maxStack; + } + } } @@ -1187,6 +1201,10 @@ namespace TShockAPI Netplay.serverPort = file.ServerPort; } + if (file.MaxSlots > 250) + file.MaxSlots = 250; + Main.maxNetPlayers = file.MaxSlots + 5; + Netplay.spamCheck = false; RconHandler.Password = file.RconPassword;