Files
LuaCsForBarotraumaEP/Barotrauma/BarotraumaClient/ClientSource/Utils/ConnectCommand.cs
Juan Pablo Arce 1219615d64 Unstable v0.19.1.0
2022-08-19 13:59:08 -03:00

33 lines
823 B
C#

#nullable enable
using Barotrauma.Networking;
namespace Barotrauma
{
readonly struct ConnectCommand
{
public readonly struct NameAndEndpoint
{
public readonly string ServerName;
public readonly Endpoint Endpoint;
public NameAndEndpoint(string serverName, Endpoint endpoint)
{
ServerName = serverName;
Endpoint = endpoint;
}
}
public readonly Either<NameAndEndpoint, ulong> EndpointOrLobby;
public ConnectCommand(string serverName, Endpoint endpoint)
{
EndpointOrLobby = new NameAndEndpoint(serverName, endpoint);
}
public ConnectCommand(ulong lobbyId)
{
EndpointOrLobby = lobbyId;
}
}
}