Hi,
I wanna make a GUI button that when you click it, it tweens to night, or to day depending on which button. How would I make this?
LocalScript inside the button
Night:
script.Parent.Activated:Connect(function()
game:GetService("TweenService"):Create(game.Lighting, TweenInfo.new(1), {ClockTime = 0}):Play()
end)
Day:
script.Parent.Activated:Connect(function()
game:GetService("TweenService"):Create(game.Lighting, TweenInfo.new(1), {ClockTime = 12}):Play()
end)
1 Like
Thanks, i didn’t expect the answer to be so simple.