elgbar / instant-inventory

Runelite plugin to instantly do inventory actions
https://runelite.net/plugin-hub/show/instant-inventory
BSD 2-Clause "Simplified" License
7 stars 0 forks source link

Deposit into group ironman bank does not work #16

Closed elgbar closed 6 months ago

elgbar commented 6 months ago

Describe the bug

Group ironman bank storage; upon depositing items to the group storage (with this plugin enabled) the items actually go to the storage. However, the item I just deposited "appears" on my inventory still, yet having the option to still "deposit" them, even though they don't actually exist in my inventory anymore.

To Reproduce Steps to reproduce the behaviour:

  1. Open Group Storage on a Group Ironman
  2. Deposit item(s) into the bank
  3. The item will reappear in the bank container.

Expected behaviour

The item should disappear when being deposited into the group ironman bank.

Screenshots

gim-deposit-bug.webm

Additional context

Originally reported in https://github.com/elgbar/instant-inventory/issues/14#issuecomment-1974784169

elgbar commented 6 months ago

Fixed in v1.2.1

elgbar commented 6 months ago

To add some context to this issue: Normally the plugin validate the state of the inventory by looking at the inventory container found with InventoryID.INVENTORY, but when the group storage is open another inventory is used called InventoryID.GROUP_STORAGE_INV.

The issue is that the normal inventory does not get updated when in the group storage, thus it will reset items to the incorrect state. This is now resolved by selecting the correct inventory when the group storage is open.

A slight complication is that if there are no items in the inventory (e.g., after depositing all items) the InventoryID.GROUP_STORAGE_INV will no longer exist, i.e., be reported as null. This is accounted for