Not using a selector in a tp command breaks rotation from a completely different tp command
a teleport command which doesn't affect rotation at all makes the following teleport commands give the entity different rotation values depending on whether the original tp command uses the @s selector, or no selector at all.
Steps to reproduce:
-Download the example datapack
-Run /execute positioned 0.0 0.0 0.0 summon minecraft:marker at @s rotated 0 -50 run function example:test1
-Run /execute positioned 0.0 0.0 0.0 summon minecraft:marker at @s rotated 0 -50 run function example:test2
-Compare the Rotation values given by the /tellraw command
Expected Behavior:
Using an @s selector vs not using a selector wouldn't affect the rotation resulting from a completely different teleport command (Just like it worked in 1.21.1)
Observed Behavior:
The difference between using an @s selector vs not using one is visible through the entity's rotation
/data/example/test1.mcfunction -> gives a Rotation[1] value of 89.99999f (expected value)
tp @s 0.0 0.0 0.0
tp @s ~ ~10 ~
execute at @s facing 0.0 0.0 0.0 run tp @s 0 0 0 0 ~
tellraw @a {"entity":"@s","nbt":"Rotation[1]","color":"green"}
/data/example/test2.mcfunction gives a Rotation[1] value of 40.0f (it seems to always add 90° to the rotation given in execution context)
tp 0.0 0.0 0.0
tp @s ~ ~10 ~
execute at @s facing 0.0 0.0 0.0 run tp @s 0 0 0 0 ~
tellraw @a {"entity":"@s","nbt":"Rotation[1]","color":"green"}
2024-09-14, 11:29 AM
2024-09-19, 11:58 PM
2024-09-17, 11:03 AM
8
2