> For the complete documentation index, see [llms.txt](https://feliperoddd.gitbook.io/gasify/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://feliperoddd.gitbook.io/gasify/ability-system-component-asc/attribute-processors.md).

# Attribute Processors

**Attribute Processors** are called everytime an **attribute** is about to change. \
They add a layer of logic to constraint the values attributes can have.\
These are usually Clampers.&#x20;

<figure><img src="https://585731495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FPvnvgshL169KwwsLUx0q%2Fuploads%2FZ0lYaTpUUiZBUfLFViN2%2Fimage.png?alt=media&amp;token=d060e3e6-01bc-46a7-93ec-2c40246cbe6c" alt="" width="323"><figcaption></figcaption></figure>

### Usage:

#### Right click in Editor -> Create -> GAS -> DataGroup - AttributeProcessor

Create a GroupAttributeProcessor, add the processors you want using the button, and drag the group into a **GroupASC**.

***ATTENTION:*** \
To add the processor, scroll down and click the "**ADD ATTRIBUTE PROCESSOR"** button. Processors need to be instantiated with their specific type, otherwise they'll do nothing.

<figure><img src="https://585731495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FPvnvgshL169KwwsLUx0q%2Fuploads%2F0R7Lo7eIqiLZMn68PgBe%2Fimage.png?alt=media&amp;token=47a62f3a-1e6c-4210-bb84-2c8fa3030ff8" alt="" width="332"><figcaption></figcaption></figure>

#### Clamper

Clamps the attribute between two constants: minValue maxValue

#### ClamperMaxAttributeValue

Clamps the attribute maximum value using the value of the attribute at MaxAttribute field.

#### ClamperMinAttributeValue

Clamps the attribute minimum value using the value of the attribute at MinAttribute field.

It is not recommended to create game mechanics using attribute processors. \
(e.g. Reacting to changes in an attribute using a processor)\
This goes against the philosophy of the framework.\
If you need to snap an attribute to a certain value, use a Override Modifier instead.\
If you need to react to an attribute change, use AbilitySystemComponent.OnAttributeChanged().
