# Highlight State

Highlight states are pretty similar to blockstates and are formatted in a similar manner for the json.

For highlight states we have a single object of <mark style="color:red;">`variants`</mark> which has key pair values with the key being the state of the block just like how you would format a blockstate and then the value either being a reference string to the highlight or an object formatted like such.

{% hint style="danger" %}
**Note:** Highlight states MUST be located in the same namespace as the namespace of the block it is being created for.

So for example for <mark style="color:red;">`minecraft:lectern`</mark> it must be located in <mark style="color:blue;">`assets/minecraft/resourcefullib/highlights/lectern.json`</mark> It can reference other namespace objects but must be in the same namespace as the namespace of the id.
{% endhint %}

{% tabs %}
{% tab title="Example" %}
This example uses the corner\_line highlight we created in the highlight section and creates 4 variants 2 where its a direct reference and 2 where it is a sub reference where on west and east it rotates the highlight by 90°.

{% code title="lectern.json" lineNumbers="true" %}

```json
{
    "variants": {
        "facing=south": "minecraft:corner_line",
        "facing=north": "minecraft:corner_line",
        "facing=west": {
            "highlight": "minecraft:corner_line",
            "rotation": { "y": 90 }
        },
        "facing=east": {
            "highlight": "minecraft:corner_line",
            "rotation": { "y": 90 }
        }
    }
}
```

{% endcode %}
{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://lib.wiki.teamresourceful.com/welcome/highlights/highlight-state.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
