diff --git a/Assets/Mirror/Runtime/NetworkClient.cs b/Assets/Mirror/Runtime/NetworkClient.cs index ff893c495..a8e30e240 100644 --- a/Assets/Mirror/Runtime/NetworkClient.cs +++ b/Assets/Mirror/Runtime/NetworkClient.cs @@ -51,7 +51,7 @@ internal static void SetHandlers(NetworkConnection conn) conn.SetHandlers(handlers); } - public void Connect(string ip) + public static void Connect(string ip) { if (LogFilter.Debug) Debug.Log("Client Connect: " + ip); diff --git a/Assets/Mirror/Runtime/NetworkManager.cs b/Assets/Mirror/Runtime/NetworkManager.cs index 74ffe8e82..6ee652ef1 100644 --- a/Assets/Mirror/Runtime/NetworkManager.cs +++ b/Assets/Mirror/Runtime/NetworkManager.cs @@ -340,7 +340,7 @@ public NetworkClient StartClient() } if (LogFilter.Debug) Debug.Log("NetworkManager StartClient address:" + networkAddress); - client.Connect(networkAddress); + NetworkClient.Connect(networkAddress); OnStartClient(client); s_Address = networkAddress;