Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-122008

CustomPotionEffects in arrow entities duplicates with '/execute store' and isn't affected by '/data remove'

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Resolution: Unresolved
    • Affects Version/s: Minecraft 17w47a, Minecraft 17w47b, Minecraft 17w48a, Minecraft 17w50a, Minecraft 18w01a, Minecraft 18w03b, Minecraft 18w21a, Minecraft 18w21b, Minecraft 1.13-pre1, Minecraft 1.13-pre2, Minecraft 1.13-pre3, Minecraft 1.13-pre4, Minecraft 1.13-pre5, Minecraft 1.13-pre6, Minecraft 1.13-pre7, Minecraft 1.13, Minecraft 18w31a, Minecraft 1.13.1
    • Fix Version/s: None
    • Confirmation Status:
      Community Consensus
    • Category:
      (Unassigned)

      Description

      The bug

      When using the /execute store command on a tipped arrow with custom potion effects, rather than replace the respective NBT, it will duplicate the field first, THEN replace the respective NBT in the new field.

      How to reproduce

      summon in Arrow entity with nbt data:

      { 
       CustomPotionEffects: [
       {Ambient: 0b, ShowParticles: 1b, Duration: 1200, Id: 26b, Amplifier: 1b}
       ]
      }
      

      Example command:

      /execute store result entity @e[limit=1,type=arrow] CustomPotionEffects[0].Id byte 1 run scoreboard players get null1 arrow_events
      

      using /data get on the entity results in:

      Arrow has the following entity data: { 
        CustomPotionEffects: [
          {Ambient: 0b, ShowParticles: 1b, Duration: 1200, Id: 26b, Amplifier: 1b}, 
          {Ambient: 0b, ShowParticles: 1b, Duration: 1200, Id: 1b, Amplifier: 1b}
        ]
      }
      

      Using /data remove doesn't seem to modify the CustomPotionEffects tag at all.

      /data remove entity @e[limit=1,type=arrow] CustomPotionEffects[0]
      

      using this and then /data get gives the same results as listed above.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                MukiTanuki MukiTanuki
              • Votes:
                8 Vote for this issue
                Watchers:
                11 Start watching this issue

                Dates

                • Created:
                  Updated:
                  CHK: