A compass is an item used to point to the world spawn or to a lodestone.
Obtaining[]
Crafting[]
Ingredients | Crafting recipe |
---|---|
Iron Ingot + Redstone Dust |
Chest loot[]
Item | Structure | Container | Quantity | Chance |
---|---|---|---|---|
Java Edition | ||||
Compass | Ancient City | Chest | 1 | 16.1% |
Shipwreck | Map chest | 1 | 7.7% | |
Stronghold | Library chest | 1 | 10.9% | |
Village | Cartographer's chest | 1 | 26.3% | |
Bedrock Edition | ||||
Compass | Ancient City | Chest | 1 | 16.1% |
Shipwreck | Map chest | 1 | 7.7% | |
Stronghold | Library chest | 1 | 10.5% | |
Village | Cartographer's chest | 1 | 26.3% |
Trading[]
In Java Edition, expert-level librarian villagers have a 50% chance to sell a single compass for 4 emeralds.
In Bedrock Edition, expert-level librarian villagers have a 1⁄3 chance to sell a single compass for 4 emeralds.
Usage[]
Normally, the compass' needle points toward the world spawn point. The compass points to spawn when viewed in any way, including as a dropped item, in a player's hand, in an inventory or the crafting table, or in an item frame. The direction the needle points to is relative to the player who is viewing it. When a compass in an item frame is rotated, the needle turns accordingly.
In the Nether or the End, the compass' needle spins and points in random directions.
The compass can be used on a lodestone, after which it is named lodestone compass by default and points to that lodestone as long as the compass is in the same dimension as the lodestone, but if the compass is taken to a different dimension, it spins randomly, as a normal compass would in the Nether or the End. If the lodestone is destroyed, it also spins randomly, even if the lodestone is replaced afterward. However, if a lodestone compass is placed in storage, the lodestone can be broken and replaced without the compass losing the attunement, as long as the compass remains in storage while the lodestone is missing.
A lodestone compass appears enchanted, similar to the enchanted golden apple.
Using /setworldspawn
to change the world spawn also changes where the compass points.
Crafting ingredient[]
Name | Ingredients | Crafting recipe | Description |
---|---|---|---|
Empty Map | Paper + Compass |
This variation is called an "empty locator map" in Bedrock Edition, or an "empty map" in Java Edition.
When the player first creates a map, it is blank. It needs to be activated by holding it and pressing use item. after which it records terrain and location markers as the player travels within (or close to) the area it maps. | |
Map (with marker) |
Map or Empty Map + Compass |
Bedrock Edition only.
Maps crafted from only paper do not show the location marker; to add it, a compass must be added to the map. | |
Recovery Compass | Echo Shard + Compass |
Anvil usage[]
Name | Ingredients | Anvil usage | Description |
---|---|---|---|
Locator Map | Map + Compass |
Bedrock Edition only.
Maps crafted with only paper do not show the location marker; to add it, a compass must be added to the map. |
Trading[]
A single compass can be sold to a journeyman-level cartographer villager for 1 emerald.[Java Edition only]
A single compass can be sold to an expert-level cartographer villager for 1 emerald as their sixth trade.[Bedrock Edition only]
A compass is also part of the cost of explorer maps:
- An ocean explorer map and[JE only]/or[BE only] a woodland explorer map can be bought from a journeyman-level cartographer for 12 emeralds and one compass, as part of their fifth trade.[Bedrock Edition only]
- In Java Edition, apprentice-level cartographer villagers offer to sell an ocean explorer map for 13 emeralds and a compass, and journeyman-level cartographer villagers offer to sell a woodland explorer map for 14 emeralds and one compass.
Enchantments[]
A compass can receive the following enchantments:
Name | Max Level | Method |
---|---|---|
Curse of Vanishing | I |
Sounds[]
Sound | Subtitles | Source | Description | Resource location | Translation key | Volume | Pitch | Attenuation distance |
---|---|---|---|---|---|---|---|---|
Lodestone Compass locks onto Lodestone | Players | When a compass is used on a lodestone | item | subtitles | 1.0 | varies [sound 1] | 16 |
- ↑ Can be 0.85 or 0.95 for each sound
Sound | Source | Description | Resource location | Volume | Pitch |
---|---|---|---|---|---|
Blocks | When a compass is used on a lodestone | lodestone_compass | 1.0 | 0.85-0.95 |
Data values[]
ID[]
Name | Identifier | Form | Translation key |
---|---|---|---|
Compass | compass | Item | item.minecraft.compass item.minecraft.lodestone_compass |
Name | Identifier | Alias ID | Numeric ID | Form | Translation key |
---|---|---|---|---|---|
Compass | compass | None | 391 | Item | item.compass.name |
Lodestone Compass | lodestone_compass | lodestonecompass | 602 | Item | item.lodestonecompass.name |
Item data[]
- tag: The item's tag tag.
- LodestoneTracked: Optional. 1 or 0 (true/false) - true if the compass is connected to a lodestone. When false, LodestoneDimension and LodestonePos is not automatically removed when the lodestone is destroyed, but the compass still points to that location.
- LodestoneDimension: Optional. The dimension of the lodestone to which the compass is pointing.
- LodestonePos: Optional. The coordinates of the lodestone to which the compass is pointing.
- X: x coordinate
- Y: y coordinate
- Z: z coordinate
Advancements[]
Icon | Advancement | In-game description | Parent | Actual requirements (if different) | Resource location |
---|---|---|---|---|---|
Country Lode, Take Me Home | Use a Compass on a Lodestone | Hidden in the Depths | — | nether/use_lodestone
|
History[]
Java Edition Alpha | |||||
---|---|---|---|---|---|
v1.1.0 | Added compasses. | ||||
They have 102 visually distinct frames due to how the texture is generated - see the section below. | |||||
Java Edition Beta | |||||
1.8 | Pre-release | Compasses can now be found in library chests in the new strongholds. | |||
Java Edition | |||||
1.3.1 | 12w21a | Librarian villagers now sell 1 compass for 10–11 emeralds, making them renewable. | |||
1.4.2 | 12w34a | Since the mapping system has been changed, a compass can now be used to craft an empty map. | |||
1.5 | 13w02a | Compasses now, instead of splitting two textures, use the new animation feature included in texture packs. As a result, they are considerably less precise, having only 29 visually distinct frames. | |||
1.8 | 14w02a | Librarian villagers now sell 1 compass for 10–12 emeralds. | |||
1.9 | 15w31a | Compasses are now broken up into individual textures, instead of having every individual frame on one vertical strip like with animated textures. | |||
15w43a | The average yield of compasses in stronghold library chests has been increased. | ||||
1.11 | 16w39a | Cartographer villagers have been added, who buy compasses as their tier 2 trade. | |||
1.13 | 17w47a | Prior to The Flattening, this item's numeral ID was 345. | |||
18w11a | Compasses can now generate in shipwreck chests. | ||||
1.14 | 18w48a | Compasses can now generate in chests in village cartographer houses. | |||
1.16 | 20w13a | Compasses can now be used on lodestones to make them point to the stones. | |||
Compasses now point to the center of the spawn point block, instead of its north-west corner. | |||||
20w14a | Compasses now have the LodestonePos , LodestoneDimension , and LodestoneTracked data fields. If LodestoneTracked is zero, the game skips checking for a lodestone in the specified position.
| ||||
Compasses can now have the Curse of Vanishing enchantment on them. | |||||
20w19a | Compasses no longer work in the recipe book.[1] | ||||
20w22a | Compasses no longer work in the villager trading GUI.[2] | ||||
1.17 | 20w48a | The textures of compass and lodestone compass have been changed. | |||
1.19 | 22w13a | Compasses may now be found in ancient city chests. | |||
22w14a | Compasses can now used to craft recovery compasses. | ||||
Pocket Edition Alpha | |||||
v0.2.0 | Added compasses. | ||||
Compasses currently have no function or legitimate method of obtaining them. | |||||
v0.8.0 | build 1 | Added animated texture to compasses. | |||
Compasses are now functional and craftable. They have been added into the Creative Inventory. | |||||
v0.14.0 | build 1 | Compasses must now be added to a map using an anvil to add the location marker. | |||
Pocket Edition | |||||
1.0.0 | ? | Windows 10 Edition can now use the anvil, as well as the crafting table, to apply position markers, with compasses just as Pocket Edition can in general. | |||
1.0.4 | alpha 1.0.4.0 | Librarian villagers now sell 1 compass for 10–12 emeralds. | |||
1.1.0 | alpha 1.1.0.3 | Cartographer villagers have been added, who buy compasses as part of their tier 2 trade. | |||
Compasses used with emeralds can be used to buy explorer maps as part of cartographer villagers' fourth tiers trade. | |||||
Bedrock Edition | |||||
1.4.0 | beta 1.2.14.2 | Compasses can now be found inside map room chests in shipwrecks. | |||
1.10.0 | beta 1.10.0.3 | Compasses can now be found in village cartographer house chests. | |||
1.11.0 | beta 1.11.0.4 | Trading has been changed, cartographer villagers now buy compassess as part of their fourth tier trades. | |||
Compasses used with emeralds can now be used to buy explorer maps as part of cartographer and fletcher villagers' third tier trades. | |||||
Librarian villagers now have a 1⁄3 chance to sell compasses for 4 emeralds as part of their fourth tier trades. | |||||
1.16.0 | beta 1.16.0.57 | Compasses can now be used on lodestones to make them point to the stones. | |||
Compasses now have the LodestonePos , LodestoneDimension , and LodestoneTracked data fields. If LodestoneTracked is zero, the game skips checking for a lodestone in the specified position. | |||||
Compasses can now have the Curse of Vanishing enchantment on them. | |||||
1.16.100 | beta 1.16.100.56 | Changed the ID lodestonecompass to lodestone_compass . | |||
1.17.0 | beta 1.17.0.54 | The texture of compass has been changed. | |||
1.18.10 | beta 1.18.10.20 | The texture of lodestone compass has been changed. | |||
Legacy Console Edition | |||||
TU1 | CU1 | 1.0 | Patch 1 | 1.0.1 | Added compasses. |
New Nintendo 3DS Edition | |||||
0.1.0 | Added compasses. |
Texture generation prior to Java Edition 13w02a[]
Compasses simply draw two lines over the item sprite to form the needle.
Much like clocks, the code responsible for moving the needle is also present with the "setup" code, however it is omitted here as it is not pertinent to the actual drawing of the sprite. Also like clocks, an oversight in how the compass sprite is set to be loaded prevents texture packs from overriding the compass's base sprite.
def setup_compass_sprite (item: Image, angle: float, output: Image):
NX = 8.5
NY = 7.5
SCALE_X = 0.3
SCALE_Y = SCALE_X * 0.5
# copy the item's texture into the output
for i, pix in enumerate(item):
output.set_pixeli(i, pix)
rx = sin(angle)
ry = cos(angle)
# draw the smaller horizontal spurs of the needle
# 1 is added to the endpoint, as `range` here is
# end-exclusive. The original loops did `i <= 4`
for i in range(-4, 4 + 1):
x = int(NX + ry * i * SCALE_X)
y = int(NY - rx * i * SCALE_Y)
output.set_pixel(x, y, '#646464')
# draw the main part needle
for i in range(-8, 16 + 1):
x = int(NX + rx * i * SCALE_X)
y = int(NY + ry * i * SCALE_Y)
if i >= 0:
# Main red pointer
output.set_pixel(x, y, '#FF1414')
else:
# Grey back half
output.set_pixel(x, y, '#646464')
The generated compass sprite has 102 possible unique frames, while the pre-rendered compass has significantly less, at only 32 frames.
Issues[]
Issues relating to "Compass" are maintained on the bug tracker. Report issues there.
Gallery[]
Purchasing a compass from a librarian villager.
See also[]
External Links[]
- Taking Inventory: Compass – Minecraft.net on August 15, 2019