mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-16 16:56:07 +00:00
i.e. world update start
This commit is contained in:
committed by
Francesco Borzì
parent
1b7522ff0e
commit
51b8773528
37
src/server/game/Time/GameTime.h
Normal file
37
src/server/game/Time/GameTime.h
Normal file
@@ -0,0 +1,37 @@
|
||||
/*
|
||||
* Copyright (C) 2016+ AzerothCore <www.azerothcore.org>, released under GNU GPL v2 license: https://github.com/azerothcore/azerothcore-wotlk/blob/master/LICENSE-GPL2
|
||||
* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/>
|
||||
* Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
|
||||
*/
|
||||
|
||||
#ifndef __GAMETIME_H
|
||||
#define __GAMETIME_H
|
||||
|
||||
#include "Define.h"
|
||||
|
||||
#include <chrono>
|
||||
|
||||
namespace GameTime
|
||||
{
|
||||
// Server start time
|
||||
time_t GetStartTime();
|
||||
|
||||
// Current server time (unix) in seconds
|
||||
time_t GetGameTime();
|
||||
|
||||
// Milliseconds since server start
|
||||
uint32 GetGameTimeMS();
|
||||
|
||||
/// Current chrono system_clock time point
|
||||
std::chrono::system_clock::time_point GetGameTimeSystemPoint();
|
||||
|
||||
/// Current chrono steady_clock time point
|
||||
std::chrono::steady_clock::time_point GetGameTimeSteadyPoint();
|
||||
|
||||
/// Uptime (in secs)
|
||||
uint32 GetUptime();
|
||||
|
||||
void UpdateGameTimers();
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user