Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- while wait() do
- local t = tick()
- local sec = math.floor(t % 60)
- local min = math.floor((t/60)% 60)
- local hour = math.floor((t/3600)% 24)
- if string.len(sec) < 2 then sec = "0" .. tostring(sec) end
- if string.len(min) < 2 then min = "0" .. tostring(min) end
- if string.len(hour) < 2 then hour = "0" .. tostring(hour) end
- script.Parent.DigitalTime.Text = hour .. ":" .. min .. ":" .. sec
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement