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

Display entity transformation property applied with incorrect order

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • None
    • 1.19.4, 1.20 Pre-release 1
    • None
    • Unconfirmed
    • Commands

      The 'transformation' NBT property is incorrectly applying translation last, according to the order defined by the 1.19.4 Release Notes (https://www.minecraft.net/en-us/article/minecraft-java-edition-1-19-4) "Transforms are composed in order translation, left_rotation, scale, right_rotation".

      Interestingly however, the visual/affine transformations applied by billboard: "center" are correctly applying translation first.

      A use case currently impossible due to the bug: animating planetary rotation around a central axis; because translations are being applied last in the transformation property, it is currently not possible to spin a model around its center.

      Steps to reproduce:

      1. Set up a stack of command blocks (as pictured): one impulse, three chain. And place end rods or other centered block as a reference.
      2. The first (impulse) should remove existing entities for convenience:
        kill @e[type=block_display] 
      3. The second (chain) should summon a block display with translation, but rotated using the transformation property:
        summon block_display ~ ~3.5 ~ {block_state:{Name:"tinted_glass"},transformation:{translation:[-0.5f,-0.5f,-0.5f],left_rotation:{angle:0.7f,axis:[0.57735f,0.57735f,-0.57735f]},right_rotation:{angle:0f,axis:[0f,0f,1f]},scale:[1f,1f,1f]}}  
      4. The third (chain) should summon a block display with translation, but rotation caused by billboard: "center":
        summon block_display ~ ~2.5 ~ {block_state:{Name:"glass"},billboard:"center",transformation:{translation:[-0.5f,-0.5f,-0.5f],left_rotation:{angle:0f,axis:[0.57735f,0.57735f,-0.57735f]},right_rotation:{angle:0f,axis:[0f,0f,1f]},scale:[1f,1f,1f]}}  

      Observed Results:

      • The block rotating with billboard: "center" rotates about the tip of the end rod.
      • The block rotated with the transformation property rotates offset from the tip of the end rod.

      Expected Results:

      • The block rotated with the transformation property should be rotated about the tip of the end rod.

      Screenshots / Videos:

      Notes:

      • Setup in screenshots as described in steps to reproduce.
      • Occurs since introduction of display entities in 1.19.4
      • Bug surfaced when attempting to build an animated clockface with commands.
      • Known to apply to block_display, item_display. Unsure about text_display, though likely.

            Unassigned Unassigned
            Mytanic Mytanic
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: