#unable to determine destination of item move?

1 messages · Page 1 of 1 (latest)

zinc basin
#

(making this a thread so i dont interrupt existing conversations)
im trying to detect if the player is moving an item into a particular inventory slot, but i cannot find any way to do this
InventoryMoveItemEvent doesnt specify the slots
InventoryClickEvent doesn't specify where shift-clicked items are being transferred to (and dont appear to even give you a reference to the inventory being shift-clicked to)

my end goal is to prevent the player from moving an item into the 15th slot of a particular inventory

tepid folio
#

you can get the information you want from the inventory click event

#

get the view and then you can access both inventories

#

You'll have to calculate where the shift clicked items are transfered to on your own

#

since the event is fired before that is done

zinc basin
#

thanks!

#

is all of spigot development this tedious or just the inventory related stuff?

tepid folio
#

It really does depend on what you try to do