mojira.dev
MC-132424

Arrows, and maybe other projectiles, ignore rotation parameter in the /tp command

The bug

Arrows without any motion ignore the rotation parameter of the /tp command and always try to match rotation [0, 0].
Arrows with motion always point in the direction they are moving towards, but that is likely working as intended.

How to reproduce

/summon minecraft:arrow ~ ~ ~ {NoGravity: 1}
/execute as @e[type=minecraft:arrow] at @s run tp @s ~ ~ ~ ~45 ~

→ ❌ The arrow is not going to rotate by 45 degree. It instead just face the original direction.

Attachments

Comments 8

I think it is rotated, but only on serverside. Check:
MC-99442
MC-103426
MC-124197

I believe that the direction is not changed server side, or at least not count into the direction of directional tp at all.
If you intead use ^ directional tp to move the arrow.
In the next directional tp, the arrow is still go straight just like it displayed

I checked it with command:
/data get entity @e[limit=1,type=minecraft:arrow] Rotation[0]
It seems that rotation is done, but arrow rotates back itself almost instant to the direction it flies. As it doesn't fly to any direction, direction is by default [0,0], as so rotation.

20w06a "affected" Description needs to be updated:

Rotation of projectile with velocity=[0,0,0] changes to [0,0] right after forcing it to another direction with command. It should stay without any change.

Can confirm in 20w49a.

Can confirm in 21w06a.

Can confirm in 1.16.5 and 21w10a. Video attached.

Can confirm in 1.17.1.

Jit-Yu Wang

(Unassigned)

Confirmed

(Unassigned)

Minecraft 1.13-pre5, Minecraft 1.13.1, 20w06a, 1.16.4, 20w49a, 1.16.5, 21w06a, 21w10a, 1.17.1, 1.21

Retrieved