Uploaded image for project: 'Spigot'
  1. Spigot
  2. SPIGOT-5435

Hand calls twice PlayerInteractEvent when using potions

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • Icon: Minor Minor
    • None
    • None
    • git-Spigot-f39a89e-f777640 (MC: 1.15) (Implementing API version 1.15-R0.1-SNAPSHOT)
    • Yes

      This is a behaviour that doesnt happen in spigot 1.14.4 but yes in the 1.15 version.

       

      When right clicking potions and pointing the air, the PlayerInteractEvent is being called twice with Hand (I am cancelling the call if Off hand is calling). This doesnt happen if you are right clicking a block or a mob, just the air. And this doesnt happen if you are using left click.

       

      I have made a test plugin so you can see it, basicly, just interact with items and you will notice the difference. The plugin tells you that the event is being called, with which item and if HAND called it. Also, I recorded a video, which I couldnt upload because of size but here is the link: https://streamable.com/ed1do

       

      As far as I tested this bug happens with this items: (it doesnt happen with GLASS_BOTTLE)

      • POTION (any kind)
      • SPLASH_POTION (any kind)
      • LINGERING_POTION (any kind)
      • EXP_BOTTLE
      • HONEY_BOTTLE
      • ENDER_PEARL
         

      Source code of test plugin: https://pastebin.com/VPLpmMme

            md_5 md_5
            xtomyserrax xtomyserrax
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: