> 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/gameplay-effect-ge/modifier.md).

# Modifier

A modifier describes how to alter the value of an Attribute when its GameplayEffect is applied.&#x20;

Modifiers can execute three distinct operations:

```csharp
Add, Multiply, Override.
```

All the addition modifiers are applied to the base value before any multiplication.

```csharp
resultValue = (baseValue + modification.add) * (modification.multiply + 1);
```

## Modifiers come in a few flavors:

### BasicModifier

The simplest modifier. A constant value that is not altered.

<figure><img src="https://585731495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FPvnvgshL169KwwsLUx0q%2Fuploads%2F9njvf08dwhBvoaLQI57R%2Fimage.png?alt=media&amp;token=852f7878-80fd-4a62-88ab-c5a4ff461eb3" alt="" width="403"><figcaption></figcaption></figure>

### ScalableModifier&#x20;

A modifier that scaled its value based on a AnimationCurve. The X axis, or how much to scale, is defined by the level of the GameplayEffect applying it. So a curve with point {1,1} and {10,20} will gradually scale the modifier between 1 and 20 depending on the value of ge.level.<br>

<figure><img src="https://585731495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FPvnvgshL169KwwsLUx0q%2Fuploads%2F3g8ZFxiPoB4hpbbsYY1Q%2Fimage.png?alt=media&amp;token=dff08f2c-91a5-4c2f-81a7-1fd407b04c9d" alt="" width="404"><figcaption></figcaption></figure>

### ScalableModifierCSV

A modifier that uses a simple .csv file to scale its value. Useful if you want designer to set exactly what value it'll output at what ge.level.

<figure><img src="https://585731495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FPvnvgshL169KwwsLUx0q%2Fuploads%2FYLXaEtlOn1y1gDpfoe1X%2Fimage.png?alt=media&amp;token=aecd0fc5-75b3-4166-b302-a216c89a8125" alt="" width="404"><figcaption></figcaption></figure>

### AttributeBasedModifier

A modifier that uses an attribute from the ASC as its value (e.g. value 2 with baseAttribute Health, would mean 200% of currenct ASC's health). It also has an optional ge.level scaling AnimationCurve.

<figure><img src="https://585731495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FPvnvgshL169KwwsLUx0q%2Fuploads%2FBs33jB6Q6O7fizPCtydW%2Fimage.png?alt=media&amp;token=bce8c134-2324-48fc-b791-81c070ad3758" alt="" width="404"><figcaption></figcaption></figure>

## ***ATTENTION:***&#x20;

To add the modifier via Editor, scroll down the GE scriptable object and click the "**ADD MODIFIER WITH TYPE"** button. *(Modifiers need to be instantiated with their type, otherwise they'll inherit the base class that does nothing (It always return 0))*

<figure><img src="https://585731495-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FPvnvgshL169KwwsLUx0q%2Fuploads%2FS1b0LGpRwDg7e4P2EXZb%2Fimage.png?alt=media&amp;token=0d60da71-a4a3-492a-8a7b-7b1bc04f672b" alt="" width="274"><figcaption></figcaption></figure>

<br>

{% embed url="<https://www.youtube.com/watch?v=IXT7QvNHd6M>" %}
