Scalable Floats and Curve Tables¶
FScalableFloat is GAS's primary mechanism for level-based scaling. It pairs a raw float value with an optional curve table reference, producing Value * Curve[Level] at runtime.
FScalableFloat¶
Properties¶
| Property | Type | Description |
|---|---|---|
Value |
float |
The raw coefficient. If no curve is set, this is the final value. |
Curve |
FCurveTableRowHandle |
Reference to a row in a UCurveTable. Evaluated at the specified level. |
RegistryType |
FDataRegistryType |
Optional: Data Registry containing the curve. If set, Curve.RowName is used as the item name. |
Evaluation¶
At runtime, GetValueAtLevel(Level) computes:
If no curve is set (IsStatic() == true), the raw Value is returned directly.
Key Methods¶
| Method | Description |
|---|---|
GetValueAtLevel(float Level) |
Returns Value * Curve[Level]. The primary evaluation method. |
GetValue() |
Returns GetValueAtLevel(0). Convenience for level-independent lookups. |
AsBool(float Level) |
Returns true if the evaluated value is non-zero |
AsInteger(float Level) |
Returns the evaluated value cast to int32 |
IsStatic() |
Returns true if there is no curve reference (raw float only) |
SetValue(float) |
Sets the raw Value without changing the curve reference |
SetScalingValue(float, FName, UCurveTable*) |
Sets both the value and curve reference |
IsValid() |
Returns false if the curve reference is broken |
Where FScalableFloat Appears in GAS¶
FScalableFloat is used extensively throughout the Gameplay Effect system:
| Location | Property | What It Controls |
|---|---|---|
FGameplayModifierInfo |
ModifierMagnitude (when using ScalableFloat type) |
Modifier magnitude at a given GE level |
UGameplayEffect |
DurationMagnitude |
How long a HasDuration effect lasts |
UGameplayEffect |
Period |
Time between periodic executions |
FGameplayAbilitySpecConfig |
LevelScalableFloat |
Ability level granted by AbilitiesGameplayEffectComponent |
UChanceToApplyGameplayEffectComponent |
ChanceToApplyToTarget |
Probability of GE application (0.0 to 1.0) |
| Various ability tasks | Duration/delay parameters | Task-specific timing |
Curve Tables¶
A UCurveTable is a collection of named curves, each mapping a float input (the "level") to a float output.
Creating a Curve Table¶
- Content Browser > Add > Miscellaneous > Curve Table
- Choose Rich Curve (for interpolated float curves) or Simple Curve (for linear segments)
- Add rows — each row name becomes a key you reference from
FScalableFloat - Add columns for each level (1, 2, 3, ...) and set the values
Linking a Scalable Float to a Curve Table¶
In a Gameplay Effect's modifier:
- Set Magnitude Calculation Type to Scalable Float
- Set the
Valuefield (the multiplier coefficient, often1.0) - In the
Curvedropdown, select your curve table and row - At runtime, the GE's level is passed as the curve input
Global Curve Table¶
You can designate a global curve table in Project Settings > Gameplay Abilities Settings > Global Curve Table. This table is loaded once at startup and available to all FScalableFloat references. Useful for centralizing all scaling data in one asset.
Data Registry Integration¶
FScalableFloat supports FDataRegistryType as an alternative to direct curve table references. When RegistryType is set:
- The
Curve.RowNameis used as the Data Registry item name - The curve table reference itself may be empty — the registry resolves it
- This enables async loading and late-binding of curve data
This is an advanced feature primarily useful for large projects that need lazy-loaded scaling data.
Practical Patterns¶
Flat Value (No Scaling)¶
Set Value to the desired number, leave Curve empty. The value is constant regardless of level.
Level Curve Only¶
Set Value to 1.0, set Curve to a row that contains the actual values per level.
Coefficient + Curve¶
Set Value to a coefficient, set Curve to a normalized progression curve. Useful when multiple abilities share the same curve shape but different magnitudes.
This allows designers to tune individual ability magnitudes (the Value) independently from the overall scaling curve.