Stat Scaling Source

πŸ“ˆ StatScalingSource Struct

The StatScalingSource struct is used by a Stat as the source to scale itself. It essentially works as the scaling settings.

Namespace: Esper.Inventool.Stats Access: public Type: struct Attributes: [Serializable]


πŸ“¦ Fields

Access
Field
Type
Description

public

scalingType

ScalingSource.ScalingType

The scaling mode used (None, Linear, Curve).

public

initialValue

StatValue

The starting value.

public

increment

StatValue

The scaling amount used for linear scaling.

public

min

StatValue

The minimum value used for curve scaling.

public

max

StatValue

The maximum value used for curve scaling.

public

curve

AnimationCurve

The curve used when scaling type is Curve.


🧰 Constructors

Access
Constructor
Description

public

StatScalingSource(StatValue initialValue)

Creates a scaling source with no scaling.

public

StatScalingSource(StatValue initialValue, StatValue increment)

Creates a scaling source with linear scaling.

public

StatScalingSource(StatValue initialValue, StatValue min, StatValue max, AnimationCurve curve)

Creates a scaling source with curve scaling.


🧰 Methods

Access
Method
Returns
Description

public

SetIdentity(StatIdentity identity)

void

Sets the identity for all values (initialValue, increment, min, max).

public

GetScaledValue(int level, int maxLevel)

StatValue

Gets the scaled value at a specific level.

Create a Scaling Source

Set Identity

The SetIdentity method can be used to set the Stat Identity of the stat values.

Get Scaled Value

You can get the scaled value at a certain level with the GetScaledValue method. This requires 2 integers: the current level and the max level.

Last updated