--!strict
--SecondsToClock
--Yuuwa0519
--2021-08-25


return function(seconds: number): ...number
    local rawHours: number = seconds / 3600
    local fullHours: number = math.floor(rawHours)
    local partialHours: number = rawHours - fullHours

    local rawMinutes: number = partialHours * 60
    local fullMinutes: number = math.floor(rawMinutes)
    local partialMinutes: number = rawMinutes - fullMinutes
    
    local rawSeconds: number = partialMinutes * 60
    local fullSeconds: number = math.round(rawSeconds)

    if fullSeconds == 60 then
        fullMinutes += 1
        fullSeconds = 0
    end

    if fullMinutes == 60 then
        fullHours += 1
        fullMinutes = 0
    end

    return fullHours, fullMinutes, fullSeconds
end
