You've already forked lidgren-network-gen3
mirror of
https://github.com/lidgren/lidgren-network-gen3.git
synced 2026-05-15 22:56:30 +09:00
Merge branch 'master' of https://github.com/lidgren/lidgren-network-gen3
This commit is contained in:
@@ -28,11 +28,14 @@ namespace Lidgren.Network
|
||||
/// </summary>
|
||||
public static IPAddress GetMyAddress(out IPAddress mask)
|
||||
{
|
||||
#if UNITY_ANDROID || UNITY_STANDALONE_OSX || UNITY_STANDLONE_WIN || UNITY_STANDLONE_LINX || UNITY_IOS
|
||||
mask = null;
|
||||
#if UNITY_ANDROID || UNITY_STANDALONE_OSX || UNITY_STANDLONE_WIN || UNITY_STANDLONE_LINUX || UNITY_IOS
|
||||
try
|
||||
{
|
||||
if (!(UnityEngine.Application.internetReachability == UnityEngine.NetworkReachability.NotReachable))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return IPAddress.Parse(UnityEngine.Network.player.externalIP);
|
||||
}
|
||||
catch // Catch Access Denied errors
|
||||
@@ -40,7 +43,6 @@ namespace Lidgren.Network
|
||||
return null;
|
||||
}
|
||||
#endif
|
||||
mask = null;
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user