1
0
mirror of https://github.com/lidgren/lidgren-network-gen3.git synced 2026-05-06 02:11:06 +09:00

masterserver sample work

This commit is contained in:
lidgren
2010-05-11 20:42:58 +00:00
parent e62057c250
commit 6afb80ab12
6 changed files with 23 additions and 3 deletions

View File

@@ -33,6 +33,15 @@ namespace Lidgren.Network
{
private static Regex s_regIP;
/// <summary>
/// Get IP endpoint from notation (xxx.xxx.xxx.xxx) or hostname and port number
/// </summary>
public static IPEndPoint Resolve(string ipOrHost, int port)
{
IPAddress adr = Resolve(ipOrHost);
return new IPEndPoint(adr, port);
}
/// <summary>
/// Get IP address from notation (xxx.xxx.xxx.xxx) or hostname
/// </summary>