EssentialsX

EssentialsX

2M Downloads

[Enhancement] Add [Player] variable to tppos

Opened this issue · 6 comments

commented

Feature request

Add [Player] variable to tppos

Feature description
Add [Player] variable to tppos, preferably in the front.

/tppos [player] [yaw] [pitch] [world]

This is a similar request to #2470

How the feature is useful
Currently, there is only one way to teleport another player to an exact location in a specific world. You must go to an exact location in a specific world, create a warp in that world, and then issue "/warp [WarpName] [player]".

The tp command can only teleport a player to coordinates in the same world as the target player. Tphere requires the destination player to already be at the location in the specific world.

Why would you want to use this command?

  • Can be used in the console to move a player.
  • Can be used in a command block with the use of other plugins (like PsudoCommands).
  • Can be used in an EssentialsX Kit with the {player} token.
commented

Did you see Leomelonseeds's comment? What does this accomplish that the tp command cannot already do?

commented

Can you check if that is actually the case? If so, I'll open this back up.

commented

I looked into this a bit further, and it looks like the vanilla tp command on its own indeed does not allow going between worlds, however you can easily use the execute command to run the tp command for a player in the context of a given world. I believe this solves your issue.

commented

As I understand, the “Execute In” command will only work for native Minecraft dimensions of the server.properties works, not for other worlds (overworlds) which a bukkit/spigot/paper server can load with a world manager.

commented

I've done a little testing in 1.15. "Execute in" seems like it can work for worlds that are not in the native server.properties world set. In order to teleport to the world, world_nether, or world_the_end, the native minecraft dimension parameter must be used.

commented

Only reason I want this option to be added is because I want the player to face a certain direction after being teleported, which doesnt exist for vanilla tp.