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

Advancement will detect multiple blocks at once and execute multiple times in one tick

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Works As Intended
    • None
    • Minecraft 17w17b
    • Windows 7 Professional
      Java 1.8.0_51 64bit
    • Community Consensus

      If you create an advancement with criteria that has one trigger, an "enter_block" trigger with no extra data, that has a command reward where it revokes itself, it will execute more than 20 times per second (multiple times per tick).

      It detect the block the player is in both on their head and feet, triggering the advancement once for each. Also, when a player is between two blocks, it will trigger the advancement FOUR times, once for their head and feed on each block. This can be increased to 8 times, and even 12 times when in the air or standing on a slab. This means the commands run 240 times per second, rather than 20.

      This breaks down systems that rely on advancements to trigger 20 times per second without external command blocks, as the clock speed will fluctuate as the player moves around and enters different amounts of blocks at once.

      Steps to recreate
      1. Put the main.json file into a folder called 'test' in the data/advancements folder
      2. Open world
      3. Place down repeating command block with say command in it, and set to always active (to see what 20 tps looks like)
      4. Observe how the amount of messages from the advancement between the 20 tps command block is always larger than 1, and changes as you move around

            Unassigned Unassigned
            johnnyhotshotmc@gmail.com Johnny Puskar
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: