fix(core): Cleanup UOGateway (#555)

This commit is contained in:
Kamron Batman 2021-03-15 18:02:34 -07:00 committed by GitHub
parent 6649344ad2
commit d40273f99d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

View file

@ -113,8 +113,8 @@ namespace Server.Network
writer.Write(ConnectUOProtocolVersion); // Version
writer.Write((byte)_serverType);
writer.Write((int)(Core.TickCount / 1000));
writer.Write(Accounts.Count); // Shame if you modify this!
writer.Write(TcpServer.Instances.Count); // Shame if you modify this!
writer.Write(Accounts.Count); // Shame if you modify this!
writer.Write(TcpServer.Instances.Count - 1); // Shame if you modify this!
ns.Send(writer.Span);
}

View file

@ -37,7 +37,7 @@ namespace Server.Network
{
ns.SendCompactShardStats(
(uint)(Core.TickCount / 1000),
TcpServer.Instances.Count,
TcpServer.Instances.Count - 1, // Shame if you modify this!
World.Items.Count,
World.Mobiles.Count,
GC.GetTotalMemory(false)
@ -50,7 +50,7 @@ namespace Server.Network
ns.SendExtendedShardStats(
ServerList.ServerName,
(int)(Core.TickCount / ticksInHour),
TcpServer.Instances.Count,
TcpServer.Instances.Count - 1, // Shame if you modify this!
World.Items.Count,
World.Mobiles.Count,
(int)(GC.GetTotalMemory(false) / 1024)
@ -88,7 +88,7 @@ namespace Server.Network
}
var str =
$"ModernUO, Name={name}, Age={age}, Clients={clients}, Items={items}, Chars={mobiles}, Mem={mem}, Ver=2";
$"ModernUO, Name={name}, Age={age}, Clients={clients}, Items={items}, Chars={mobiles}, Mem={mem}K, Ver=2";
var length = Encoding.UTF8.GetMaxByteCount(str.Length);