Fixes #25 client crash on non en-US clients

This commit is contained in:
hondacrx
2019-01-01 22:34:45 -05:00
parent 1e1c5c77a8
commit 4cad206647
2 changed files with 6 additions and 6 deletions
+5 -5
View File
@@ -83,15 +83,15 @@ namespace Game.Network.Packets
if (Allow)
{
_worldPacket.WriteBits(Stats.Title.IsEmpty() ? 0 : Stats.Title.Length + 1, 11);
_worldPacket.WriteBits(Stats.TitleAlt.IsEmpty() ? 0 : Stats.TitleAlt.Length + 1, 11);
_worldPacket.WriteBits(Stats.CursorName.IsEmpty() ? 0 : Stats.CursorName.Length + 1, 6);
_worldPacket.WriteBits(Stats.Title.IsEmpty() ? 0 : Stats.Title.GetByteCount() + 1, 11);
_worldPacket.WriteBits(Stats.TitleAlt.IsEmpty() ? 0 : Stats.TitleAlt.GetByteCount() + 1, 11);
_worldPacket.WriteBits(Stats.CursorName.IsEmpty() ? 0 : Stats.CursorName.GetByteCount() + 1, 6);
_worldPacket.WriteBit(Stats.Leader);
for (var i = 0; i < SharedConst.MaxCreatureNames; ++i)
{
_worldPacket.WriteBits(Stats.Name[i].Length + 1, 11);
_worldPacket.WriteBits(Stats.NameAlt[i].Length + 1, 11);
_worldPacket.WriteBits(Stats.Name[i].GetByteCount() + 1, 11);
_worldPacket.WriteBits(Stats.NameAlt[i].GetByteCount() + 1, 11);
}
for (var i = 0; i < SharedConst.MaxCreatureNames; ++i)