Convert Time

This function converts Unix epoch timestamps into Windows FILETIME timestamps (in seconds) or vice versa.

function ConvertTime(n, To)
local Formats = {
Unix = -1
Windows = 1
}
return Formats[To] and n + 11644473600 * Formats[To] or nil
end