1
0
mirror of https://github.com/lidgren/lidgren-network-gen3.git synced 2026-05-16 15:16:33 +09:00

Fixed issue with recycling count and resent messages

This commit is contained in:
Michael Lidgren
2015-02-06 19:23:32 +01:00
parent b3fffb52e5
commit 6a0abf25c3
3 changed files with 16 additions and 6 deletions

View File

@@ -220,7 +220,10 @@ namespace Lidgren.Network
msg.m_isSent = true;
if (m_configuration.IsMessageTypeEnabled(NetIncomingMessageType.UnconnectedData) == false)
{
Interlocked.Decrement(ref msg.m_recyclingCount);
return; // dropping unconnected message since it's not enabled for receiving
}
NetIncomingMessage om = CreateIncomingMessage(NetIncomingMessageType.UnconnectedData, msg.LengthBytes);
om.Write(msg);