Hello! I found this script on the forum which use the tween service to tween the color of the part. But it’s not tweening smoothly.
Here is the script:
local TweenService = game:GetService("TweenService")
local Frame = script.Parent
local function SimpleTween(Object, Length, Style, Direction, Properties)
local Tween = TweenService:Create(
Object,
TweenInfo.new(Length, Enum.EasingStyle[Style].Value, Enum.EasingDirection[Direction].Value),
Properties
)
Tween:Play()
Tween.Completed:Wait()
Tween:Destroy()
end
while true do
SimpleTween(Frame, 1, "Linear", "Out", { Color = Color3.fromRGB(255, 0, 0) })
SimpleTween(Frame, 1, "Linear", "Out", { Color = Color3.fromRGB(255, 136, 0) })
SimpleTween(Frame, 1, "Linear", "Out", { Color = Color3.fromRGB(255, 226, 0) })
SimpleTween(Frame, 1, "Linear", "Out", { Color = Color3.fromRGB(0, 255, 0) })
SimpleTween(Frame, 1, "Linear", "Out", { Color = Color3.fromRGB(0, 251, 255) })
SimpleTween(Frame, 1, "Linear", "Out", { Color = Color3.fromRGB(8, 0, 255) })
SimpleTween(Frame, 1, "Linear", "Out", { Color = Color3.fromRGB(149, 0, 255) })
SimpleTween(Frame, 1, "Linear", "Out", { Color = Color3.fromRGB(226, 0, 255) })
end
Here is the video:
https://i.gyazo.com/be20d7617f0cbc5d9be349e8ba9839c8.mp4
