> For the complete documentation index, see [llms.txt](https://wiki.hmmbo.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://wiki.hmmbo.com/fundamentals/gui-help/edit-menu/customize-block-commands.md).

# Customize Block Commands

1. Run the command `/regen menu`.
2. Select "Edit Menu."
3. Select "Region / Global."
4. Select "Block Menu."
5. Select the block you want to edit.
6. Click on "Add Commands" (Command Block icon).

<figure><img src="/files/6elX2JfhLQWpuSkGEwLA" alt=""><figcaption></figcaption></figure>

* **Runner:** Specify whether the command should be run by the console or the player.
* **Command:** Specify the command to be executed.
* **Chance:** Set a chance between 0.001 to 0.999 for the command to run.

For example:

<pre><code><strong>Console ; say hi ; 0.5
</strong></code></pre>

```
Player ; spawn ; 0.1
```

## Command Chaining

#### Example of Command Chaining

To use command chaining, format the command sequence as shown below:

```plaintext
Console ; teleport %player% 100 64 200 > Player ; give %player% diamond_sword ; 0.25
```

In this example, if the teleport command is successful, there is a 25% chance that the player will receive a diamond sword.

{% hint style="warning" %}
Supported Placeholders:\
%player% : Replaces with player name \
%x% : Replaces with block's x co-ordinate\
%y% : Replaces with block's y co-ordinate\
%z% : Replaces with block's z co-ordinate\
%world% : Replaces with block's world
{% endhint %}
