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

Entities without hitboxes cannot properly be tested for with target argument "distance=0" or "dy=0"


    • Type: Bug
    • Status: Reopened
    • Resolution: Unresolved
    • Affects Version/s: Minecraft 1.8.8, Minecraft 15w36d, Minecraft 15w37a, Minecraft 15w42a, Minecraft 15w51b, Minecraft 16w05b, Minecraft 1.9 Pre-Release 4, Minecraft 1.9, Minecraft 1.9.1 Pre-Release 3, Minecraft 1.9.4, Minecraft 16w21b, Minecraft 1.10.2, Minecraft 1.11 Pre-Release 1, Minecraft 1.11, Minecraft 1.12 Pre-Release 5, Minecraft 1.12 Pre-Release 7, Minecraft 1.12.1, Minecraft 1.12.2, Minecraft 17w50a, Minecraft 18w05a, Minecraft 18w10d, Minecraft 18w16a, Minecraft 1.13-pre3, Minecraft 1.13-pre4, Minecraft 1.13-pre5, Minecraft 1.13-pre6, Minecraft 1.13-pre7, Minecraft 1.13-pre8, Minecraft 1.13-pre9, Minecraft 1.13
    • Fix Version/s: Minecraft 16w38a
    • Confirmation Status:
      Community Consensus


      These experiments involve marker armorstands – it also affects area effect clouds with zero radius. Most likely the bug occurs due to these armorstands lacking a hitbox.

      Setup experiment
      In this scenerio the armorstands involved in the testing were obtained as follows:

      /summon armor_stand ~ ~ ~ {CustomName:"\"A\"",Marker:X}
      /execute at @e[name=A] run summon armor_stand ~ ~ ~ {CustomName:"\"B\"",Marker:X}

      Note that the X is either a 0 or 1 depending on the following cases.

      Results experiment
      We distinguish the following 3 cases

      • Case 1: ArmorStand A is not a marker, ArmorStand B is not a marker.
        execute at @e[name=A] run kill @e[name=B,distance=0]

        Kills B, works as expected

        execute at @e[name=B] run kill @e[name=A,distance=0]

        Kills A, works as expected

      • Case 2: ArmorStand A is a marker, ArmorStand B is not a marker.
        execute at @e[name=A] run kill @e[name=B,distance=0]

        Kills B, works as expected

        execute at @e[name=B] run kill @e[name=A,distance=0]

        Does not kill A, does not work as expected

      • Case 3: ArmorStand A is a marker, ArmorStand B is a marker.
        execute at @e[name=A] run kill @e[name=B,distance=0]

        Does not kill B, does not work as expected

        execute at @e[name=B] run kill @e[name=A,distance=0]

        Does not kill A, does not work as expected

      Further research
      I've had a talk about these seemingly bugs with SkylinerW who in the MC community is a well respected modder/'expert' on Minecraft. This talk can be found back in this reddit topic:

      Here are some extracts from our conversation that might help you guys further, credit to SkylinerW:

      "That one definitely seems to be a bug. It's not just armor stands, but any entity that is in the ground; I can't get the command to work even if there's a villager with its feet stuck in a block directly underneath the armor stand without increasing the radius to 2 (r=1 still presents the problem, so it's not restricted to r=0). It's specific to the Y coordinate, so it seems like their interpreted location is being skewed for being within a block. I imagine the eye height for marker stands being at the exact Y value causes it to be seen as being within a block.

      Code analysis by [Mod] Marcono1234 can be found in this comment.

      Also this can be more easily tested with this being run in chat while you don't move:

      summon armor_stand ~ ~ ~ {NoGravity:1b,Marker:1b,CustomName:"\"c\""}
      say @e[distance=0]

      this'll only show your name and not the armor stand's, unless you change it to Marker:0b


          Issue Links



              • Assignee:
                GamerGuppy GamerGuppy
              • Votes:
                50 Vote for this issue
                29 Start watching this issue


                • Created: