Fixes SendMessages

This commit is contained in:
Kamron Batman 2023-10-10 20:34:48 -07:00
parent 13c3e52639
commit d984df1c16
No known key found for this signature in database
GPG key ID: 7D81DF26D9A5D94A
18 changed files with 309 additions and 1962 deletions

View file

@ -255,7 +255,7 @@ public class GenericEntityPersistence<T> : Persistence, IGenericEntityPersistenc
try
{
using var op = new StreamWriter("world-save-errors.log", true);
op.WriteLine("{0}\t{1}", DateTime.UtcNow, message);
op.WriteLine("{0}\t{1}", Core.Now, message);
op.WriteLine(new StackTrace(2).ToString());
op.WriteLine();
}

View file

@ -51,7 +51,7 @@ public interface IGenericReader
{
long.MinValue => DateTime.MinValue,
long.MaxValue => DateTime.MaxValue,
var delta => new DateTime(delta + DateTime.UtcNow.Ticks, DateTimeKind.Utc)
var delta => new DateTime(delta + Core.Now.Ticks, DateTimeKind.Utc)
};
}
decimal ReadDecimal() => new(stackalloc int[4] { ReadInt(), ReadInt(), ReadInt(), ReadInt() });

View file

@ -70,7 +70,7 @@ public interface IGenericWriter
}
// Technically supports negative deltas for times in the past
Write(value.Ticks - DateTime.UtcNow.Ticks);
Write(value.Ticks - Core.Now.Ticks);
}
void Write(IPAddress value)
{