Skip to main content

Value Set

A Value Set is a UObject subclass with a value determined by its Value Types.
It is used inside a Value Sets Manager to determine its Value Total

Value Set Mode

When creating a Value Set, you'll be able to specify a Mode in its Details panel.

This Mode will determine the behavior of the Value Set.
There currently exists three modes:

  • Regular
  • Multiplier
  • Super Multiplier

Regular

The Default Value of a Regular Value Set is 0 and its Value Types and ID Values are added together.
It means that a Regular Value Set will return 0 + ValueType1 + ValueType2 + etc..

A newly registered ID Value will also have a Default Value of 0.
Therefore, using ModifyIDValue() with an ID that doesn't exist yet in a Regular Value Set will set its value to 0 + Modifier.

In this example, if "NewID" already exists, it will just add 5 to it.
If it doesn't exist, it will set it to DefaultValue + Modifier = 0 + 5 = 5.

Regular Value Set Example

Multiplier

The Default Value of a Multiplier Value Set is 1 and its Value Types and ID Values are added together.
It means that a Multiplier Value Set will return 1 + ValueType1 + ValueType2 + etc..

A newly registered ID Value will have a Default Value of 0.
Therefore, using ModifyIDValue() with an ID that doesn't exist yet in a Multiplier Value Set will set its value to 0 + Modifier.

In this example, if "NewID" already exists, it will just add 0.1 to it.
If it doesn't exist, it will set it to DefaultValue + Modifier = 0 + 0.1 = 0.1.
If we used a negative value, for example -0.1, it would set it to DefaultValue + Modifier = 0 - 0.1 = -0.1

Multiplier Value Set Example

note

This is how a standard multiplier usually works. A Multiplier increase of 10% isn't absolute and doesn't guarantee an overall increase of 10% on the Final Value.

Consider a Strength Regular value of 100 with a Multiplier of 1.2.
Assuming GetValueTotal() in the Value Sets Manager multiplies them together, its Final Vale would be
Regular * Multiplier = 100 * 1.2 = 120.

Now consider this effect: "Increase your Strength by 10%".
In most games, this increase won't be applied to the overall value of the Stat, but rather increase the multiplier.
So, instead of doing this:
New Final Value = 120 * 1.1 = 132.
It will do this:
New Final Value = 100 * (1.2 + 0.1) = 130.

If you want a Mutliplier that always guarantees an absolute multiplication, you'll have to use a Super Multiplier.

Super Multiplier

The Default Value of a Super Multiplier Value Set is 1 and its Value Types and ID Values are multiplied together.
It means that a Super Multiplier Value Set will return 1 * ValueType1 * ValueType2 * etc..

A newly registered ID Value will have a Default Value of 1.
For example, using ModifyIDValue() with an ID that doesn't exist yet in a Super Multiplier Value Set will set its value to 1 + Modifier.

In this example, if "NewID" already exists, it will just add 0.1 to it.
If it doesn't exist, it will set it to DefaultValue + Modifier = 1 + 0.1 = 1.1.
I we used a negative value, for example -0.1, it would set it to DefaultValue + Modifier = 1 - 0.1 = 0.9.

Super Multiplier Value Set Example

Get

To get the value of a Value Set, you can use GetValueSetValue().