Inaccurate warehouse counts
wadewegner opened this issue ยท 14 comments
I'm beginning to suspect that warehouse counts are not accurate.
Here you see Light Torque Distributors & Shafts. When I click on them, though, I get nothing -- I can drag into inventory.
If I add the 3 from my inventory back in ...
... and then shift-click to take out ...
... notice it only takes out there, leaving two (which now can't be clicked).
I'm on latest: ancientwarfare-1.12.2-2.5.82.jar
Are you on dedicated server? I am guessing there's something funky happening with synch packets.
The best would be if you had steps to recreate that I can follow, but I understand that may not be that easy when this is happening to half full warehouse so I will try to recreate on my side as well.
Btw, I hope you're not expecting clean code because what's in is pretty far from that. If you would like to I could give you some pointers, but that's probably easier to explain in a chat app than here (I know, I sound like a broken record here)
@P3pp3rF1y I can't find your contact info you shared in another issue. Can you share again so we can can chat w/o going through issues? :)
So, I am using IntelliJ myself, but I hope Eclipse has similar setup after running gradle eclipse task. In which case you should see Run Server configuration in there and run dedicated server locally that you can debug as any other project. Just be prepared to run into issues with client dropping off that server because it's unresponsive.
However I have tried recreating this locally in single player first and found a small issue where when you take from a big stack of a single item very quickly it would sometimes give you more than a stack size, the same count would be removed from warehouse so no duplication issue, but potentially this could keep client out of sync on dedicated server. I have that fixed and am going to check dedicated server now.
One more question that I believe I know the answer to:
When you close the UI does it get fixed or does server restart help?
I would think that you have tried the first, but am wondering if this persists after restart as well.
Thanks for the info. I'm going to switch to IntelliJ. Been looking for an excuse. (I'm actually a VS Code guy.)
No, closing the UI doesn't help/fix it. Haven't tried a server restart, but I can next time I notice it happening.
And actually can you check if the items you cant take out you have in one of the storage blocks. After looking through code i am guessing it lost cached pointer to the storage where the item is stored.
I am VS C# guy originally and find idea closer to vs than eclipse is. Not as simple as vs code though.