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

entity.remove() on a leash drops a lead item

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • None
    • None
    • 3870-Spigot-d2eba2c-78796c9 (MC: 1.20.1)
    • Yes

      Whenever you call entity.remove() on a LeashHitch entity, a lead item is dropped at the entity's location.

      I'm not sure if this is expected behavior, but when we do the same on a painting or an item frame, they do not drop anything.

      entity.remove() should simply remove the entity without spawning any item.

       

      I made a small plugin to test this out.
      You can follow these steps:
      1. attach lead to any entity
      2. attach it to a fence
      3. in survival mode, break the attached leash
      4. a diamond and a lead will drop

      another testing:

      1. attach lead to any entity
      2. attach it to a fence

      3. right click on the leash with an empty hand

      4. send a message in chat
      5. the leash is broken and there's a new lead on the ground

        1. image-2023-09-21-18-36-54-824.png
          81 kB
          Maxime Deraiche Jenkins

            Unassigned Unassigned
            Maxx_Qc Maxime Deraiche Jenkins
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: