Setting PlayerBucketEmptyEvent cancelled still empties the bucket, opening a block with inventory reverts bucket to pre-event ItemStack.

    • Type: Bug
    • Resolution: Fixed
    • Priority: Minor
    • None
    • Affects Version/s: None
    • Environment:

      Windows

    • 1.13.2
    • Yes

      Recreate:

      Create a PlayerBucketEmptyEvent listener.  Set event.Cancelled(true).

       

      What happens:

      Bucket empties as normal and reverts to Material.BUCKET.

      Open an inventory block (chest, furnace, crafting table etc.), bucket reverts to what it was before the event (Material.SALMON_BUCKET in my case).

       

      I'm trying to access the ItemMeta on the original bucket and only cancel the event if the Meta matches a given criteria.  I can't get the ItemMeta until it reverts when I open an inventory block.

            Assignee:
            Unassigned
            Reporter:
            Reg
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: