Custom mechanic
This mechanism allows you to realize an extremely customizable mechanism without programming
Last updated
Was this helpful?
This mechanism allows you to realize an extremely customizable mechanism without programming
Last updated
Was this helpful?
This mechanic is for items only and does not work with blocks/furniture. For that check the . The mechanics let you create subsections composed of 3 parts:
Event: when is this mechanic triggered? e.g. when you right-click on a block
Conditions: a set of conditions that must be satisfied. e.g. having a permission
Actions: a set of actions to perform. e.g. send a command or a message
In this example, the subsection test
defines a custom mechanic triggered when someone right click (on a block or in the air).
If this player has the permission example.permission
, the console will perform the give command and replace <player> by the player name.
The item won't be consumed (oneUsage: false).
Called when you click with the item.
mouse_click_type: [ right, left, all ]
target_type: [ block, air, all ]
Called when you drop the item.
Called when you pick up the item.
Called when a player breaks an item.
Called when a player equips an item.
Called when a player unequips an item.
Called when a player clicks an item in an inventory.
Called when a player dies and would normally drop the given item.
the.permission: The permission required by the player using the item
sender: [ console, player ]
command: The command to perform. The placeholder <player> can be used.
content: Content of the message to send (it supports minimessage format)
content: Content of the message to send (it supports minimessage format)