mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-10 21:41:50 +00:00
change system clock to steady clock (like in l_precise_time)
This commit is contained in:
parent
4e149e2b28
commit
b70dce5da2
1 changed files with 1 additions and 1 deletions
|
|
@ -22,7 +22,7 @@ static int l_utc_time(lua::State* L) {
|
||||||
}
|
}
|
||||||
|
|
||||||
static int l_precise_utc_time(lua::State* L) {
|
static int l_precise_utc_time(lua::State* L) {
|
||||||
auto now = std::chrono::system_clock::now();
|
auto now = std::chrono::steady_clock::now();
|
||||||
return lua::pushnumber(
|
return lua::pushnumber(
|
||||||
L, std::chrono::duration<double>(now.time_since_epoch()).count()
|
L, std::chrono::duration<double>(now.time_since_epoch()).count()
|
||||||
);
|
);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue