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

Inconsistent interpolation animations can result from desync on display entities

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • None
    • 23w13a
    • None
    • Plausible
    • Commands, Entities

      This bug has been separated out from MC-260874

      Multiple animations from desync

      The game can desync, for example, depending on how much the user pauses. This then becomes evident when a transform animation is applied, which can cause animations to behave in multiple different ways based on how desynced they are.

      Animations may appear to manifest in multiple ways with a single set of deterministic commands that are different from each other when desynced, when the expected behavior is a single animation.

      Pausing the game for various lengths of time may trigger this desync. This desync appears to be due to interpolation occasionally happening in the tick after it was set, resulting in different forms of the animation appearing for different desync timings. This may or may not be expected behavior by changes to how updates to transformations are handled in the release candidate.

      Videos have been attached to demonstrate the varying ways this issue manifests.

      To Reproduce (constant 20hz demonstration)

      1. Create a void superflat world
      2. /scoreboard objectives add test dummy
      3. Place these 5 commands in order in a command block chain starting with a repeating command block
        execute positioned 0 -58 0 run summon minecraft:block_display ~ ~ ~ {Tags:[bob],block_state:{Name:"stone"},transformation:{translation:[0.0f,0.0f,0.0f],scale:[0.0f,0.0f,0.0f],left_rotation:[0.0f,0.0f,0.0f,1.0f],right_rotation:[0.0f,0.0f,0.0f,1.0f]},start_interpolation:0,interpolation_duration:0}
        scoreboard players add @e[tag=bob] test 1
        execute as @e[tag=bob,scores={test=2}] run data merge entity @s {transformation:{scale:[0.1f,0.1f,0.1f],translation:[0.0f,2.0f,0.0f]},start_interpolation:0,interpolation_duration:0}
        execute as @e[tag=bob,scores={test=20}] run data merge entity @s {transformation:{scale:[0.1f,0.1f,0.1f],translation:[0.0f,0.0f,0.0f]},start_interpolation:0,interpolation_duration:40}
        kill @e[tag=bob,type=minecraft:block_display,scores={test=50..}]
        
      4. Hold down the pause button, or ESC, and observe that occasionally there will be a missing spot in the line of animating displays due to a desync
      5. This datapack can also be used to test the commands above: [^display_test.zip]
      6. See video: desync1 (epilepsy warning).mp4

      To Reproduce (20hz desync demonstration)

      1. Create a void superflat world
      2. /scoreboard objectives add test dummy
      3. Place these 5 commands in order in a command block chain starting with a repeating command block
        summon minecraft:block_display ~ ~1 ~ {Tags:[bob,joe],block_state:{Name:"stone"}}
        execute as @e[tag=joe] run data merge entity @s {transformation:{scale:[0.1f,0.1f,0.1f],translation:[0.0f,2.0f,0.0f]},start_interpolation:0,interpolation_duration:40}
        tag @e remove joe
        scoreboard players add @e[tag=bob] test 1
        kill @e[tag=bob,type=minecraft:block_display,scores={test=40..}]
        
      4. Notice that the animation occasionally appears to animate from default transformation instead of staying at the second transformation
      5. This appears to demonstrate the desync, where the data merge'd transformation is applying on the following tick instead of the summon tick
      6. Pause the game for different lengths of time to observe that the desync'd animation may or may not appear for different lengths of time.
      7. See video: desync2.mp4

            Unassigned Unassigned
            onnowhere Onnowhere
            Votes:
            4 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: