> For the complete documentation index, see [llms.txt](https://roogame.gitbook.io/roogame/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://roogame.gitbook.io/roogame/roo-gameplay-framework/stats-system/modifiers-and-stat-actions.md).

# Modifiers and Stat Actions

Modifiers change a Stat's calculated value without replacing its configuration asset.

## Create a Stat Action

In the Content Browser, right-click inside the destination folder and select `RooGame > Stat > Action > Stat Action`.

## Modifier types

Constant adds a fixed amount.

```
Final = Value + ConstantModifiers
```

Percent values are ratios and are applied after constant modifiers.

```
Final = ValueAfterConstants * (1 + TotalPercent)
```

For example, 0.25 means plus 25 percent and -0.10 means minus 10 percent.

Add Modifier returns a Roo Stat Modifier Handle. Store the handle when you need to remove that exact modifier.

SourceId groups modifiers by their source. Equipment uses source IDs so all modifiers from one equipped instance can be removed together.

## Stat Actions

A Stat Action Data Asset is a reusable operation executed through Apply Stat Action.

Action types:

* Change Base
* Change Value
* Set Value
* Add Status Effect
* Remove Status Effect

Value types:

* Constant Number
* Constant Formula
* Percent Number
* Percent Formula

Change Base targets the stored Stat base. Change Value works from the calculated Stat value or current Attribute value. Set Value replaces the target runtime value.

Percent action values multiply the relevant reference value. A Number of 0.10 means 10 percent.

Add Status Effect interprets the resolved Value as a stack amount, floors it to an integer, and clamps one action to a maximum of 1000 stacks. Remove Status Effect uses the same stack-amount rule.

## Status Effect actions

A Status Effect contains Add Actions, Tick Actions, and Remove Actions. These embedded actions support:

* Change Base
* Change Value
* Set Value
* Add Modifier
* Remove Modifier

Use Add Modifier and Remove Modifier for reversible Buff bonuses. Use Change Value for healing, damage, or resource changes.
