1

I saw this question asking for the same thing and tried it on PE, but it didn't work. I put execute @a[x=11, y=4, z=0, r=1] ~ ~ ~ tp @p 11 4 -2 in a repeating command block, but it ignored the x=11, y=4, z=0 and r=1 and constantly kept teleporting me even though I was not on x=11, y=4, z=0. If it is possible, how would you teleport players that are on specific coordinates?

I am on single player and on version 1.1.5.

1 Answer 1

2

The x, y and z arguments in the target selector only move the origin of where to search for players, you still need a radius (r) or range (dx, dy, dz).

Also you don't need execute in this example, you can just put the target selector in the `tp' command.

So your command could for example look like this:

tp @a[x=11,y=4,z=0,r=1] 11 4 -2

A tip for dealing with repeating command blocks with teleport commands in them: In case anything goes wrong and you're stuck in a teleporting loop, write down the coordinates of the repeating command block beforehand and if it's out of control, execute the command /blockdata <coordinates> {auto:0} to stop it.

1
  • 1
    I forgot to add I did use r=1 in my command. /blockdata is not available in PE, but I could use /setblock X Y Z air to get rid of the command block. Commented Aug 27, 2017 at 11:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .