You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/custom-backpack/setting-the-unlock-challenge/challenge-types.mdx
+58-11Lines changed: 58 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -444,11 +444,11 @@ Backpacked comes with many built-in challenge types
444
444
445
445
**Description:** A challenge that requires the player to trade with a merchant type entity. Supports Villagers, Wandering Traders, and even modded NPCs like Goblin Traders.
|`block`| Object | No | — | An optional block snapshot predicate to test to against the block that was just mined. See Block Snapshot Predicate for more details. |
450
-
|`item`| Object | No | — | An optional item predicate to test the item that was used by the player to mine the block. See [Minecraft Wiki](https://minecraft.wiki/w/Advancement/Conditions/item) for more details. |
451
-
|`player`| Object | No | — | An optional entity predicate for the player. See [Minecraft Wiki](https://minecraft.wiki/w/Advancement/Conditions/entity) for more details. |
|`block`| Object | No | — | An optional block snapshot predicate to test to against the block that was just mined. See Block Snapshot Predicate for more details. |
450
+
|`item`| Object | No | — | An optional item predicate to test the item that was used by the player to mine the block. See [Minecraft Wiki](https://minecraft.wiki/w/Advancement/Conditions/item) for more details. |
451
+
|`player`| Object | No | — | An optional entity predicate for the player. See [Minecraft Wiki](https://minecraft.wiki/w/Advancement/Conditions/entity) for more details. |
452
452
|`count`| Number | No | 1 | The amount of times the `player` has to mine the `block`|
453
453
454
454
#### Examples
@@ -459,13 +459,60 @@ TODO
459
459
460
460
**ID:**`backpacked:travel_distance`
461
461
462
-
**Description:** A challenge that requires the player to trade with a merchant type entity. Supports Villagers, Wandering Traders, and even modded NPCs like Goblin Traders.
462
+
**Description:** A challenge that requires the player to travel a specific
|`movement`| String | No | — | The type of movement. If left undefined, any type of movement will count towards the `total distance`. Available list of movements are: `walk`, `sprint`, `sneak`, `swim`, `walk_underwater`, `walk_on_water`, `climb`, `elytra_flying`, `fly`, and `fall`. |
467
+
|`total_distance`| Number | Yes | — | The total distance (in centimetres) the player must move while in the correct `movement` type. The number must be positive. |
468
+
|`player`| Object | No | — | An optional entity predicate for the player. See [Minecraft Wiki](https://minecraft.wiki/w/Advancement/Conditions/entity) for more details. **Important:** Keep it simple since this check is run often. |
|`movement`| String | No | — | The type of movement. See list below of valid movement types. If left undefined, any type of movement will count towards the `total distance`. |
467
-
|`total_distance`| Number | Yes | — | The total distance the player must move while in the correct `movement` type. The number must be positive. |
470
+
:::note
471
+
The `total_distance` is calculated in centimetres. To travel one block is the equivalent of 100 centimetres.
472
+
:::
468
473
469
474
#### Examples
470
475
471
-
TODO
476
+
<divclass="code-block">
477
+
**Sprint a total of 100km (62.1 miles) to unlock this backpack**
0 commit comments