MinusKube / SmartInvs

Advanced Inventory API for your Minecraft Bukkit plugins.
https://minuskube.gitbook.io/smartinvs/
Apache License 2.0
262 stars 65 forks source link

.listener InventoryClickEvent get not called when clicking air. #190

Closed Rysefoxx closed 3 years ago

Rysefoxx commented 3 years ago

.listener(new InventoryListener<>(InventoryClickEvent.class, new Consumer<InventoryClickEvent>() { @Override public void accept(InventoryClickEvent event) { Bukkit.broadcast(Component.text("ABC")); } }))

I then only see the broadcast message "ABC" when I click on an item within the inventory. If I click on a slot where there is no item, this message is not displayed.

For what I have in mind, it is important that the event is triggered when I click on an empty slot.

Is there an alternative or integrated function that I don't know yet?

Rysefoxx commented 3 years ago

I workarounded and set Eventhandler's priority to lowest.