Add a Order.SyncHashOrderLength const

This commit is contained in:
abcdefg30
2020-10-11 20:22:37 +02:00
committed by abcdefg30
parent 8d5ed65feb
commit 1861174d38
7 changed files with 9 additions and 6 deletions

View File

@@ -123,7 +123,7 @@ namespace OpenRA.Network
var frame = BitConverter.ToInt32(packet, 0);
if (packet.Length == 5 && packet[4] == (byte)OrderType.Disconnect)
frameData.ClientQuit(clientId, frame);
else if (packet.Length == 4 + 1 + 4 + 8 && packet[4] == (byte)OrderType.SyncHash)
else if (packet.Length == 4 + Order.SyncHashOrderLength && packet[4] == (byte)OrderType.SyncHash)
CheckSync(packet);
else if (frame == 0)
immediatePackets.Add((clientId, packet));