Restriction Types
The types array in your JSON file determines what the player is prevented from doing when the conditions are met.
Available Types
| Restriction Type | Description |
|---|---|
craft | Prevents the item from being crafted in a crafting table or player inventory. |
smelt | Prevents the item from being smelted in a furnace, blast furnace, or smoker. |
brew | Prevents the potion from being brewed in a brewing stand. |
enchant | Prevents the item from being enchanted in an enchanting table. |
repair | Prevents the item from being repaired or combined in an Anvil or Grindstone. |
use_item | Prevents the "right-click" usage of an item (e.g., eating food, throwing potions, using a bow). |
break_block | Prevents the player from breaking the target block, regardless of the tool held. |
item_break_block | Prevents the player from breaking a block specifically with the item defined in the conditions. |
place_block | Prevents the block/item from being placed in the world. |
hurt_entity | Prevents the player from dealing damage to an entity using the restricted item. |
interact_entity | Prevents right-clicking on an entity (e.g., shearing a sheep, trading with a villager). |
interact_block | Prevents right-clicking a block (e.g., opening a chest, pressing a button). |
Error Messages
When a player attempts a restricted action, a translatable error message appears in the chat (red text).
- Example:
You can't craft this item yet. - Keys:
itemrestrictions.inventory.<restriction_type>
These can be customized via a resource pack modifying the language files.