Modularize CultMesh transport planes
This commit is contained in:
parent
434db81e43
commit
c16163a82f
19 changed files with 2162 additions and 171 deletions
|
|
@ -112,7 +112,8 @@ namespace GameCult.Networking
|
|||
!IsSupportedSchemaEndpointScheme(uri.Scheme) ||
|
||||
string.IsNullOrWhiteSpace(uri.Host))
|
||||
{
|
||||
throw new FormatException($"CultNet endpoint '{endpoint}' must use cultnet://host:port or rudp://host:port.");
|
||||
throw new FormatException(
|
||||
$"CultNet endpoint '{endpoint}' must use cultnet+tcp://host:port, cultnet://host:port, or rudp://host:port.");
|
||||
}
|
||||
|
||||
return (uri.Host, uri.IsDefaultPort ? 3075 : uri.Port);
|
||||
|
|
@ -135,7 +136,8 @@ namespace GameCult.Networking
|
|||
|
||||
private static bool IsSupportedSchemaEndpointScheme(string scheme)
|
||||
{
|
||||
return string.Equals(scheme, "cultnet", StringComparison.OrdinalIgnoreCase) ||
|
||||
return string.Equals(scheme, "cultnet+tcp", StringComparison.OrdinalIgnoreCase) ||
|
||||
string.Equals(scheme, "cultnet", StringComparison.OrdinalIgnoreCase) ||
|
||||
string.Equals(scheme, "rudp", StringComparison.OrdinalIgnoreCase);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue