Commands/locate

Displays the coordinates for the closest configured structure feature and biomes of a given type in the chat for the player who executed the command.

$$, it can also display points of interest.

Syntax

 * Java Edition


 * Bedrock Edition

Arguments
(case-sensitive): 


 * biome: Biome

Specifies the biome to locate. In Java Edition, this argument also supports biome tags.

(case-sensitive): 


 * structure: Structure

Specifies the configured structure to locate. Must be one of the following:
 * {| class="wikitable sortable"

!Structure name||Java Edition||Bedrock Edition||Dimension
 * ||Overworld
 * ||The Nether
 * ||Overworld
 * ||The End
 * The Nether
 * Overworld
 * ||||Overworld
 * Overworld
 * —||The Nether
 * ||||Overworld
 * ||Overworld
 * || ||Overworld, The Nether
 * ||||Overworld
 * Overworld
 * rowspan="4" ||| rowspan="4" |Overworld
 * ||||Overworld
 * }
 * —||The Nether
 * ||||Overworld
 * ||Overworld
 * || ||Overworld, The Nether
 * ||||Overworld
 * Overworld
 * rowspan="4" ||| rowspan="4" |Overworld
 * ||||Overworld
 * }
 * Overworld
 * rowspan="4" ||| rowspan="4" |Overworld
 * ||||Overworld
 * }
 * ||||Overworld
 * }
 * ||||Overworld
 * }
 * ||||Overworld
 * }
 * ||||Overworld
 * }
 * }


 * $$, this argument also supports configured structure tags, as following:
 * {| class="wikitable sortable"

!Tag !Structure(s)
 * }
 * }
 * }
 * }
 * }
 * }
 * }
 * }
 * }
 * }
 * }
 * }
 * }
 * }


 * useNewChunksOnly: Boolean

Specifies if a structure of any type wants to be located in new chunks only or not, and it's   by default.

(case-sensitive): 

Specifies the point of interest to locate. Must be one of the following:
 * {| class="wikitable sortable"

!Point of Interest||ID
 * Blast Furnace
 * Bee nest
 * Beehive
 * Smoker
 * Cartography Table
 * Brewing Stand
 * Composter
 * Barrel
 * Fletching Table
 * Bed
 * Cauldron
 * Lectern
 * Lightning Rod
 * Lodestone
 * Stonecutter
 * Bell
 * Nether Portal
 * Loom
 * Smithing Table
 * Grindstone
 * }
 * Barrel
 * Fletching Table
 * Bed
 * Cauldron
 * Lectern
 * Lightning Rod
 * Lodestone
 * Stonecutter
 * Bell
 * Nether Portal
 * Loom
 * Smithing Table
 * Grindstone
 * }
 * Lightning Rod
 * Lodestone
 * Stonecutter
 * Bell
 * Nether Portal
 * Loom
 * Smithing Table
 * Grindstone
 * }
 * Bell
 * Nether Portal
 * Loom
 * Smithing Table
 * Grindstone
 * }
 * Loom
 * Smithing Table
 * Grindstone
 * }
 * Smithing Table
 * Grindstone
 * }
 * Grindstone
 * }
 * }
 * }


 * This argument also supports point of interest type tags, as following:
 * {| class="wikitable sortable"

!Tag !Point of Interests






 * }

Note
The vertical coordinate of the structure is ignored when finding.

$$, structures in the Anvil chunk region of the command's execution are prioritized over others due to a bug, meaning the found structure is not necessarily the closest.

If successful, the following message is sent to chat: "The nearest  is at [ ~ ] ( blocks away) ", in which  is the horizontal distance between the executor and the structure feature. $$, the coordinates can be clicked, which can put the command in the chat box. The command can then be executed, and the player is sent to those coordinates.

Examples

 * To obtain the coordinates of the nearest woodland mansion:
 * To obtain the coordinates of the nearest pillager outpost in new chunks only:
 * To obtain the coordinates of the nearest village of any kind: /
 * To obtain the coordinates of the nearest desert biome:
 * To obtain the coordinates of the nearest point of interest used by villagers: