Constant Gradient Component

Add the Constant Gradient component to create an output gradient with the same value.

Provider

Gradient Signal Gem

Constant Gradient properties

Constant Gradient component properties

PropertyDescriptionValuesDefault
PreviewDisplays the output gradient of this component after all properties are applied.
Pin Preview to ShapeSets an entity with a compatible Shape component to use as the bounds of the preview if Constrain to Shape is Enabled.EntityIdCurrent Entity
Preview PositionSets the world location of the preview.

This field is available only if there is no entity selected in Pin Preview to Shape.
Vector3: -Infinity to InfinityX:0.0, Y:0.0, Z:0.0
Preview SizeSets the dimensions of the preview.Vector3: 0.0 to InfinityX:1.0, Y:1.0, Z:1.0
Constrain to ShapeIf Enabled, the gradient preview uses the bounds of the entity selected in Pin Preview to Shape.

This field is available only if an entity is selected in Pin Preview to Shape.
BooleanDisabled
ValueSets the single value that this gradient returns.Float: 0.0 - 1.01.0

ConstantGradientRequestBus

Use the following request functions with the ConstantGradientRequestBus EBus interface to communicate with Constant Gradient components in your game.

Request NameDescriptionParameterReturnScriptable
GetConstantValueReturns the value of the Value property.NoneConstant Value: FloatYes
SetConstantValueSets the value of the Value property.Constant Value: FloatNoneYes