Fixed Multiple Deposit withdrawals

I have now fixed multiple deposit withdrawals. The home-made deposit plugin had a bug where it would once get the players inventory and check for space for the first item to be withdrawn, give him the item, then check for the second item and so on.

What we overlooked is that the inventory info is static in the code and does not update when when the user receives the first item. There is also no way of re-requesting the current inventory. So I had to write a process that would track the changes in the inventory manually when the user is given an item so that when he gets the second item, the system knows what space is remaining and bail if the inventory is full.

TL;DR: If you withdraw more from the deposit than your inventory can hold, you will now get as much as fits into your inventory and then the process will halt. You can make space and then start again for the rest of your deposit.

2 thoughts on “Fixed Multiple Deposit withdrawals

  1. I withdrew my items from the contest and it looked like it did a check, but not after every item. It would give me an error that my inventory is full – but also would say that I withdrew items that I didn’t have the inventory space for.

    As an example, last night when I did that it said it gave me all of my note blocks, however I did not have the space, they weren’t in my inventory and they weren’t in my deposit.

  2. The Plugin is broken again I guess… I withdrew my lottery stuff, had 2 spaces open in my inventory, and one of the 3 items vanished into thin air… Just a report…

Comments are closed.