Hello everyone,
I have seen a lot of day/night cycle scripts but seen none of them use tween service which is weird because I feel it’s more smooth so I decided to make it like that
local co = coroutine.resume(coroutine.create(function()
wait(2)
local Tick = 1 -- the time it needs to pass 1 hour in game
while true do
local tween = game:GetService("TweenService"):Create(game.Lighting,TweenInfo.new(Tick,Enum.EasingStyle.Linear),{ClockTime = game.Lighting.ClockTime + 1})
tween:Play()
tween.Completed:Wait()
end
end))
What do you think?