mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-08-15 10:47:21 +00:00
#UTILS
* Fix for GetOSTime
This commit is contained in:
parent
882c2e2378
commit
02a59b0742
@ -1725,10 +1725,16 @@ end
|
|||||||
-- @return #number Os time in seconds.
|
-- @return #number Os time in seconds.
|
||||||
function UTILS.GetOSTime()
|
function UTILS.GetOSTime()
|
||||||
if os then
|
if os then
|
||||||
return os.clock()
|
local ts = 0
|
||||||
|
local t = os.date("*t")
|
||||||
|
local s = t.sec
|
||||||
|
local m = t.min * 60
|
||||||
|
local h = t.hour * 3600
|
||||||
|
ts = s+m+h
|
||||||
|
return ts
|
||||||
|
else
|
||||||
|
return nil
|
||||||
end
|
end
|
||||||
|
|
||||||
return nil
|
|
||||||
end
|
end
|
||||||
|
|
||||||
--- Shuffle a table accoring to Fisher Yeates algorithm
|
--- Shuffle a table accoring to Fisher Yeates algorithm
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user