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

Structure blocks don't rotate when loaded by a structure block

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • None
    • 1.20.1, 1.20.2 Pre-release 1, 23w44a
    • None
    • Community Consensus
    • Block states
    • Low
    • Platform

      When you load a rotated structure there are blocks which change, such as logs, but if the structure contains another structure block that block doesn't change at all if rotated. I think it would be better if they did, tho, in order to totally rotate the structure.

      For example, I have created a structure named "structure" which contains 4 logs:

      After that, I created a structure named "hello" which contains a log and a load structure block:

      The content of the structure block contained in "hello" is:

      Then I tried to load the "hello" structure somewhere else but rotating it:

      As you can see, the log has been changed to be rotated, but this hasn't happened for the generated structure block, which has still the same parameters of the original one:

      I would have expected this result in this case, tho:

      This could be solved with this formula:

      taken "x" the x-coordinate of Relative Position of the original block, "z" the z-coordinate of Relative Position of the original block, "angle" the angle of rotation in degrees of the original block and "rotation" the angle of rotation in degrees of the structure that includes the block, the new values will be:

      new_x = x*cos(rotation)-z*sin(rotation)
      new_z = x*sin(rotation)+z*cos(rotation)
      new_angle = (angle+rotation)mod360

      In this specific case, the values would be:

      angle = 0°, rotation = 90°, x=-1, z=0

      and the result:

      new_x = -1*cos(90°)-0*sin(90°) = 0
      new_z = -1*sin(90°)+0*cos(90°) = -1
      new_angle = (0°+90°)mod360 = 90°

        1. 2023-09-06_02.07.45.png
          2023-09-06_02.07.45.png
          572 kB
        2. 2023-09-06_02.07.49.png
          2023-09-06_02.07.49.png
          359 kB
        3. 2023-09-06_02.13.04.png
          2023-09-06_02.13.04.png
          554 kB
        4. 2023-09-06_02.13.18.png
          2023-09-06_02.13.18.png
          350 kB
        5. 2023-09-06_02.13.32.png
          2023-09-06_02.13.32.png
          520 kB
        6. 2023-09-06_02.13.45.png
          2023-09-06_02.13.45.png
          316 kB
        7. 2023-09-06_02.23.17.png
          2023-09-06_02.23.17.png
          498 kB
        8. 2023-09-06_02.23.29.png
          2023-09-06_02.23.29.png
          325 kB
        9. 2023-09-06_02.23.41.png
          2023-09-06_02.23.41.png
          477 kB
        10. 2023-09-06_02.24.03.png
          2023-09-06_02.24.03.png
          320 kB
        11. 2023-09-06_02.24.56.png
          2023-09-06_02.24.56.png
          315 kB
        12. 2023-11-06_19-31-30.mp4
          3.12 MB

            Unassigned Unassigned
            GiAnMMV GiAnMMV
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              CHK: