I try to make a tagged Armor Stand look at the same place as the player, but I can't find a way to do it.
For example, if the player looks in the direction of the (x, y, y) block, the Armor Stand should look at the (x, y, z) block.
For now I wrote the following command, but it only rotates the Armor Stand in the same direction as the player, it doesn't make it look at the same place:
/execute as @e[tag=my_armor_stand] at @s rotated as @p run teleport @s ~ ~ ~ ~ ~
If this should take more than one command, it is also okay.