private void onValidationFailed() { Log.Warning("PLAYER CONNECTION FAILED"); // Disconnect the client clientPeerConnection.Disconnect(); failureHandler(clientPeerConnection); }
/// <summary> /// Disconnect and destroy player object /// </summary> public void Destroy(string reason) { if (clientConnection != null) { clientConnection.Disconnect(reason); } clientConnection = null; GlobalManager.GetManager <CreatureManager>().RemovePlayer(this); }