Glorpia Docs
Instances

UIGradient

Applies a two-endpoint colour and transparency gradient to its parent GUI object.

Properties

NameTypeDescription
ColourColourSequenceTwo endpoint colours. Color is an alias. Default: white to white.
TransparencyNumberSequenceTwo endpoint transparencies from 0 through 1. Default: 0 to 0.
OffsetVector2Moves the gradient across the parent GUI. Each component is clamped from -1 through 1. Default: Vector2.zero.
RotationnumberGradient rotation in degrees. Default: 0.
EnabledbooleanControls whether the gradient is applied. Default: true.
This UIGradient pass supports two endpoints. ColorSequence.new / ColourSequence.new and NumberSequence.new expose Start and End values rather than arbitrary keypoints.
UIGradient affects the parent GUI object's background, border and text rendering.

Example

Luau
local gradient = Instance.new("UIGradient")
gradient.Colour = ColourSequence.new(
    Colour3.fromRGB(88, 255, 106),
    Colour3.fromRGB(80, 145, 255)
)
gradient.Transparency = NumberSequence.new(0, 0.2)
gradient.Offset = Vector2.new(0, 0)
gradient.Rotation = 35
gradient.Enabled = true
gradient.Parent = workspace.Part.BillboardGui.TextButton

Related