I followed a youtube tutorial on how to make a circular progress bar but It wasn’t specifically made for my game so I had to make some changes and I don’t understand what’s wrong with it what to do next.
local TweenService = game:GetService("TweenService")
local LevelProgress = script.Parent
local Left = LevelProgress:WaitForChild("Left"):WaitForChild("Circle")
local Right = LevelProgress:WaitForChild("Right"):WaitForChild("Circle")
local Center = LevelProgress:WaitForChild("Center")
local Percentage = game.Players.LocalPlayer.leaderstats.Exp.Value/tostring(100 * (game.Players.LocalPlayer.leaderstats.Level.Value + 1))
game.Players.LocalPlayer.leaderstats.Exp:GetPropertyChangedSignal("Value"):Connect(function()
local Rotation = math.floor(math.clamp(Percentage * 3.6, 0, 360))
Right.UIGradient.Rotation = math.clamp(Rotation, 0, 180)
Left.UIGradient.Rotation = math.clamp(Rotation, 180, 360)
end)
local Tween = TweenService:Create(Percentage, TweenInfo.new(0.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out), {Value = Percentage})
game.Players.LocalPlayer.leaderstats.Exp.Value:GetPropertyChangedSignal("Value"):Connect(function()
print(Percentage)
end)