Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Minecraft:Commands/locate: Difference between revisions

From SAS Gaming Wiki
SyncBot (talk | contribs)
Sync: updated from Minecraft
SyncBot (talk | contribs)
Sync: updated from Minecraft
 
(2 intermediate revisions by the same user not shown)
Line 7: Line 7:
}}
}}


Displays the [[Minecraft:coordinates]] for the closest [[Minecraft:generated structure]] or [[Minecraft:biome]]s of a given type in the chat for the player who executed the [[Minecraft:command]]. {{IN|java}}, it can also display for the closest [[Minecraft:Village mechanics|points of interest]].
Displays the [[Minecraft:coordinates]] for the closest [[Minecraft:generated structure]] or [[Minecraft:biome]]s of a given type in the chat for the player who executed the [[Minecraft:command]]. {{IN|java}}, it can also display for the closest [[Minecraft:Village mechanics|points of interest]].{{upcoming|BE}}


==Usage==
==Usage==
Line 193: Line 193:
|The parameter is now a configured structure rather than a structure type.}}
|The parameter is now a configured structure rather than a structure type.}}
|{{HistoryLine||1.19|dev=22w19a|{{cmd|locatebiome}} has been merged with {{cmd|locate|link=none}}.|Added the ability to locate points of interest.}}
|{{HistoryLine||1.19|dev=22w19a|{{cmd|locatebiome}} has been merged with {{cmd|locate|link=none}}.|Added the ability to locate points of interest.}}
|{{HistoryLine|java upcoming}}
|{{HistoryLine||26.3|dev=snap10|Improved the performance when trying to locate [[Minecraft:structure]]s.}}
}}
}}


Line 208: Line 210:
|{{HistoryLine|||dev=Preview 1.19.30.21|Added new structure names with underscores like {{cd|d=and|ancient_city|bastion_remnant|buried_treasure|end_city|pillager_outpost|ruined_portal}}.}}
|{{HistoryLine|||dev=Preview 1.19.30.21|Added new structure names with underscores like {{cd|d=and|ancient_city|bastion_remnant|buried_treasure|end_city|pillager_outpost|ruined_portal}}.}}
|{{HistoryLine||1.21.100|dev=Preview 1.21.100.20|{{cmd|locate biome|link=none}} now requires that the biome's namespace is specified (ex: <code>minecraft:plains</code> instead of just <code>plains</code>). Auto-complete suggestions for this command will now include namespaces.}}
|{{HistoryLine||1.21.100|dev=Preview 1.21.100.20|{{cmd|locate biome|link=none}} now requires that the biome's namespace is specified (ex: <code>minecraft:plains</code> instead of just <code>plains</code>). Auto-complete suggestions for this command will now include namespaces.}}
|{{HistoryLine|bedrock upcoming}}
|{{HistoryLine||26.50|exp=Points of Interest (POI)|dev=Preview 26.50.26|{{cmd|locate|link=none}} can now locate points of interest, using {{cmd|locate poi|link=none}}.}}
}}
}}



Latest revision as of 11:07, 29 August 2026

Template:Infobox command

Displays the Minecraft:coordinates for the closest Minecraft:generated structure or Minecraft:biomes of a given type in the chat for the player who executed the Minecraft:command. Template:IN, it can also display for the closest points of interest.Template:Upcoming

Usage

For Template:Cd, the vertical coordinate of structure is ignored when finding. Template:IN, the horizonal search range is 201x201 units of the Structure's spacing (see Default structure sets for values). For example, Mansions have a spacing of 80 chunks, so it can search out ±128,000 blocks before failure. For concentric ring structures like Strongholds, there is no set max distance. Structures within the same Minecraft:structure set are ordered approximately by Minecraft:taxicab distance, and structures with greater spacing have prioritized over others due to a bug, meaning the found structure is not necessarily the closest.<ref>Template:Bug</ref>

For Template:Cd, the horizonal search resolution is 32 blocks, and vertical resolution is 64 blocks, which means biomes that are too narrow may not be found. The horizonal search range is 12801×12801 blocks Template:In.Template:Info needed

Template:IN, for Template:Cd, the search range is a sphere with a radius of 256 blocks.

When locating structure or POI, if successful, the following message is sent to chat: "The nearest <requested thing(s)> is at [<x> ~ <z>] (<distance> blocks away)", in which <distance> is the horizontal distance from the executor.

When locating biome, if successful, the following message is sent to chat: "The nearest <requested biome(s)> is at [<x> <y> <z>] (<distance> blocks away)", in which <distance> is the distance from the executor to the biome.

Template:IN, the coordinates in these messages can be clicked, which can put the command Template:Cmd in the chat box. The command can then be executed, and the player is sent to those coordinates. Also, Template:In, this message does not appear if the command was run from a function.<ref>Template:Bug</ref>

Syntax

  • Java Edition
/locate structure <structure>
/locate biome <biome>
/locate poi <poi>
  • Bedrock Edition
/locate structure <structure: Structure> [useNewChunksOnly: Boolean]
/locate biome <minecraft: Biome>

Arguments

Template:El : Template:Argument
Template:El: Template:Argument

Specifies the Minecraft:biome to locate. Template:IN, this argument also supports biome Minecraft:tags.
Template:Arg desc

Template:El (case-sensitive): Template:Argument
Template:El: Template:Argument

Specifies the structure to locate. See Minecraft:Generated structures#Data values.
Template:Arg desc

Template:El: Template:Argument

Specifies if a structure of any type wants to be located in new chunks only (true) or not (false), and it's false by default.
Template:Arg desc

Template:El : Template:Argument

Specifies the point of interest to locate.
Template:Arg desc
The following are resource locations of POIs:
This argument also supports point of interest type tags, as following:

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 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

Examples

History

Java Edition

Template:HistoryTable

Bedrock Edition

Template:HistoryTable

References

Template:Reflist

External links

Navigation

Template:Navbox commands

Minecraft:de:Befehl/locate Minecraft:es:Comandos/locate Minecraft:fr:Commandes/locate Minecraft:ja:コマンド/locate Minecraft:ko:명령어/locate Minecraft:pt:Comandos/locate Minecraft:ru:Команды консоли/locate Minecraft:uk:Команди консолі/locate Minecraft:zh:命令/locate