2009-04-19 18:07:22 +00:00
|
|
|
|
|
|
|
#region ================== Copyright (c) 2007 Pascal vd Heiden
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Copyright (c) 2007 Pascal vd Heiden, www.codeimp.com
|
|
|
|
* This program is released under GNU General Public License
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
2012-07-10 10:20:45 +00:00
|
|
|
using SlimDX;
|
2009-04-19 18:07:22 +00:00
|
|
|
|
|
|
|
namespace CodeImp.DoomBuilder
|
|
|
|
{
|
2016-02-01 22:04:00 +00:00
|
|
|
public static class Clock
|
2009-04-19 18:07:22 +00:00
|
|
|
{
|
|
|
|
// This queries the system for the current time
|
2016-03-14 00:01:21 +00:00
|
|
|
public static long CurrentTime { get { return Configuration.Timer.ElapsedMilliseconds; } }
|
2016-08-29 10:06:16 +00:00
|
|
|
|
|
|
|
//mxd. Timer needs to be reset from time to time (like, every 2 days of continuously running the editor) to prevent float precision degradation.
|
|
|
|
internal static void Reset()
|
|
|
|
{
|
|
|
|
Configuration.Timer.Reset();
|
|
|
|
Configuration.Timer.Start();
|
|
|
|
}
|
2009-04-19 18:07:22 +00:00
|
|
|
}
|
|
|
|
}
|