void SetupConnection()
        {
            if (m_Connection == null)
            {
                return;
            }

            m_Connection.Register(LiveLinkMsg.PlayerRequestHandshakeLiveLink, RequestSessionHandshake);
            m_Connection.Register(LiveLinkMsg.PlayerRequestConnectLiveLink, ConnectLiveLink);
            m_Connection.Register(LiveLinkMsg.PlayerSetLoadedScenes, SetLoadedScenes);
            m_Connection.RegisterConnection(OnPlayerConnected);
            m_Connection.RegisterDisconnection(OnPlayerDisconnected);

            // After domain reload we need to reconnect all data to the player.
            // Optimally we would keep all state alive across domain reload...
            LiveLinkMsg.LogSend("ResetGame");
            m_Connection.Send(LiveLinkMsg.EditorResetGame, new byte[0]);
        }