Skip to main content

Alter

StatValueAdapter_Alter modifies the incoming Stat value using a configurable Modifier and Modify Type.

The adapter takes the current value of the incoming Stat and applies the selected modification method. The resulting value is returned as the adapted value.

FieldDescription
ModifierDefines the value used to modify the incoming Stat value.
Modify TypeDetermines how the Modifier is applied to the incoming Stat value. See Contribution Types below.

Modify Types​

TypeDescription
FlatAdds the Modifier directly to the Stat value. Result = Value + Modifier
RateChanges the Stat value by the Modifier rate. Result = Value × (1 + Modifier)
MultiplierMultiplies the Stat value directly by the Modifier. Result = Value × Modifier
info

The adapter has implementations for different Stat value types. The supported value type and the behavior of the modification depend on the specific implementation being used.

Example​

With an incoming Stat value of 100, all three types reach 110:

Modify TypeModifierResult
Flat10100 + 10 = 110
Rate0.10100 × (1 + 0.10) = 110
Multiplier1.10100 × 1.10 = 110

In Ranged Deflect, StatValueAdapter_AlterVector3 (Flat, Modifier (0, 0.5, 0)) lifts the shooter's Position by half a metre, so a deflected projectile flies back at chest height instead of at the shooter's feet.