You've already forked lidgren-network-gen3
mirror of
https://github.com/lidgren/lidgren-network-gen3.git
synced 2026-05-06 10:21:09 +09:00
Tag added to NetPeer
This commit is contained in:
@@ -50,6 +50,8 @@ namespace Lidgren.Network
|
||||
|
||||
private void InitializeNetwork()
|
||||
{
|
||||
VerifyNetworkThread();
|
||||
|
||||
lock (m_initializeLock)
|
||||
{
|
||||
m_configuration.Lock();
|
||||
|
||||
@@ -13,6 +13,7 @@ namespace Lidgren.Network
|
||||
private static int s_initializedPeersCount;
|
||||
|
||||
private int m_listenPort;
|
||||
private object m_tag;
|
||||
|
||||
internal readonly List<NetConnection> m_connections;
|
||||
private readonly Dictionary<IPEndPoint, NetConnection> m_connectionLookup;
|
||||
@@ -42,6 +43,15 @@ namespace Lidgren.Network
|
||||
/// </summary>
|
||||
public int Port { get { return m_listenPort; } }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the application defined object containing data about the peer
|
||||
/// </summary>
|
||||
public object Tag
|
||||
{
|
||||
get { return m_tag; }
|
||||
set { m_tag = value; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets a copy of the list of connections
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user