I'm stuck on how to turn the IntValue that has a value of 86400(seconds in a day). How do I turn the value into Hours and seconds? I have checked online the wiki and haven't been able to find anything to answer my question. Please, if possible give me some help
local plr = game.Players.LocalPlayer
local hasjoined = plr.hasjoined
local val = script.Parent.Timer
local sp = script.Parent.Parent.Parent.StarterPack
local repstore = game:GetService("ReplicatedStorage")
local rem = repstore.RemoteFolder:WaitForChild("StarterPackUpdate")
if hasjoined.Value == false then
while wait(1) do
val.Value = val.Value - 1
script.Parent.Text = "".. val.Value ..""
if val.Value == 0 then
sp.Visible = false
rem:FireServer("updateSP")
print("fired")
elseif
hasjoined.Value == true then
sp.Visible = false
end
end
end

6 comments
script.Parent.Text = string.format("%d: % 0 2 d", math.floor(val.Value/60), val.Value%60)
Be sure to remove the space in the pattern % 0 2 d. I put them there since the site doesn't like them for some reason
Sorry to ask, is there a way to make it Hours,Minutes,Seconds?
ew what indentation is that
I don't worry about indentation I fix it when I'm done with a script not when I'm working on it
Why do indentation after you finish? The point of it is to be easier to read.