quick core tweak

This commit is contained in:
mark 2011-10-02 04:14:01 +00:00
parent 4ff574358a
commit 008c706ba8
2 changed files with 6 additions and 6 deletions

View file

@ -502,7 +502,7 @@ namespace Server
try
{
DateTime now, last = DateTime.Now;
DateTime now, last = DateTime.UtcNow;
const int sampleInterval = 100;
const float ticksPerSecond = (float)(TimeSpan.TicksPerSecond * sampleInterval);
@ -525,7 +525,7 @@ namespace Server
if( (++sample % sampleInterval) == 0 )
{
now = DateTime.Now;
now = DateTime.UtcNow;
m_CyclesPerSecond[m_CycleIndex++ % m_CyclesPerSecond.Length] =
ticksPerSecond / (now.Ticks - last.Ticks);
last = now;

View file

@ -3050,10 +3050,10 @@ namespace Server
private static TimeSpan m_WalkMount = TimeSpan.FromSeconds( 0.2 );
private static TimeSpan m_RunMount = TimeSpan.FromSeconds( 0.1 );
public static TimeSpan WalkFoot { get { return m_WalkFoot; } }
public static TimeSpan RunFoot { get { return m_RunFoot; } }
public static TimeSpan WalkMount { get { return m_WalkMount; } }
public static TimeSpan RunMount { get { return m_RunMount; } }
public static TimeSpan WalkFoot { get { return m_WalkFoot; } set { m_WalkFoot = value; } }
public static TimeSpan RunFoot { get { return m_RunFoot; } set { m_RunFoot = value; } }
public static TimeSpan WalkMount { get { return m_WalkMount; } set { m_WalkMount = value; } }
public static TimeSpan RunMount { get { return m_RunMount; } set { m_RunMount = value; } }
private DateTime m_EndQueue;