mirror of
https://github.com/n00mkrad/flowframes.git
synced 2025-12-25 12:49:26 +01:00
24 lines
502 B
C#
24 lines
502 B
C#
using System;
|
|
using System.Diagnostics;
|
|
using System.Linq;
|
|
|
|
namespace Flowframes.MiscUtils
|
|
{
|
|
class NmkdStopwatch
|
|
{
|
|
public Stopwatch sw = new Stopwatch();
|
|
public long ElapsedMs { get { return sw.ElapsedMilliseconds; } }
|
|
|
|
public NmkdStopwatch(bool startOnCreation = true)
|
|
{
|
|
if (startOnCreation)
|
|
sw.Restart();
|
|
}
|
|
|
|
public override string ToString()
|
|
{
|
|
return FormatUtils.TimeSw(sw);
|
|
}
|
|
}
|
|
}
|