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

/stats does not find marker armorstands in upper half of a block

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • None
    • Minecraft 1.11, Minecraft 1.11.2
    • None
    • Confirmed

      The second selector of the /stats entity command does not find marker armorstands that are in the upper half of a block when using r=0 or dy=?.

      Steps to reproduce:

      1. /scoreboard objectives add STATS_TEST dummy
      2. /scoreboard objectives setdisplay sidebar STATS_TEST
      3. /summon armor_stand ~ 57.6 ~ {Tags:["statsTest"],NoGravity:1,Marker:1}
      4. /scoreboard players set @e[type=armor_stand,tag=statsTest] STATS_TEST 0
      5. /stats entity @e[type=armor_stand,tag=statsTest] set SuccessCount @e[type=armor_stand,tag=statsTest,r=0,c=1] STATS_TEST
      6. /execute @e[type=armor_stand,tag=statsTest] ~ ~ ~ testfor @p

      After the execute-testfor command the armorstand should have a score of 1, but it has a score of 0. If I repeat the same experiment with other y values and other selectors instead of

      r=0

      there are the results:

        r=0 r=1 dy=0 dy=1
      57.0
      57.1
      57.4
      57.5
      57.6
      57.9
      A useful command to get rid of all the Armorstands
      /kill @e[type=armor_stand,tag=statsTest]
      Here is a OneCommand that creates the setup
      summon falling_block ~ ~1 ~ {Block:redstone_block,Time:1,Passengers:[{id:falling_block,Block:activator_rail,Time:1},{id:commandblock_minecart,Command:fill ~1 ~-2 ~1 ~4 ~-1 ~2 air},{id:commandblock_minecart,Command:setblock ~2 ~-2 ~2 command_block 5  {Command:scoreboard objectives add STATS_TEST dummy}},{id:commandblock_minecart,Command:setblock ~3 ~-2 ~2 chain_command_block 5  {auto:1,Command:scoreboard objectives setdisplay sidebar STATS_TEST}},{id:commandblock_minecart,Command:setblock ~4 ~-2 ~2 chain_command_block 1  {auto:1,Command:summon armor_stand ~ 57.6 ~ {Tags:["statsTest"],NoGravity:1,Marker:1}}},{id:commandblock_minecart,Command:setblock ~4 ~-1 ~2 chain_command_block 4  {auto:1,Command:scoreboard players set @e[type=armor_stand,tag=statsTest] STATS_TEST 0}},{id:commandblock_minecart,Command:setblock ~3 ~-1 ~2 chain_command_block 4  {auto:1,Command:stats entity @e[type=armor_stand,tag=statsTest] set SuccessCount @e[type=armor_stand,tag=statsTest,r=0,c=1] STATS_TEST}},{id:commandblock_minecart,Command:setblock ~2 ~-1 ~2 chain_command_block 4  {auto:1,Command:execute @e[type=armor_stand,tag=statsTest] ~ ~ ~ testfor @p}},{id:commandblock_minecart,Command:setblock ~ ~-2 ~ command_block},{id:commandblock_minecart,Command:setblock ~ ~2 ~ command_block 0  {Command:fill ~ ~-3 ~ ~ ~ ~ air}},{id:commandblock_minecart,Command:setblock ~ ~1 ~ redstone_block},{id:commandblock_minecart,Command:kill @e[type=commandblock_minecart,r=0]}]}

            Unassigned Unassigned
            Adrodoc55 Adrodoc55
            Votes:
            3 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: