Stefano Bonicatti
- smjert
- smjert
- Europe/Stockholm
- Yes
- No
This has been tested in vanilla minecraft 1.6.2 and 14w30c.
When using whatever container that automatically updates the contents of a slot (like a furnace) and if the player, with the container GUI open, is constantly moving items into the inventory, the player won't see the container slot update (like a raw steak being cooked).How to reproduce:
1) open the furnace gui
2) place charcoal/coal and keep some item in your inventory
3) place something to be cooked into the furnace
4) when the progress bar is almost at the end, start continuosly left clicking an item in the inventoryWhat should happen is that the item to be cooked doesn't update (if it doesn't happen the first time, just retry), the progress bar has finished, and you won't have any item in the output slot, but if you click in it you will get the item cooked.
Why this happens:
This happen because there's a boolean in EntityPlayerMP that's set to true when the server receives a window click packet and then there the function that should send the slot updates is called, though if this boolean is true it will not send the packet to the client to update it (while the serverside thinks from the next update on that the client has received the update).
Basicly if the server code updates the content of some slots in the container (raw food to be removed, output slot set to cooked food) while the player is moving other items in the inventory.. it won't get the update.So one way to fix this would be to know which slot is getting modified by player and block the updates only for that slot and not all the container slots. Another way would be having a resend list where clients that didn't got a certain slot update, get a resend of the packet from the server.
Sorry for the duplicate, i swear i searched but didn't found this issues (probably wrong keywords). Anyway this means it will be resolved?
Because the other issues you linked is closed and Fixed but in 1.6.2 this issue still exists, so is NOT fixed.
I'm actually unable to reproduce this bug too in vanilla.
In fact i wrongly tested this with Forge, just because the problem was leading me to vanilla code.
What was happening is that due to Forge another reference didn't get cleaned and while IntegratedServer keeps those references to the world, when you load again a world the memory gets reused/freed, but due to that Forge problem it wasn't happening.
Sorry again for the wrong report.
I've updated the affected version because the problem is still present in 14w30c, the bug is reproducible in the same way.
Well i have to say that it still happens but in a corner case.
Basicly if the output slot is empty, it all works.
Though if there's already an item and another is in the way and if 2 seconds before that item arrives (cooks if its a furnace) you start moving quickly stuff in the inventory, you won't see the stack number updating, so it seems there's only one item. And you can do this for every new item, so that maybe you finally click on the output and receive 10 items.
Now, i don't know if it's worth updating the affected version, i mean.. this is a very corner case ^^.