Minecraft:Commands/teleport: Difference between revisions
More actions
imported>COS wikiuser Undo revision 3430990 by ~2026-RubyDogSavanna2381 (talk) when did the teleport range change? |
Remove broken links to missing pages |
||
| Line 1: | Line 1: | ||
{{about|the command in the current version (since | {{about|the command in the current version (since Java Edition 1.13 (17w45a))|the command in former game versions|Commands/tp/Before Java Edition 17w45a}} | ||
{{Infobox command | {{Infobox command | ||
|name=teleport | |name=teleport | ||
| Line 6: | Line 6: | ||
* 2 {{only|java|short=1}} | * 2 {{only|java|short=1}} | ||
* 1 {{only|bedrock|short=1}} | * 1 {{only|bedrock|short=1}} | ||
|others= | |others=Cheat only{{only|bedrock|short=1}} | ||
}} | }} | ||
Teleports | Teleports entities (players, mobs, etc.). | ||
Although most [[Minecraft:commands]] can affect only | Although most [[Minecraft:commands]] can affect only chunks that have already been generated, {{cmd|teleport}} can send entities into chunks that have yet to be generated. Right before teleporting, the game generates the destination chunk. | ||
==Syntax== | ==Syntax== | ||
| Line 160: | Line 160: | ||
{{Navbox commands}} | {{Navbox commands}} | ||
de:Befehl/teleport | |||
es:Comandos/tp | |||
ja:コマンド/teleport | |||
pt:Comandos/teleport | |||
ru:Команды консоли/teleport | |||
zh:命令/teleport | |||
Revision as of 15:45, 9 April 2026
|
For the {{{Description}}} of the same name, see [[{{{Destination}}}]]. |
Teleports entities (players, mobs, etc.).
Although most Minecraft:commands can affect only chunks that have already been generated, Template:Cmd can send entities into chunks that have yet to be generated. Right before teleporting, the game generates the destination chunk.
Syntax
- Java Edition
teleport <destination>teleport <targets> <destination>- Teleports the executor or the specified entity(s) to the position of an entity, and makes its rotation the same as the specified entity's.
teleport <location>- Teleports the executor to a certain position (and changes its rotation to the command's execution rotation).
teleport <targets> <location>- Teleports the entity(s) to a certain position (without changing their rotation).
teleport <targets> <location> <rotation>teleport <targets> <location> facing <facingLocation>teleport <targets> <location> facing entity <facingEntity> [<facingAnchor>]- Teleports the entity(s) to a certain position and changes their rotation to the specified rotation.
- Bedrock Edition
teleport <destination: target>teleport <victim: target> <destination: target> [checkForBlocks: Boolean]- Teleports the executor or the specified entity(s) to the position of an entity, and makes it face horizontally, and make its horizontal rotation the same as the specified entity's.
teleport <destination: x y z> [checkForBlocks: Boolean]teleport <victim: target> <destination: x y z> [checkForBlocks: Boolean]- Teleports the executor or the specified entity(s) to a certain position (without changing its rotation).
teleport <destination: x y z> [yRot: value] [xRot: value] [checkForBlocks: Boolean]teleport <destination: x y z> facing <lookAtPosition: x y z> [checkForBlocks: Boolean]teleport <destination: x y z> facing <lookAtEntity: target> [checkForBlocks: Boolean]teleport <victim: target> <destination: x y z> [yRot: value] [xRot: value] [checkForBlocks: Boolean]teleport <victim: target> <destination: x y z> facing <lookAtPosition: x y z> [checkForBlocks: Boolean]teleport <victim: target> <destination: x y z> facing <lookAtEntity: target> [checkForBlocks: Boolean]- Teleports the executor or the specified entity(s) to a certain position and changes their rotation to the specified rotation.
Arguments
- Specifies the entity(s) to be teleported. If not specified, defaults to the command's executor.
- Template:Arg desc
- Specifies the coordinates to teleport the target(s) to.
- Template:Arg desc
- Specifies the entity to teleport the target(s) to.
- Template:Arg desc
Template:El: Template:Argument
Template:El: Template:Argument and Template:Argument
- Specifies the rotation.
- Template:Arg desc
- Specifies the coordinates to make the target(s) facing to.
- Template:Arg desc
- Specifies the entity to make the target(s) facing to.
- Template:Arg desc
Template:El: Template:Argument
- Specifies whether the entity'eyes or feet to make the target(s) facing to. If not specified, defaults to feet. Template:IN, the anchor of the targets can be changed with Template:Cmd. Template:IN, always facing the entity's feet from the targets' feet.
- Template:Arg desc
Template:El: Template:Argument
- Template:Arg desc
- If set to
true, teleports the target(s) only if the target(s) would not collide with a block it cannot be inside (Note: this allows teleporting into flowers as well as midair). Iffalseor not specified, the default behavior applies (do no check; just teleport the target(s)).
Result
Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table
Output
Template:Output table Template:Output table Template:Output table Template:Output table Template:Output table Template:Output table Template:Output table Template:Output table Template:Output table
Examples
- To teleport the executing player to Alice:
teleport Alice
- To teleport all players to the executing player:
teleport @a @s
- To teleport the executing player to x=100 and z=100, but three blocks above their current position:
teleport 100 ~3 100 - To teleport the executing player 1 block forward
teleport ^ ^ ^1
- To rotate the nearest player 10 degrees to the right without changing their position:
execute as @p at @s run teleport @s ~ ~ ~ ~10 ~
- When used via the execute command, can teleport between the Overworld, the Nether and the End:
- To teleport the executing player to the same coordinates, but in the Nether:
execute in minecraft:the_nether run teleport ~ ~ ~Template:Onlyexecute in nether run teleport ~ ~ ~Template:Only
- To teleport all players to x=84 y=57 z=79 in the End:
execute as @a in minecraft:the_end run teleport 84 57 79Template:Onlyexecute as @a in the_end run teleport 84 57 79Template:Only
- To teleport Alex to x=251 y=64 z=-160 in the Overworld:
execute as Alex in minecraft:overworld run teleport 251 64 -160Template:Onlyexecute as Alex in overworld run teleport 251 64 -160Template:Only
- To teleport the executing player to the same coordinates, but in the Nether:
History
Java Edition
Bedrock Edition
External links
de:Befehl/teleport es:Comandos/tp ja:コマンド/teleport pt:Comandos/teleport ru:Команды консоли/teleport zh:命令/teleport