[SPIGOT-6346] InventoryClickEvent setCancelled(true) results in duping the item Created: 07/Feb/21 Updated: 09/Feb/21 |
|
Status: | Open |
Project: | Spigot |
Component/s: | None |
Affects Version/s: | None |
Fix Version/s: | None |
Type: | Bug | Priority: | Minor |
Reporter: | NooTChhYT | Assignee: | Unassigned |
Resolution: | Unresolved | Votes: | 0 |
Labels: | Spigot, event | ||
Environment: |
Windows 10 Pro Java 8 CraftBukkit version git-Spigot-138d451-e5cb519 (MC: 1.16.5) (Implementing API version 1.16.5-R0.1-SNAPSHOT) |
Version: | 1.16.x |
Guidelines Read: | Yes |
Description |
I'm creating a custom potions plugin. I have a potion with custom model data that if you consume, it sends a packet to all players (PacketPlayOutEntityEquipment, helmet to dragon head). First, if you take it off, it should disappear, because it's not supposed to be in the inventory, it's just a packet. However, the player is able to take it off, it doesn't disappear (probably an NMS bug). The Spigot bug is: when the InventoryClickEvent gets canceled, it dupes the item (stays in the slot, but gets added to the cursor). This only happens in creative mode. |
Comments |
Comment by NooTChhYT [ 09/Feb/21 ] |
Thanks for the feedback. I don't know much about the client side, but if @md_5 says something, that's probably correct |
Comment by md_5 [ 08/Feb/21 ] |
> This only happens in creative mode. Probably can't be fixed then, creative mode is client authoritative. |
Comment by NooTChhYT [ 07/Feb/21 ] |
In survival mode, the dragon head gets removed, and the dupe doesn't occur. The server is running CraftBukkit version git-Spigot-138d451-e5cb519 (MC: 1.16.5) (Implementing API version 1.16.5-R0.1-SNAPSHOT) |
Comment by Black Hole [ 07/Feb/21 ] |
Please provide the output of the /version command. Please test that it happens in survival game mode, too. |