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

PlayerInteractEvent only calling once while using a brush

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • None
    • This server is running CraftBukkit version 3904-Spigot-224dad5-1bf30a4 (MC: 1.20.2) (Implementing API version 1.20.2-R0.1-SNAPSHOT)
    • Yes

      Currently since there is no PlayerBrushEvent (which should be added), we're having to use the PlayerInteractEvent.

      If a player begins to start "brushing" (holding right click with a brush in hand) the PlayerInteractEvent only fires one time, and not each time the player attempts to brush. This causes issues where we have no way to fully detect when a player is trying to brush a block.

      Example:
      If I'm attempting to create a land claiming plugin, and want to protect a player build. If the player is using suspicious gravel or sand in their build, there is no way to prevent another player from brushing. They can begin and start the "brushing" animation, while outside of the claim, (holding right click with a brush in hand), and continue this animation, walk into the claim then begin brushing the suspicious gravel/sand.

      Here's a real example we're struggling with at GriefPrevention
      https://github.com/TechFortress/GriefPrevention/pull/2162

            Unassigned Unassigned
            QarthO QarthO
            Votes:
            3 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: