mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
NetworkClient.ConnectLocalServer: use the same order as Connect
This commit is contained in:
parent
7bc320d098
commit
912572d6fe
@ -82,6 +82,12 @@ public static void Connect(string ip)
|
||||
// connect host mode
|
||||
internal static void ConnectLocalServer()
|
||||
{
|
||||
if (LogFilter.Debug) Debug.Log("Client Connect Local Server");
|
||||
active = true;
|
||||
RegisterSystemHandlers(true);
|
||||
|
||||
connectState = ConnectState.Connected;
|
||||
|
||||
// create local connection to server
|
||||
connection = new ULocalConnectionToServer();
|
||||
SetHandlers(connection);
|
||||
@ -90,11 +96,6 @@ internal static void ConnectLocalServer()
|
||||
ULocalConnectionToClient connectionToClient = new ULocalConnectionToClient();
|
||||
NetworkServer.SetLocalConnection(connectionToClient);
|
||||
|
||||
connectState = ConnectState.Connected;
|
||||
|
||||
active = true;
|
||||
RegisterSystemHandlers(true);
|
||||
|
||||
localClientPacketQueue.Enqueue(MessagePacker.Pack(new ConnectMessage()));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user