Closed bcat closed 1 year ago
Rebased against HEAD to resolve conflicts (which reset the approval status, sorry!).
and the server decides what chests are close enough
Where does the server decide this? I don't see range checks in Packet 85's code path
It's right there in Chest.PutItemInNearbyChest
🤔
Vector2 vector = new Vector2(Main.chest[i].x * 16 + 16, Main.chest[i].y * 16 + 16);
if ((vector - position).Length() >= 600f)
{
continue;
}
Ahh. Found it
Fixes #2885.
As described here, vanilla Terraria already has a range check for quick stacking (packet 85 from the client only lists the inventory slot to quick stack, and the server decides what chests are close enough). As such, removing TShock's check is safe, and it enables quick stacking to the same range as vanilla (~36 tiles) rather than the 32 tiles TShock is limited to with the extra range check.
Example of distance that you couldn't quick stack from before, but can now after this fix: