mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2025-12-21 19:40:39 +00:00
Merge pull request #110 from kamilprzyb/vehicles_pr
Fixed Time and implemented vehicles expiring
This commit is contained in:
@@ -150,3 +150,12 @@ time_t getTime() {
|
||||
|
||||
return (time_t)value.count();
|
||||
}
|
||||
|
||||
// returns system time in seconds
|
||||
time_t getTimestamp() {
|
||||
using namespace std::chrono;
|
||||
|
||||
seconds value = duration_cast<seconds>((time_point_cast<seconds>(system_clock::now())).time_since_epoch());
|
||||
|
||||
return (time_t)value.count();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user