0

So im trying to make a teleportation area that will teleport players to certain points in my world. I have multiple command blocks next to each other because there are multiple selections as to where you can teleport. I set a command here:

/tp @a[x=41, y=4, z=31] 26 12 10

I put specified coordinates in there because I only want players in a certain point to be teleported. I have 4 of these commands with different coordinates for different places. This is where trouble started. I was done putting in all the commands, and tried it out. The command it tested was set as the following:

/tp @a[x=41, y=12, z=31] 26 12 10

That worked. I tried another one, but, it teleported me to a location that was set in a different command block?? I even double checked to see if had mixed up any numbers, but, nope.

Just for clarification, there were 4 command blocks. I pressed the first on and it sent me to the location set in the second command, vise versa. What is happening? This also happened on another world I had, I dont really know how to fix this. Is there blocks you cant teleport through? Can command blocks not be side by side??

7
  • Please see this post, which you could have found by searching our site before posting. – ExpertCoder14 Dec 8 '20 at 1:58
  • "it teleported me to 26.50 12.00 10.50" this is bad? That's exactly what you put in to do. What do you want it to do, as it worked how it's supposed to. – Penguin Dec 8 '20 at 2:56
  • @ExpertCoder14 it seems that they're just asking how the teleport command works, doesn't it? – Penguin Dec 8 '20 at 2:57
  • @Penguin My analysis of this post is that the tp commands are triggering when OP does not want them to. They typed in coordinates into the target selector, expecting players within those coordinates will get teleported, but instead, it teleports regardless of whether player is in the location they set. The OP needs to know that they need to provide a radius with arguments r and rm, or a prismic box with arguments dx, dy, and dz. The post I linked will help them with that. – ExpertCoder14 Dec 8 '20 at 3:32
  • Thanks a lot for the help! I'm going to try it again now. I got rid of the 26.50 12.00 10.50 part. I was just trying to figure out every detail – aqualeon_ Dec 9 '20 at 2:36
0

Uh. Without knowing what command you put in each command block, it is hard to say what is going on. If you put the command blocks together or too close, they could be activating one another if the redstone signal is detected.

I can suggest a different command:

teleport @p[r=2] -100.5 64 -100.5 180 0

If you put this into a command block, and press a button to activate it, any player within 2 blocks of the command block will be teleported to the xyz coordinates, facing 180 0.

If you want the player to step onto the block, you could put a pressure plate on top of it instead of a button.

You could set it to always run, then any player that enters the range will be teleported.

1
  • This won't work for Bedrock. It was a quick fix so I went ahead and did it myself, but if you have good reason to want to change it back you can. – Penguin Feb 13 at 7:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.