# Build Mobs With Blocks

## How do block patterns work?

Building mobs with block patterns mimics the vanilla feature where Withers, Iron golems or snowmans can be built. Players must make a specific pattern for a mob to spawn - the block pattern disappears. Best explained by this gif:

<figure><img src="https://2125321039-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuAb528wVCZfJT8n3LXzI%2Fuploads%2FbVclnKl56ZwiqNfVmJuv%2Fbosses.gif?alt=media&#x26;token=8970d8e3-28c4-4bb3-b010-d0309138ba32" alt=""><figcaption></figcaption></figure>

## How to customize / make your own patterns?

You will need to do this all inside `plugins/AdvancedMobs/bosses` folder. If you are customizing an already available pattern, find the file named same as the mob you want to change, otherwise, create a new file called `<mob name>.yml`, example: `Wyvern.yml`

We're going to be customizing a default pattern of Wyvern mob. The inside of file looks like this:

{% code title="plugins/AdvancedMobs/bosses/Wyvern.yml" overflow="wrap" lineNumbers="true" %}

```yaml
# Boss Configuration file for Wyvern

# How to build Wyvern boss
build:
  pattern:
    - ' e '
    - 'idi'
    - ' d '
  materials:
    e: ENCHANTING_TABLE
    i: IRON_BLOCK
    d: REINFORCED_DEEPSLATE
```

{% endcode %}

Patterns are very simple to understand. Use empty space    to act as an AIR block, otherwise specify material names below the pattern list. As an example, in our file, `e` means ENCHANTING\_TABLE.&#x20;

Here is a visual representation of how this pattern looks:

<figure><img src="https://2125321039-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuAb528wVCZfJT8n3LXzI%2Fuploads%2FE5gBn5BI4obVeGUDGD5W%2Fbuild%20pattern.png?alt=media&#x26;token=80f590e0-4c3a-4335-9683-98927f8876aa" alt=""><figcaption></figcaption></figure>

Because there's 3 lines, and 3 materials in each line, this is a 3x3 pattern. A very basic 2D pattern. You can have as many lines in height or width as you want.
