You've already forked lidgren-network-gen3
mirror of
https://github.com/lidgren/lidgren-network-gen3.git
synced 2026-05-19 00:26:30 +09:00
- Handle NatIntroduction message even if connection already exists
This commit is contained in:
@@ -409,6 +409,10 @@ namespace Lidgren.Network
|
|||||||
int size = emsg.ReadInt32();
|
int size = emsg.ReadInt32();
|
||||||
HandleExpandMTUSuccess(now, size);
|
HandleExpandMTUSuccess(now, size);
|
||||||
break;
|
break;
|
||||||
|
case NetMessageType.NatIntroduction:
|
||||||
|
// Unusual situation where server is actually already known, but got a nat introduction - oh well, lets handle it as usual
|
||||||
|
m_peer.HandleNatIntroduction(ptr);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
m_peer.LogWarning("Connection received unhandled library message: " + tp);
|
m_peer.LogWarning("Connection received unhandled library message: " + tp);
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ namespace Lidgren.Network
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Called when host/client receives a NatIntroduction message from a master server
|
/// Called when host/client receives a NatIntroduction message from a master server
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void HandleNatIntroduction(int ptr)
|
internal void HandleNatIntroduction(int ptr)
|
||||||
{
|
{
|
||||||
VerifyNetworkThread();
|
VerifyNetworkThread();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user