Stopping item_slot from calling _drop_data from _inventory_grid_stacked_transfer if the item is not to be unequipped #281
Replies: 2 comments
-
|
Not sure I fully understand the issue here.
So, is the item equipped in the slot or not? If not then how is it being dragged from the item slot? |
Beta Was this translation helpful? Give feedback.
-
|
Well, rereading this, its a pretty good example of the 3 am brain 🤦 The issue is that I have duplicated which works fine as far as functionality is concerned. Below is an MRE from the latest Gloot version, tested on 4.5.dev1.mono of the exact configuration explained above. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, I'm using
inventory_grid_stacked_transfer.gdfor my inventory andctrl_item_slot.gdfor my equipment/item slots. Tested this on the current stable gloot version and saw the same issue however. I create adrop_data_instanceso items are dropped on the ground like so ininventory_grid_stacked_transfer.gd:However,
ctrl_item_slot.gdalso calls it when dragging the item from the item slot outside the inventory, even though the item in the item slot is not unequipped. Is there an intended way to circumvent this? I am not 100% sure where the slot calls_drop_datafrom, the control flow was not the easiest to follow I'm afraid.Any help at all would be greatly appreciated!
Beta Was this translation helpful? Give feedback.
All reactions