mojira.dev
MC-276516

Teleport command ignores execution position

Command:

/execute as @s at @n[type=pig] run teleport ~ ~ ~

 

Expected behaviour:

The entity running the command would teleport to the nearest pig.

 

Actual behaviour:

The entity is teleported to its own relative coordinates.

 

Other notes:

  • This seems to apply to both teleport and tp commands.

  • The behaviour is the same when attempting to use execute positioned, regardless of if the position is another entity or a constant value. (edit: if the positioned value is set to a specific coordinate, it will print in chat the correct coordinates)

  • This bug prevents being able to teleport to an entity, and keeping the original rotation.

Linked issues

Comments 1

Thank you for your report!
We're tracking this issue in MC-276315, so this ticket is being resolved and linked as a duplicate.

If you would like to add a vote and any extra information to the main ticket it would be appreciated.

If you haven't already, you might like to make use of the search feature to see if the issue has already been mentioned.

Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki
-- I am a bot. This action was performed automatically! The ticket was resolved by one of our moderators, and I left this message to give more information to you.

SystemUpdate

(Unassigned)

Unconfirmed

(Unassigned)

24w36a

Retrieved