Implement Core.TickCount
Convert movement, actions (lift/use), combat, and spells to use Core.TickCount and avoid DateTime caveats (performance, system time dependency, etc) Refactor DateTime.Now to DateTime.UtcNow Add LOS check for Iron Maiden addon
This commit is contained in:
parent
f99eefb288
commit
d2c670f5c3
241 changed files with 842 additions and 831 deletions
|
|
@ -77,8 +77,8 @@ namespace Server.Engines.Reports
|
|||
{
|
||||
BaseInfo cmp = obj as BaseInfo;
|
||||
|
||||
int v = cmp.GetPageCount( cmp is StaffInfo ? PageResolution.Handled : PageResolution.None, DateTime.Now - m_SortRange, DateTime.Now )
|
||||
- this.GetPageCount( this is StaffInfo ? PageResolution.Handled : PageResolution.None, DateTime.Now - m_SortRange, DateTime.Now );
|
||||
int v = cmp.GetPageCount( cmp is StaffInfo ? PageResolution.Handled : PageResolution.None, DateTime.UtcNow - m_SortRange, DateTime.UtcNow )
|
||||
- this.GetPageCount( this is StaffInfo ? PageResolution.Handled : PageResolution.None, DateTime.UtcNow - m_SortRange, DateTime.UtcNow );
|
||||
|
||||
if ( v == 0 )
|
||||
v = String.Compare( this.Display, cmp.Display );
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ namespace Server.Engines.Reports
|
|||
|
||||
public QueueStatus( int count )
|
||||
{
|
||||
m_TimeStamp = DateTime.Now;
|
||||
m_TimeStamp = DateTime.UtcNow;
|
||||
m_Count = count;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ namespace Server.Engines.Reports
|
|||
|
||||
public ResponseInfo( string sentBy, string message )
|
||||
{
|
||||
m_TimeStamp = DateTime.Now;
|
||||
m_TimeStamp = DateTime.UtcNow;
|
||||
m_SentBy = sentBy;
|
||||
m_Message = message;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ namespace Server.Engines.Reports
|
|||
|
||||
public override void DeserializeChildren( PersistanceReader ip )
|
||||
{
|
||||
DateTime min = DateTime.Now - TimeSpan.FromDays( 8.0 );
|
||||
DateTime min = DateTime.UtcNow - TimeSpan.FromDays( 8.0 );
|
||||
|
||||
while ( ip.HasChild )
|
||||
{
|
||||
|
|
@ -229,7 +229,7 @@ namespace Server.Engines.Reports
|
|||
int[] totals = new int[24];
|
||||
int[] counts = new int[24];
|
||||
|
||||
DateTime max = DateTime.Now;
|
||||
DateTime max = DateTime.UtcNow;
|
||||
DateTime min = max - TimeSpan.FromDays( 7.0 );
|
||||
|
||||
for ( int i = 0; i < m_QueueStats.Count; ++i )
|
||||
|
|
@ -289,7 +289,7 @@ namespace Server.Engines.Reports
|
|||
|
||||
DateTime[] dates = new DateTime[24];
|
||||
|
||||
DateTime max = DateTime.Now;
|
||||
DateTime max = DateTime.UtcNow;
|
||||
DateTime min = max - TimeSpan.FromDays( 7.0 );
|
||||
|
||||
bool sentStamp = ( res == PageResolution.None );
|
||||
|
|
@ -349,7 +349,7 @@ namespace Server.Engines.Reports
|
|||
|
||||
private Report ReportTotalPages( StaffInfo[] staff, TimeSpan ts, string title )
|
||||
{
|
||||
DateTime max = DateTime.Now;
|
||||
DateTime max = DateTime.UtcNow;
|
||||
DateTime min = max - ts;
|
||||
|
||||
Report report = new Report( title + " Staff Report", "400" );
|
||||
|
|
@ -365,7 +365,7 @@ namespace Server.Engines.Reports
|
|||
|
||||
private PieChart[] ChartTotalPages( StaffInfo[] staff, TimeSpan ts, string title, string fname )
|
||||
{
|
||||
DateTime max = DateTime.Now;
|
||||
DateTime max = DateTime.UtcNow;
|
||||
DateTime min = max - ts;
|
||||
|
||||
PieChart staffChart = new PieChart( title + " Staff Chart", fname + "_staff", true );
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue