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

"distance" selector does not seem to work with any non-zero number

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • None
    • Minecraft 18w21a
    • None
    • Windows 10 Pro 64 bit
    • Unconfirmed

      I came across this issue when trying to create a zombie HP bossbar that would detect the nearest zombie and store its hp in the bar. However, I noticed that the command selector I used (the command for storing max HP, for example, was "/execute as @p run execute store result bossbar minecraft:zombie max run data get entity @e[type=zombie,distance=10,limit=1] Attributes[0].Base"). The distance selector does not work. The command block gives no output, so there wasn't an error in the command. I confirmed this using /say as well. Doing /say hi @e[limit=1,distance=10] resulted in it just saying hi. However, using /say hi @e[limit=1,distance=0] said hi YourAverageLink, so it seems to work with a distance of 0, but not with any other number.

            Unassigned Unassigned
            AGD Alex DiGiovanni
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: