Teleporting a player from one block to another

So the problem I have here is I want to teleport a player standing at 1 34 70
to 273 33 -5
.
I have tried using a clock with testfor @a [x=1.3,y=34,z=70]
hooked up to a tp @p 273 33 -5
but when I go to 1 34 70
I don't get teleported.
Best Answer
Problem 1:
You have a space between the selector and the arguments.
Remove that space to make your selector: @a[x=1.3,y=34,z=70]
Problem 2:
The coordinates in selectors cannot be decimals. As you are looking for someone at 1, 34, 70, just use those coordinates: @a[x=1,y=34,z=70]
Problem 3:
You are testing if someone is at 1, 34, 70, and then if there is, teleporting the nearest player to the command block to 273, 33, -5. What you actually want to do is teleport the person at 1, 34, 70 to 273, 33, -5. You should put the selector arguments into the tp
command.
Problem 4:
There's no radius specified. You need to specify a radius from that point to test for. I'd recommend either a radius of 0 if you want to test just that block.
Fixing this should give you a working command:
tp @a[x=1,y=34,z=70,r=0] 273 33 -5
You could also compact this down into:
tp @a[1,34,70,0] 273 33 -5
Here is the wiki page on commands, which may be useful to read up on:
Pictures about "Teleporting a player from one block to another"



How do you teleport to a player with a block?
Type this command in when having the command block GUI open /teleport @p <x> <y> <z> . Then, activate the command block with redstone (including buttons, levers, and pressure plates), and they will be sent to their destination. The player can set up multiple different teleports.What is the command to teleport a player in Minecraft?
You can teleport to a set of coordinates or teleport another player using the /tp command in Minecraft (see also /teleport command).How do you randomly teleport a player?
Try the /spreadplayers command, which spreads entities in a random area. The syntax is /spreadplayers <x> <z> <spreadDistance> <maxRange> <respectTeams> <player \u2026> In your case, you might want to try something like /spreadplayers ~ ~ 0 10000 false @a[r=5,c=1] .How to Teleport Players to a Different Roblox Game - Roblox Studio Tutorial
Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.
Images: Kaique Rocha, Andrea Piacquadio, Monstera, Oliver Sjöström