diff --git a/Lidgren.Network/NetBuffer.Write.Reflection.cs b/Lidgren.Network/NetBuffer.Write.Reflection.cs index bcb01af..1498bf1 100644 --- a/Lidgren.Network/NetBuffer.Write.Reflection.cs +++ b/Lidgren.Network/NetBuffer.Write.Reflection.cs @@ -78,11 +78,7 @@ namespace Lidgren.Network foreach (PropertyInfo fi in fields) { -#if UNITY_WEBPLAYER || UNITY_4_5 MethodInfo getMethod = fi.GetGetMethod(); -#else - MethodInfo getMethod = fi.GetMethod; -#endif if (getMethod != null) { object value = getMethod.Invoke(ob, null); diff --git a/Lidgren.Network/NetConnection.cs b/Lidgren.Network/NetConnection.cs index d9863ac..91741b3 100644 --- a/Lidgren.Network/NetConnection.cs +++ b/Lidgren.Network/NetConnection.cs @@ -12,7 +12,7 @@ namespace Lidgren.Network /// /// Represents a connection to a remote peer /// - [DebuggerDisplay("RemoteUniqueIdentifier={RemoteUniqueIdentifier} RemoteEndPoint={remoteEndPoint}")] + [DebuggerDisplay("RemoteUniqueIdentifier={RemoteUniqueIdentifier} RemoteEndPoint={m_remoteEndPoint}")] public partial class NetConnection { private const int m_infrequentEventsSkipFrames = 8; // number of heartbeats to skip checking for infrequent events (ping, timeout etc) diff --git a/Lidgren.Network/NetUtility.cs b/Lidgren.Network/NetUtility.cs index a81ae09..2d58a4b 100644 --- a/Lidgren.Network/NetUtility.cs +++ b/Lidgren.Network/NetUtility.cs @@ -38,6 +38,8 @@ namespace Lidgren.Network /// public static partial class NetUtility { + private static readonly bool IsMono = Type.GetType("Mono.Runtime") != null; + /// /// Resolve endpoint callback ///