How To Edit KeyPoint UI Gradient Transparency

so i have two keypoints and i want to move them ,edit there time value but i cant do it .
i am trying to set there time but it not updateing , it giving me an error that says “Time cannot be assigned to”
how could i update the keypoints?

local UiGradint = script.Parent
local tweenService = game:GetService("TweenService")
local tweeninfo = TweenInfo.new(4,Enum.EasingStyle.Linear,Enum.EasingDirection.InOut,-1)

--UiGradint.Keypoints[3].Time = 0
UiGradint.Transparency.Keypoints[3].Time = 0.5

Thanks :smiley:

1 Like

You have to reconstruct the modified keypoints before overwriting the entire sequence.

local uiGradient = script.Parent
local keypoints = uiGradient.Transparency.Keypoints

keypoints[3] = NumberSequenceKeypoint.new(0.5, keypoints[3].Value)
uiGradient.Transparency = NumberSequence.new(keypoints)
2 Likes

Thanks Bro i was trying to edit the keypoin for like a 3 days from now

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.